package ink.wgink.login.oauth2.server.pojo.dtos;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;

/**
 * When you feel like quitting. Think about why you started
 * 当你想要放弃的时候，想想当初你为何开始
 *
 * @ClassName: OauthClientSimpleDTO
 * @Description: 客户端简单信息
 * @Author: WangGeng
 * @Date: 2020/7/17 18:18
 * @Version: 1.0
 **/
@ApiModel
public class OAuth2ClientSimpleDTO implements Serializable {

    private static final long serialVersionUID = -1552124710719004198L;
    @ApiModelProperty(name = "clientId", value = "客户端ID")
    private String clientId;
    @ApiModelProperty(name = "clientName", value = "客户端名称")
    private String clientName;
    @ApiModelProperty(name = "webServerRedirectUri", value = "重定向链接")
    private String webServerRedirectUri;
    @ApiModelProperty(name = "environment", value = "系统环境")
    private String environment;
    @ApiModelProperty(name = "systemSummary", value = "系统介绍")
    private String systemSummary;
    @ApiModelProperty(name = "systemIcon", value = "系统图标")
    private String systemIcon;
    @ApiModelProperty(name = "gmtCreate", value = "创建时间")
    private String gmtCreate;

    public String getClientId() {
        return clientId == null ? "" : clientId.trim();
    }

    public void setClientId(String clientId) {
        this.clientId = clientId;
    }

    public String getClientName() {
        return clientName == null ? "" : clientName.trim();
    }

    public void setClientName(String clientName) {
        this.clientName = clientName;
    }

    public String getWebServerRedirectUri() {
        return webServerRedirectUri == null ? "" : webServerRedirectUri.trim();
    }

    public void setWebServerRedirectUri(String webServerRedirectUri) {
        this.webServerRedirectUri = webServerRedirectUri;
    }

    public String getEnvironment() {
        return environment == null ? "" : environment.trim();
    }

    public void setEnvironment(String environment) {
        this.environment = environment;
    }

    public String getSystemSummary() {
        return systemSummary == null ? "" : systemSummary.trim();
    }

    public void setSystemSummary(String systemSummary) {
        this.systemSummary = systemSummary;
    }

    public String getSystemIcon() {
        return systemIcon == null ? "" : systemIcon.trim();
    }

    public void setSystemIcon(String systemIcon) {
        this.systemIcon = systemIcon;
    }

    public String getGmtCreate() {
        return gmtCreate == null ? "" : gmtCreate.trim();
    }

    public void setGmtCreate(String gmtCreate) {
        this.gmtCreate = gmtCreate;
    }

    @Override
    public String toString() {
        final StringBuilder sb = new StringBuilder("{");
        sb.append("\"clientId\":\"")
                .append(clientId).append('\"');
        sb.append(",\"clientName\":\"")
                .append(clientName).append('\"');
        sb.append(",\"webServerRedirectUri\":\"")
                .append(webServerRedirectUri).append('\"');
        sb.append(",\"environment\":\"")
                .append(environment).append('\"');
        sb.append(",\"systemSummary\":\"")
                .append(systemSummary).append('\"');
        sb.append(",\"systemIcon\":\"")
                .append(systemIcon).append('\"');
        sb.append(",\"gmtCreate\":\"")
                .append(gmtCreate).append('\"');
        sb.append('}');
        return sb.toString();
    }
}
