com.hn.im.easemob.comm.body.ModifyNicknameBody Maven / Gradle / Ivy
package com.hn.im.easemob.comm.body;
import com.fasterxml.jackson.databind.node.ContainerNode;
import com.fasterxml.jackson.databind.node.JsonNodeFactory;
import com.hn.im.easemob.comm.wrapper.BodyWrapper;
import cn.hutool.core.util.StrUtil;
public class ModifyNicknameBody implements BodyWrapper{
private String nickname;
public ModifyNicknameBody(String nickname) {
this.nickname = nickname;
}
public String getNickname() {
return nickname;
}
public void setNickname(String nickname) {
this.nickname = nickname;
}
public ContainerNode> getBody() {
return JsonNodeFactory.instance.objectNode().put("nickname", nickname);
}
public Boolean validate() {
return StrUtil.isNotBlank(nickname);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy