package ink.wgink.login.app.pojo.vos.appsign;

import ink.wgink.annotation.CheckEmptyAnnotation;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * When you feel like quitting. Think about why you started
 * 当你想要放弃的时候，想想当初你为何开始
 *
 * @ClassName: LoginVO
 * @Description: 登录
 * @Author: WangGeng
 * @Date: 2019-08-01 14:33
 * @Version: 1.0
 **/
@ApiModel
public class AppLoginVO {

    @ApiModelProperty(name = "username", value = "用户名")
    @CheckEmptyAnnotation(name = "用户名")
    private String username;
    @ApiModelProperty(name = "deviceNo", value = "设备编号")
    private String deviceNo;
    @ApiModelProperty(name = "longitude", value = "经度")
    private String longitude;
    @ApiModelProperty(name = "latitude", value = "纬度")
    private String latitude;
    @ApiModelProperty(name = "appId", value = "appId")
    private String appId;
    @ApiModelProperty(name = "appVersion", value = "app版本")
    private Integer appVersion;

    public String getUsername() {
        return username == null ? "" : username.trim();
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getDeviceNo() {
        return deviceNo == null ? "" : deviceNo.trim();
    }

    public void setDeviceNo(String deviceNo) {
        this.deviceNo = deviceNo;
    }

    public String getLongitude() {
        return longitude == null ? "" : longitude.trim();
    }

    public void setLongitude(String longitude) {
        this.longitude = longitude;
    }

    public String getLatitude() {
        return latitude == null ? "" : latitude.trim();
    }

    public void setLatitude(String latitude) {
        this.latitude = latitude;
    }

    public String getAppId() {
        return appId == null ? "" : appId.trim();
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public Integer getAppVersion() {
        return appVersion;
    }

    public void setAppVersion(Integer appVersion) {
        this.appVersion = appVersion;
    }

    @Override
    public String toString() {
        final StringBuilder sb = new StringBuilder("{");
        sb.append("\"username\":")
                .append("\"").append(username).append("\"");
        sb.append(",\"deviceNo\":")
                .append("\"").append(deviceNo).append("\"");
        sb.append(",\"longitude\":")
                .append("\"").append(longitude).append("\"");
        sb.append(",\"latitude\":")
                .append("\"").append(latitude).append("\"");
        sb.append(",\"appId\":")
                .append("\"").append(appId).append("\"");
        sb.append(",\"appVersion\":")
                .append(appVersion);
        sb.append('}');
        return sb.toString();
    }
}
