All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.dahuatech.icc.face.model.v202207.personInfo.SyncIvssRequest Maven / Gradle / Ivy

The newest version!
package com.dahuatech.icc.face.model.v202207.personInfo;

import com.dahuatech.hutool.http.Method;
import com.dahuatech.icc.common.ParamValidEnum;
import com.dahuatech.icc.exception.ClientException;
import com.dahuatech.icc.face.constant.FaceConstant;
import com.dahuatech.icc.oauth.exception.BusinessException;
import com.dahuatech.icc.oauth.http.AbstractIccRequest;
import com.dahuatech.icc.util.StringUtils;

/**
 * program:java-sdk
 *
 * Author: 312013
 * Date:2022-07-26 15:29
 * Description: 人像重发
 */
public class SyncIvssRequest extends AbstractIccRequest {
    private Long personid;
    private String deviceCode;

    public Long getPersonid() {
        return personid;
    }

    public void setPersonid(Long personid) {
        this.personid = personid;
    }

    public String getDeviceCode() {
        return deviceCode;
    }

    public void setDeviceCode(String deviceCode) {
        this.deviceCode = deviceCode;
    }

    public SyncIvssRequest() {
        super(FaceConstant.url(FaceConstant.SYNC_IVSS), Method.GET);
    }

    @Override
    public Class getResponseClass() {
        return SyncIvssResponse.class;
    }

    public void businessValid() {
        if(personid == null){
            throw new BusinessException(ParamValidEnum.PARAM_NOT_EMPTY_ERROR.getCode(), ParamValidEnum.PARAM_NOT_EMPTY_ERROR.getErrMsg(), "personid");
        }
        if(StringUtils.isEmpty(deviceCode)){
            throw new BusinessException(ParamValidEnum.PARAM_NOT_EMPTY_ERROR.getCode(), ParamValidEnum.PARAM_NOT_EMPTY_ERROR.getErrMsg(), "deviceCode");
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy