-
-
Notifications
You must be signed in to change notification settings - Fork 8.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
458e7c3
commit 6638383
Showing
8 changed files
with
325 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
114 changes: 114 additions & 0 deletions
114
weixin-java-cp/src/main/java/me/chanjar/weixin/cp/bean/oa/wedrive/WxCpFileList.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
package me.chanjar.weixin.cp.bean.oa.wedrive; | ||
|
||
import com.google.gson.annotations.SerializedName; | ||
import lombok.Data; | ||
import lombok.Getter; | ||
import lombok.Setter; | ||
import me.chanjar.weixin.cp.bean.WxCpBaseResp; | ||
import me.chanjar.weixin.cp.util.json.WxCpGsonBuilder; | ||
|
||
import java.io.Serializable; | ||
import java.util.List; | ||
|
||
/** | ||
* 获取邀请链接. | ||
* | ||
* @author Wang_Wong | ||
*/ | ||
@Data | ||
public class WxCpFileList extends WxCpBaseResp implements Serializable { | ||
private static final long serialVersionUID = -5028321625142879581L; | ||
|
||
@SerializedName("has_more") | ||
private Boolean hasMore; | ||
|
||
@SerializedName("next_start") | ||
private Integer nextStart; | ||
|
||
@SerializedName("file_list") | ||
private FileList fileList; | ||
|
||
@Getter | ||
@Setter | ||
public static class FileList implements Serializable { | ||
private static final long serialVersionUID = -4960239393895754598L; | ||
|
||
@SerializedName("item") | ||
private List<Item> item; | ||
|
||
public static FileList fromJson(String json) { | ||
return WxCpGsonBuilder.create().fromJson(json, FileList.class); | ||
} | ||
|
||
public String toJson() { | ||
return WxCpGsonBuilder.create().toJson(this); | ||
} | ||
|
||
} | ||
|
||
@Getter | ||
@Setter | ||
public static class Item implements Serializable { | ||
private static final long serialVersionUID = -4960239393895754598L; | ||
|
||
@SerializedName("fileid") | ||
private String fileId; | ||
|
||
@SerializedName("file_name") | ||
private String fileName; | ||
|
||
@SerializedName("spaceid") | ||
private String spaceId; | ||
|
||
@SerializedName("fatherid") | ||
private String fatherId; | ||
|
||
@SerializedName("file_size") | ||
private Long fileSize; | ||
|
||
@SerializedName("ctime") | ||
private Long cTime; | ||
|
||
@SerializedName("mtime") | ||
private Long mTime; | ||
|
||
@SerializedName("file_type") | ||
private Integer fileType; | ||
|
||
@SerializedName("file_status") | ||
private Integer fileStatus; | ||
|
||
@SerializedName("create_userid") | ||
private String createUserId; | ||
|
||
@SerializedName("update_userid") | ||
private String updateUserId; | ||
|
||
@SerializedName("sha") | ||
private String sha; | ||
|
||
@SerializedName("url") | ||
private String url; | ||
|
||
@SerializedName("md5") | ||
private String md5; | ||
|
||
public static Item fromJson(String json) { | ||
return WxCpGsonBuilder.create().fromJson(json, Item.class); | ||
} | ||
|
||
public String toJson() { | ||
return WxCpGsonBuilder.create().toJson(this); | ||
} | ||
|
||
} | ||
|
||
public static WxCpFileList fromJson(String json) { | ||
return WxCpGsonBuilder.create().fromJson(json, WxCpFileList.class); | ||
} | ||
|
||
public String toJson() { | ||
return WxCpGsonBuilder.create().toJson(this); | ||
} | ||
|
||
} |
50 changes: 50 additions & 0 deletions
50
weixin-java-cp/src/main/java/me/chanjar/weixin/cp/bean/oa/wedrive/WxCpFileListRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
package me.chanjar.weixin.cp.bean.oa.wedrive; | ||
|
||
import com.google.gson.annotations.SerializedName; | ||
import lombok.AllArgsConstructor; | ||
import lombok.Builder; | ||
import lombok.Data; | ||
import lombok.NoArgsConstructor; | ||
import lombok.experimental.Accessors; | ||
import me.chanjar.weixin.cp.util.json.WxCpGsonBuilder; | ||
|
||
import java.io.Serializable; | ||
|
||
/** | ||
* 获取文件列表请求. | ||
*/ | ||
@Data | ||
@Builder | ||
@NoArgsConstructor | ||
@AllArgsConstructor | ||
@Accessors(chain = true) | ||
public class WxCpFileListRequest implements Serializable { | ||
private static final long serialVersionUID = -4960239393895754138L; | ||
|
||
@SerializedName("userid") | ||
private String userId; | ||
|
||
@SerializedName("spaceid") | ||
private String spaceId; | ||
|
||
@SerializedName("fatherid") | ||
private String fatherId; | ||
|
||
@SerializedName("sort_type") | ||
private Integer sortType; | ||
|
||
@SerializedName("start") | ||
private Integer start; | ||
|
||
@SerializedName("limit") | ||
private Integer limit; | ||
|
||
public static WxCpFileListRequest fromJson(String json) { | ||
return WxCpGsonBuilder.create().fromJson(json, WxCpFileListRequest.class); | ||
} | ||
|
||
public String toJson() { | ||
return WxCpGsonBuilder.create().toJson(this); | ||
} | ||
|
||
} |
30 changes: 30 additions & 0 deletions
30
weixin-java-cp/src/main/java/me/chanjar/weixin/cp/bean/oa/wedrive/WxCpFileUpload.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package me.chanjar.weixin.cp.bean.oa.wedrive; | ||
|
||
import com.google.gson.annotations.SerializedName; | ||
import lombok.Data; | ||
import me.chanjar.weixin.cp.bean.WxCpBaseResp; | ||
import me.chanjar.weixin.cp.util.json.WxCpGsonBuilder; | ||
|
||
import java.io.Serializable; | ||
|
||
/** | ||
* 上传文件返回信息. | ||
* | ||
* @author Wang_Wong | ||
*/ | ||
@Data | ||
public class WxCpFileUpload extends WxCpBaseResp implements Serializable { | ||
private static final long serialVersionUID = -5028321625142879581L; | ||
|
||
@SerializedName("fileid") | ||
private String fileId; | ||
|
||
public static WxCpFileUpload fromJson(String json) { | ||
return WxCpGsonBuilder.create().fromJson(json, WxCpFileUpload.class); | ||
} | ||
|
||
public String toJson() { | ||
return WxCpGsonBuilder.create().toJson(this); | ||
} | ||
|
||
} |
47 changes: 47 additions & 0 deletions
47
weixin-java-cp/src/main/java/me/chanjar/weixin/cp/bean/oa/wedrive/WxCpFileUploadRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
package me.chanjar.weixin.cp.bean.oa.wedrive; | ||
|
||
import com.google.gson.annotations.SerializedName; | ||
import lombok.AllArgsConstructor; | ||
import lombok.Builder; | ||
import lombok.Data; | ||
import lombok.NoArgsConstructor; | ||
import lombok.experimental.Accessors; | ||
import me.chanjar.weixin.cp.util.json.WxCpGsonBuilder; | ||
|
||
import java.io.Serializable; | ||
|
||
/** | ||
* 上传文件请求. | ||
*/ | ||
@Data | ||
@Builder | ||
@NoArgsConstructor | ||
@AllArgsConstructor | ||
@Accessors(chain = true) | ||
public class WxCpFileUploadRequest implements Serializable { | ||
private static final long serialVersionUID = -4960239393895754138L; | ||
|
||
@SerializedName("userid") | ||
private String userId; | ||
|
||
@SerializedName("spaceid") | ||
private String spaceId; | ||
|
||
@SerializedName("fatherid") | ||
private String fatherId; | ||
|
||
@SerializedName("file_name") | ||
private String fileName; | ||
|
||
@SerializedName("file_base64_content") | ||
private String fileBase64Content; | ||
|
||
public static WxCpFileUploadRequest fromJson(String json) { | ||
return WxCpGsonBuilder.create().fromJson(json, WxCpFileUploadRequest.class); | ||
} | ||
|
||
public String toJson() { | ||
return WxCpGsonBuilder.create().toJson(this); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters