Selaa lähdekoodia

inss调整

master
huminghao 3 viikkoa sitten
vanhempi
commit
5dc05645d0

+ 37
- 0
gly-base-core/src/main/java/cn/com/taiji/core/model/comm/protocol/inss/renewalInst/RenewalInstApplyRequest.java Näytä tiedosto

@@ -0,0 +1,37 @@
package cn.com.taiji.core.model.comm.protocol.inss.renewalInst;

import cn.com.taiji.core.model.comm.protocol.AbstractSignTypeRequest;
import cn.com.taiji.core.model.comm.protocol.inss.inst.InstApplyResponse;
import cn.com.taiji.core.model.comm.protocol.inss.inst.InstServiceCmd;
import cn.com.taiji.core.model.comm.protocol.valid.ErrorMsgBuilder;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

@Getter
@Setter
@Accessors(chain = true)
public class RenewalInstApplyRequest extends AbstractSignTypeRequest<RenewalInstApplyResponse> {

public RenewalInstApplyRequest() {
super(RenewalInstServiceCmd.APPLY);
}

@NotBlank
private String orderNo;//订单号
@NotBlank
private String cardId;//卡号
@NotBlank
private String obuId;//签号
@NotNull
private Integer cardVersion;//卡版本
@NotNull
private Integer obuVersion;//签版本

public void relatedValid(ErrorMsgBuilder builder) {
}

}

+ 30
- 0
gly-base-core/src/main/java/cn/com/taiji/core/model/comm/protocol/inss/renewalInst/RenewalInstApplyResponse.java Näytä tiedosto

@@ -0,0 +1,30 @@
package cn.com.taiji.core.model.comm.protocol.inss.renewalInst;

import cn.com.taiji.core.model.comm.protocol.AbstractSignTypeResponse;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

@Getter
@Setter
@Accessors(chain = true)
public class RenewalInstApplyResponse extends AbstractSignTypeResponse {

private Integer stepNo;//步骤号
private String cmd;//指令
private String cmdType;//指令类型
private String transOrderId;//二发订单号


public RenewalInstApplyResponse() {

}

public RenewalInstApplyResponse(Integer stepNo, String cmd, String cmdType, String transOrderId) {
this.stepNo = stepNo;
this.cmd = cmd;
this.cmdType = cmdType;
this.transOrderId = transOrderId;
}

}

+ 35
- 0
gly-base-core/src/main/java/cn/com/taiji/core/model/comm/protocol/inss/renewalInst/RenewalInstCallBackRequest.java Näytä tiedosto

@@ -0,0 +1,35 @@
package cn.com.taiji.core.model.comm.protocol.inss.renewalInst;

import cn.com.taiji.core.model.comm.protocol.AbstractSignTypeRequest;
import cn.com.taiji.core.model.comm.protocol.inss.inst.InstCallBackResponse;
import cn.com.taiji.core.model.comm.protocol.inss.inst.InstServiceCmd;
import cn.com.taiji.core.model.comm.protocol.valid.ErrorMsgBuilder;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

@Getter
@Setter
@Accessors(chain = true)
public class RenewalInstCallBackRequest extends AbstractSignTypeRequest<RenewalInstCallBackResponse> {

public RenewalInstCallBackRequest() {
super(RenewalInstServiceCmd.CALLBACK);
}

@NotBlank
private String transOrderId;//交易编号
@NotBlank
private String cmd;//指令
@NotBlank
private String cmdResult;//指令结果
@NotNull
private Integer stepNo;

public void relatedValid(ErrorMsgBuilder builder) {
}

}

+ 18
- 0
gly-base-core/src/main/java/cn/com/taiji/core/model/comm/protocol/inss/renewalInst/RenewalInstCallBackResponse.java Näytä tiedosto

@@ -0,0 +1,18 @@
package cn.com.taiji.core.model.comm.protocol.inss.renewalInst;

import cn.com.taiji.core.model.comm.protocol.AbstractSignTypeResponse;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

@Getter
@Setter
@Accessors(chain = true)
public class RenewalInstCallBackResponse extends AbstractSignTypeResponse {

private Integer stepNo;
private String cmd;//指令
private String cmdType;//指令类型
private String transOrderId;//二发订单号

}

+ 46
- 0
gly-base-core/src/main/java/cn/com/taiji/core/model/comm/protocol/inss/renewalInst/RenewalInstServiceCmd.java Näytä tiedosto

@@ -0,0 +1,46 @@
package cn.com.taiji.core.model.comm.protocol.inss.renewalInst;

import cn.com.taiji.core.model.comm.protocol.AbstractSignTypeRequest;
import cn.com.taiji.core.model.comm.protocol.SignServiceCommand;
import cn.com.taiji.core.model.comm.protocol.SignServiceType;
import cn.com.taiji.core.model.comm.protocol.inss.InssServiceType;
import cn.com.taiji.core.model.comm.protocol.inss.inst.InstApplyRequest;
import cn.com.taiji.core.model.comm.protocol.inss.inst.InstCallBackRequest;

public enum RenewalInstServiceCmd implements SignServiceCommand {

APPLY("初始化命令", RenewalInstApplyRequest.class),
CALLBACK("激活指令回传", RenewalInstCallBackRequest.class);

private final String value;
private final Class<? extends AbstractSignTypeRequest<?>> reqClass;

RenewalInstServiceCmd(String value, Class<? extends AbstractSignTypeRequest<?>> reqClass) {
this.value = value;
this.reqClass = reqClass;
}

@Override
public SignServiceType getServiceType() {
return InssServiceType.RENEWALINST;
}

public static RenewalInstServiceCmd fromIfCode(String ifCode) {
return SignServiceCommand.fromName(RenewalInstServiceCmd.class, SignServiceCommand.getCmdStr(ifCode));
}

@Override
public String getValue() {
return value;
}

@Override
public boolean isMyCommand(String ifCode) {
return this == fromIfCode(ifCode);
}

@Override
public Class<? extends AbstractSignTypeRequest<?>> getProtocolClass() {
return reqClass;
}
}

Loading…
Peruuta
Tallenna