Unverified Commit 300a2802 authored by Yang Libin's avatar Yang Libin Committed by GitHub

feat: update toString methods (#51)

parent 102a7f69
......@@ -2,9 +2,6 @@ package io.github.doocs.im.model.group;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.github.doocs.im.constant.ApplyJoinOption;
import io.github.doocs.im.constant.GroupType;
import io.github.doocs.im.model.request.CreateGroupRequest;
import java.util.List;
......@@ -53,7 +50,7 @@ public class GroupInfo {
public GroupInfo() {
}
public GroupInfo(String ownerAccount, String type, String groupId, String name, String introduction,
public <T extends Builder> GroupInfo(String ownerAccount, String type, String groupId, String name, String introduction,
String notification, String faceUrl, Integer maxMemberCount, String applyJoinOption,
List<AppDefinedDataItem> appDefinedData, List<MemberProfile> memberList,
List<AppMemberDefinedDataItem> appMemberDefinedData) {
......@@ -71,7 +68,7 @@ public class GroupInfo {
this.appMemberDefinedData = appMemberDefinedData;
}
protected GroupInfo(Builder builder) {
protected <T extends Builder> GroupInfo(Builder builder) {
this.ownerAccount = builder.ownerAccount;
this.type = builder.type;
this.groupId = builder.groupId;
......@@ -205,22 +202,7 @@ public class GroupInfo {
'}';
}
public static void main(String[] args) {
CreateGroupRequest request = (CreateGroupRequest) CreateGroupRequest.builder()
.type(GroupType.PUBLIC)
.name("TestGroup")
.ownerAccount("doocs")
.groupId("MyFirstGroup")
.introduction("This is group Introduction")
.notification("This is group Notification")
.faceUrl("https://avatars.githubusercontent.com/u/43716716?s=200&v=4")
.maxMemberCount(500)
.applyJoinOption(ApplyJoinOption.FREE_ACCESS)
.build();
System.out.println(request.getClass());
}
public static class Builder {
public static class Builder<T extends Builder> {
private String ownerAccount;
private String type;
private String groupId;
......@@ -241,64 +223,64 @@ public class GroupInfo {
return new GroupInfo(this);
}
public Builder ownerAccount(String ownerAccount) {
public T ownerAccount(String ownerAccount) {
this.ownerAccount = ownerAccount;
return this;
return (T) this;
}
public Builder type(String type) {
public T type(String type) {
this.type = type;
return this;
return (T) this;
}
public Builder groupId(String groupId) {
public T groupId(String groupId) {
this.groupId = groupId;
return this;
return (T) this;
}
public Builder name(String name) {
public T name(String name) {
this.name = name;
return this;
return (T) this;
}
public Builder introduction(String introduction) {
public T introduction(String introduction) {
this.introduction = introduction;
return this;
return (T) this;
}
public Builder notification(String notification) {
public T notification(String notification) {
this.notification = notification;
return this;
return (T) this;
}
public Builder faceUrl(String faceUrl) {
public T faceUrl(String faceUrl) {
this.faceUrl = faceUrl;
return this;
return (T) this;
}
public Builder maxMemberCount(Integer maxMemberCount) {
public T maxMemberCount(Integer maxMemberCount) {
this.maxMemberCount = maxMemberCount;
return this;
return (T) this;
}
public Builder applyJoinOption(String applyJoinOption) {
public T applyJoinOption(String applyJoinOption) {
this.applyJoinOption = applyJoinOption;
return this;
return (T) this;
}
public Builder appDefinedData(List<AppDefinedDataItem> appDefinedData) {
public T appDefinedData(List<AppDefinedDataItem> appDefinedData) {
this.appDefinedData = appDefinedData;
return this;
return (T) this;
}
public Builder memberList(List<MemberProfile> memberList) {
public T memberList(List<MemberProfile> memberList) {
this.memberList = memberList;
return this;
return (T) this;
}
public Builder appMemberDefinedData(List<AppMemberDefinedDataItem> appMemberDefinedData) {
public T appMemberDefinedData(List<AppMemberDefinedDataItem> appMemberDefinedData) {
this.appMemberDefinedData = appMemberDefinedData;
return this;
return (T) this;
}
}
}
......@@ -17,7 +17,7 @@ public class CreateGroupRequest extends GroupInfo {
super(builder);
}
public static class Builder extends GroupInfo.Builder {
public static class Builder extends GroupInfo.Builder<CreateGroupRequest.Builder> {
@Override
public CreateGroupRequest build() {
return new CreateGroupRequest(this);
......
......@@ -24,6 +24,9 @@ public class AccountCheckResult extends GenericResult {
public String toString() {
return "AccountCheckResult{" +
"resultItems=" + resultItems +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class AccountDeleteResult extends GenericResult {
public String toString() {
return "AccountDeleteResult{" +
"resultItems=" + resultItems +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/7/28 11:02
*/
public class AccountImportResult extends GenericResult {
@Override
public String toString() {
return "AccountImportResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class AddGroupMemberResult extends GenericResult {
public String toString() {
return "AddGroupMemberResult{" +
"memberList=" + memberList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/28 20:32
*/
public class AdminMsgWithdrawResult extends GenericResult {
@Override
public String toString() {
return "AdminMsgWithdrawResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -70,8 +70,11 @@ public class AdminRoamMsgResult extends GenericResult {
"complete=" + complete +
", msgCnt=" + msgCnt +
", lastMsgTime=" + lastMsgTime +
", lastMsgKey=" + lastMsgKey +
", lastMsgKey='" + lastMsgKey + '\'' +
", msgList=" + msgList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/28 20:32
*/
public class AdminSetMsgReadResult extends GenericResult {
@Override
public String toString() {
return "AdminSetMsgReadResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -36,6 +36,9 @@ public class BatchSendMsgResult extends GenericResult {
return "BatchSendMsgResult{" +
"msgKey='" + msgKey + '\'' +
", errorList=" + errorList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -3,6 +3,7 @@ package io.github.doocs.im.model.response;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
import java.util.StringJoiner;
/**
* @author hyh
......@@ -48,6 +49,9 @@ public class BlackListAddResult extends GenericResult {
"resultItemList=" + resultItemList +
", failAccount=" + failAccount +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -48,6 +48,9 @@ public class BlackListCheckResult extends GenericResult {
"blackListCheckItemList=" + blackListCheckItemList +
", failAccount=" + failAccount +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -48,6 +48,9 @@ public class BlackListDeleteResult extends GenericResult {
"resultItemList=" + resultItemList +
", failAccount=" + failAccount +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -60,6 +60,9 @@ public class BlackListGetResult extends GenericResult {
", startIndex=" + startIndex +
", currentSequence=" + currentSequence +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -48,6 +48,9 @@ public class C2cUnreadMsgNumResult extends GenericResult {
"allC2cUnreadMsgNum=" + allC2cUnreadMsgNum +
", unreadMsgNumList=" + unreadMsgNumList +
", errorList=" + errorList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/8/4 11:36
*/
public class ChangeGroupOwnerResult extends GenericResult {
@Override
public String toString() {
return "ChangeGroupOwnerResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -22,6 +22,9 @@ public class CreateGroupResult extends GenericResult {
public String toString() {
return "CreateGroupResult{" +
"groupId='" + groupId + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,5 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/8/4 10:40
*/
public class DeleteGroupMemberResult extends GenericResult {
@Override
public String toString() {
return "DeleteGroupMemberResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/08/01 13:55
*/
public class DeleteGroupMsgBySenderResult extends GenericResult {
@Override
public String toString() {
return "DeleteGroupMsgBySenderResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -22,6 +22,9 @@ public class DeleteRecentContactResult extends GenericResult {
public String toString() {
return "DeleteRecentContactResult{" +
"errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,5 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/8/4 10:43
*/
public class DestroyGroupResult extends GenericResult {
@Override
public String toString() {
return "DestroyGroupResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/8/4 11:19
*/
public class ForbidSendMsgResult extends GenericResult {
@Override
public String toString() {
return "ForbidSendMsgResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -36,6 +36,9 @@ public class FriendAddResult extends GenericResult {
return "FriendAddResult{" +
"resultItemList=" + resultItemList +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -48,6 +48,9 @@ public class FriendCheckResult extends GenericResult {
"friendCheckInfoItemList=" + friendCheckInfoItemList +
", failAccount=" + failAccount +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -22,6 +22,9 @@ public class FriendDeleteAllResult extends GenericResult {
public String toString() {
return "FriendDeleteAllResult{" +
"errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -36,6 +36,9 @@ public class FriendDeleteResult extends GenericResult {
return "FriendDeleteResult{" +
"errorDisplay='" + errorDisplay + '\'' +
", resultItemList=" + resultItemList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -52,4 +52,14 @@ public class FriendGetListInfoItem {
public void setResultInfo(String resultInfo) {
this.resultInfo = resultInfo;
}
@Override
public String toString() {
return "FriendGetListInfoItem{" +
"toAccount='" + toAccount + '\'' +
", snsProfileItemList=" + snsProfileItemList +
", resultCode=" + resultCode +
", resultInfo='" + resultInfo + '\'' +
'}';
}
}
......@@ -50,6 +50,9 @@ public class FriendGetListResult extends GroupGetResult {
"infoItemList=" + infoItemList +
", failAccount=" + failAccount +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -96,6 +96,9 @@ public class FriendGetResult extends GenericResult {
", completeFlag=" + completeFlag +
", nextStartIndex=" + nextStartIndex +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -48,6 +48,9 @@ public class FriendImportResult extends GenericResult {
"resultItemList=" + resultItemList +
", errorDisplay='" + errorDisplay + '\'' +
", failAccount=" + failAccount +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -48,6 +48,9 @@ public class FriendUpdateResult extends GenericResult {
"resultItemList=" + resultItemList +
", errorDisplay='" + errorDisplay + '\'' +
", failAccount=" + failAccount +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -11,19 +11,19 @@ public abstract class GenericResult {
* 请求处理的结果,OK 表示处理成功,FAIL 表示失败,如果为 FAIL,ErrorInfo 带上失败原因
*/
@JsonProperty("ActionStatus")
private String actionStatus;
protected String actionStatus;
/**
* 失败原因
*/
@JsonProperty("ErrorInfo")
private String errorInfo;
protected String errorInfo;
/**
* 错误码,0为成功,其他为失败,错误码表:https://cloud.tencent.com/document/product/269/1671
*/
@JsonProperty("ErrorCode")
private Integer errorCode;
protected Integer errorCode;
public String getActionStatus() {
return actionStatus;
......
......@@ -24,6 +24,9 @@ public class GetAppInfoResult extends GenericResult {
public String toString() {
return "GetAppInfoResult{" +
"result=" + result +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -48,6 +48,9 @@ public class GetAppidGroupListResult extends GenericResult {
"totalCount=" + totalCount +
", groupIdList=" + groupIdList +
", next=" + next +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -25,6 +25,9 @@ public class GetGroupInfoResult extends GenericResult {
public String toString() {
return "GetGroupInfoResult{" +
"groupInfo=" + groupInfo +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -37,6 +37,9 @@ public class GetGroupMemberInfoResult extends GenericResult {
return "GetGroupMemberInfoResult{" +
"memberNum=" + memberNum +
", memberList=" + memberList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -12,10 +12,21 @@ public class GetGroupShuttedUinResult extends GenericResult {
@JsonProperty("ShuttedUinList")
private List<ShuttedUinResultItem> shuttedUinList;
public List<ShuttedUinResultItem> getShuttedUinList() {
return shuttedUinList;
}
public void setShuttedUinList(List<ShuttedUinResultItem> shuttedUinList) {
this.shuttedUinList = shuttedUinList;
}
@Override
public String toString() {
return "GetGroupShuttedUinResult{" +
"shuttedUinList=" + shuttedUinList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class GetHistoryResult extends GenericResult {
public String toString() {
return "GetHistoryResult{" +
"file=" + file +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class GetIpListResult extends GenericResult {
public String toString() {
return "GetIpListResult{" +
"ipList=" + ipList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -15,11 +15,30 @@ public class GetJoinGroupListResult extends GenericResult {
@JsonProperty("GroupIdList")
private List<GroupIdListResultItem> groupIdList;
public Integer getTotalCount() {
return totalCount;
}
public void setTotalCount(Integer totalCount) {
this.totalCount = totalCount;
}
public List<GroupIdListResultItem> getGroupIdList() {
return groupIdList;
}
public void setGroupIdList(List<GroupIdListResultItem> groupIdList) {
this.groupIdList = groupIdList;
}
@Override
public String toString() {
return "GetJoinGroupListResult{" +
"totalCount=" + totalCount +
", groupIdList=" + groupIdList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -41,6 +41,9 @@ public class GetNoSpeakingResult extends GenericResult {
return "GetNoSpeakingResult{" +
"c2CMsgNoSpeakingTime=" + c2CMsgNoSpeakingTime +
", groupMsgNoSpeakingTime=" + groupMsgNoSpeakingTime +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,4 +24,14 @@ public class GetOnlineMemberNumResult extends GenericResult {
public void setOnlineMemberNum(Integer onlineMemberNum) {
this.onlineMemberNum = onlineMemberNum;
}
@Override
public String toString() {
return "GetOnlineMemberNumResult{" +
"onlineMemberNum=" + onlineMemberNum +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -96,6 +96,9 @@ public class GetRecentContactListResult extends GenericResult {
", topTimestamp=" + topTimestamp +
", topStartIndex=" + topStartIndex +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class GetRoleInGroupResult extends GenericResult {
public String toString() {
return "GetRoleInGroupResult{" +
"userIdList=" + userIdList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -60,6 +60,9 @@ public class GroupAddResult extends GenericResult {
", failAccount=" + failAccount +
", currentSequence=" + currentSequence +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -34,6 +34,9 @@ public class GroupDeleteResult extends GenericResult {
return "GroupDeleteResult{" +
"currentSequence=" + currentSequence +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -48,6 +48,9 @@ public class GroupGetResult extends GenericResult {
"resultItemList=" + resultItemList +
", currentSequence=" + currentSequence +
", errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -174,7 +174,7 @@ public class GroupIdListResultItem {
@Override
public String toString() {
return "GroupIdListIResultItem{" +
return "GroupIdListResultItem{" +
"groupId='" + groupId + '\'' +
", type='" + type + '\'' +
", name='" + name + '\'' +
......
......@@ -48,6 +48,9 @@ public class GroupMsgGetSimpleResult extends GenericResult {
"groupId='" + groupId + '\'' +
", isFinished=" + isFinished +
", rspMsgList=" + rspMsgList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class GroupMsgRecallResult extends GenericResult {
public String toString() {
return "GroupMsgRecallResult{" +
"recallRetList=" + recallRetList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/30 14:27
*/
public class ImAddTagResult extends GenericResult {
@Override
public String toString() {
return "ImAddTagResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -22,8 +22,11 @@ public class ImGetAttrNameResult extends GenericResult {
@Override
public String toString() {
return "IMGetAttrNameResult{" +
return "ImGetAttrNameResult{" +
"attrNames=" + attrNames +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......
......@@ -22,8 +22,11 @@ public class ImGetAttrResult extends GenericResult {
@Override
public String toString() {
return "IMGetAttrResult{" +
return "ImGetAttrResult{" +
"userAttrs=" + userAttrs +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class ImGetTagResult extends GenericResult {
public String toString() {
return "ImGetTagResult{" +
"userTags=" + userTags +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -22,6 +22,9 @@ public class ImPushResult extends GenericResult {
public String toString() {
return "ImPushResult{" +
"taskId='" + taskId + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/30 14:28
*/
public class ImRemoveAllTagsResult extends GenericResult {
@Override
public String toString() {
return "ImRemoveAllTagsResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/30 14:03
*/
public class ImRemoveAttrResult extends GenericResult {
@Override
public String toString() {
return "ImRemoveAttrResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/30 14:27
*/
public class ImRemoveTagResult extends GenericResult {
@Override
public String toString() {
return "ImRemoveTagResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/30 11:22
*/
public class ImSetAttrNameResult extends GenericResult {
@Override
public String toString() {
return "ImSetAttrNameResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/30 11:54
*/
public class ImSetAttrResult extends GenericResult {
@Override
public String toString() {
return "ImSetAttrResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class ImportGroupMemberResult extends GenericResult {
public String toString() {
return "ImportGroupMemberResult{" +
"memberList=" + memberList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class ImportGroupMsgResult extends GenericResult {
public String toString() {
return "ImportGroupMsgResult{" +
"importMsgResult=" + importMsgResult +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -22,6 +22,9 @@ public class ImportGroupResult extends GenericResult {
public String toString() {
return "ImportGroupResult{" +
"groupId='" + groupId + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,5 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/28 17:54
*/
public class ImportMsgResult extends GenericResult {
@Override
public String toString() {
return "ImportMsgResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/7/28 11:07
*/
public class KickResult extends GenericResult {
@Override
public String toString() {
return "KickResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/08/02 19:27
*/
public class ModifyGroupBaseInfoResult extends GenericResult {
@Override
public String toString() {
return "ModifyGroupBaseInfoResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/8/4 10:42
*/
public class ModifyGroupMemberInfoResult extends GenericResult {
@Override
public String toString() {
return "ModifyGroupMemberInfoResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -24,6 +24,9 @@ public class MultiAccountImportResult extends GenericResult {
public String toString() {
return "MultiAccountImportResult{" +
"failAccounts=" + failAccounts +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -48,6 +48,9 @@ public class PortraitGetResult extends GenericResult {
"errorDisplay='" + errorDisplay + '\'' +
", userProfileItemList=" + userProfileItemList +
", failAccount=" + failAccount +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -22,6 +22,9 @@ public class PortraitSetResult extends GenericResult{
public String toString() {
return "PortraitSetResult{" +
"errorDisplay='" + errorDisplay + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -36,6 +36,9 @@ public class QueryOnlineStatusResult extends GenericResult {
return "QueryOnlineStatusResult{" +
"queryResult=" + queryResult +
", errorList=" + errorList +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -34,6 +34,9 @@ public class SendGroupMsgResult extends GenericResult {
return "SendGroupMsgResult{" +
"msgTime=" + msgTime +
", msgSeq=" + msgSeq +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/8/4 11:32
*/
public class SendGroupSystemNotificationResult extends GenericResult {
@Override
public String toString() {
return "SendGroupSystemNotificationResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -34,6 +34,9 @@ public class SendMsgResult extends GenericResult {
return "SendMsgResult{" +
"msgTime=" + msgTime +
", msgKey='" + msgKey + '\'' +
", actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,5 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/07/31 11:51:01
*/
public class SetNoSpeakingResult extends GenericResult {
@Override
public String toString() {
return "SetNoSpeakingResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -5,4 +5,12 @@ package io.github.doocs.im.model.response;
* @since 2021/08/01 13:58
*/
public class SetUnreadMsgNumResult extends GenericResult {
@Override
public String toString() {
return "SetUnreadMsgNumResult{" +
"actionStatus='" + actionStatus + '\'' +
", errorInfo='" + errorInfo + '\'' +
", errorCode=" + errorCode +
'}';
}
}
......@@ -4,8 +4,6 @@ import io.github.doocs.im.constant.ApplyJoinOption;
import io.github.doocs.im.constant.GroupType;
import io.github.doocs.im.constant.MemberRole;
import io.github.doocs.im.constant.OnlineOnlyFlag;
import io.github.doocs.im.model.group.GroupInfo;
import io.github.doocs.im.model.message.TIMMsgElement;
import io.github.doocs.im.model.message.TIMTextMsgElement;
import io.github.doocs.im.model.request.*;
import io.github.doocs.im.model.response.*;
......@@ -54,10 +52,10 @@ public class GroupTest {
@Test
public void testCreateGroup() throws IOException {
CreateGroupRequest request = (CreateGroupRequest) CreateGroupRequest.builder()
CreateGroupRequest request = CreateGroupRequest.builder()
.type(GroupType.PUBLIC)
.name("TestGroup")
.ownerAccount("doocs")
.ownerAccount("user2")
.groupId("MyFirstGroup")
.introduction("This is group Introduction")
.notification("This is group Notification")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment