Files
123123/dapp/src/project/monitor/erc20/dto/TransactionResponseDto.java
2026-02-19 03:37:37 +08:00

66 lines
1.2 KiB
Java
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
package project.monitor.erc20.dto;
public class TransactionResponseDto {
/**
* 自定义200为成功
*/
public static final String CODE_LOCAL_SUCCESS ="200";
/**
* 自定义-1为本地失败
*/
public static final String CODE_LOCAL_FAIL ="-1";
/**
* 交易返回的code
* 自定义200为成功
* 自定义-1为本地失败
* 其他为失败code
*/
private String code;
/**
* 交易发起时产生hash码
*/
private String hash;
/**
* 错误时会返回错误信息
*/
private String error;
public TransactionResponseDto() {
}
public TransactionResponseDto(String code, String hash, String error) {
this.code = code;
this.hash = hash;
this.error = error;
}
public TransactionResponseDto(String hash) {
this.code = CODE_LOCAL_SUCCESS;
this.hash = hash;
}
public TransactionResponseDto(String code, String error) {
this.code = code;
this.error = error;
}
public String getCode() {
return code;
}
public String getHash() {
return hash;
}
public String getError() {
return error;
}
public void setCode(String code) {
this.code = code;
}
public void setHash(String hash) {
this.hash = hash;
}
public void setError(String error) {
this.error = error;
}
}