add chatroom api

This commit is contained in:
imhao183
2020-04-02 22:50:04 +08:00
parent 83eae385b3
commit 1047db9990
12 changed files with 379 additions and 1 deletions
@@ -5,6 +5,11 @@ public interface APIPath {
String Chatroom_Destroy = "/admin/chatroom/del";
String Chatroom_Info = "/admin/chatroom/info";
String Chatroom_GetMembers = "/admin/chatroom/members";
String Chatroom_SetBlacklist = "/admin/chatroom/set_black_status";
String Chatroom_GetBlacklist = "/admin/chatroom/get_black_status";
String Chatroom_SetManager = "/admin/chatroom/set_manager";
String Chatroom_GetManagerList = "/admin/chatroom/get_manager_list";
String Chatroom_MuteAll = "/admin/chatroom/mute_all";
String Sensitive_Add = "/admin/sensitive/add";
@@ -0,0 +1,12 @@
package cn.wildfirechat.pojos;
public class InputChatroomId {
public String chatroomId;
public InputChatroomId() {
}
public InputChatroomId(String chatroomId) {
this.chatroomId = chatroomId;
}
}
@@ -0,0 +1,36 @@
/*
* This file is part of the Wildfire Chat package.
* (c) Heavyrain2012 <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
package cn.wildfirechat.pojos;
public class InputChatroomMute {
private String chatroomId;
private int status;
public InputChatroomMute(String chatroomId, int status) {
this.chatroomId = chatroomId;
this.status = status;
}
public String getChatroomId() {
return chatroomId;
}
public void setChatroomId(String chatroomId) {
this.chatroomId = chatroomId;
}
public int getStatus() {
return status;
}
public void setStatus(int status) {
this.status = status;
}
}
@@ -0,0 +1,58 @@
/*
* This file is part of the Wildfire Chat package.
* (c) Heavyrain2012 <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
package cn.wildfirechat.pojos;
public class InputSetChatroomBlacklist {
private String chatroomId;
private String userId;
private int status;
private long expiredTime;
public InputSetChatroomBlacklist() {
}
public InputSetChatroomBlacklist(String chatroomId, String userId, int status, long expiredTime) {
this.chatroomId = chatroomId;
this.userId = userId;
this.status = status;
this.expiredTime = expiredTime;
}
public String getChatroomId() {
return chatroomId;
}
public void setChatroomId(String chatroomId) {
this.chatroomId = chatroomId;
}
public String getUserId() {
return userId;
}
public void setUserId(String userId) {
this.userId = userId;
}
public int getStatus() {
return status;
}
public void setStatus(int status) {
this.status = status;
}
public long getExpiredTime() {
return expiredTime;
}
public void setExpiredTime(long expiredTime) {
this.expiredTime = expiredTime;
}
}
@@ -0,0 +1,48 @@
/*
* This file is part of the Wildfire Chat package.
* (c) Heavyrain2012 <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
package cn.wildfirechat.pojos;
public class InputSetChatroomManager {
private String chatroomId;
private String userId;
private int status;
public InputSetChatroomManager() {
}
public InputSetChatroomManager(String chatroomId, String userId, int status) {
this.chatroomId = chatroomId;
this.userId = userId;
this.status = status;
}
public String getChatroomId() {
return chatroomId;
}
public void setChatroomId(String chatroomId) {
this.chatroomId = chatroomId;
}
public String getUserId() {
return userId;
}
public void setUserId(String userId) {
this.userId = userId;
}
public int getStatus() {
return status;
}
public void setStatus(int status) {
this.status = status;
}
}
@@ -0,0 +1,25 @@
package cn.wildfirechat.pojos;
import java.util.ArrayList;
import java.util.List;
public class OutputChatroomBlackInfos {
public static class OutputChatroomBlackInfo {
public String userId;
public int state;
public long expiredTime;
public OutputChatroomBlackInfo() {
}
public OutputChatroomBlackInfo(String userId, int state, long expiredTime) {
this.userId = userId;
this.state = state;
this.expiredTime = expiredTime;
}
}
public List<OutputChatroomBlackInfo> infos = new ArrayList<>();
public void addBlackInfo(String userId, int state, long expiredTime) {
infos.add(new OutputChatroomBlackInfo(userId, state, expiredTime));
}
}