记得上下班打卡 | git大法好,push需谨慎
Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
liquidnet-bus-v1
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
董敬伟
liquidnet-bus-v1
Commits
ff4314e4
Commit
ff4314e4
authored
Feb 27, 2022
by
anjiabin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
实现nft中service接口
parent
64a5b495
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
1876 additions
and
307 deletions
+1876
-307
BeanUtil.java
...c/main/java/com/liquidnet/commons/lang/util/BeanUtil.java
+33
-0
ZxlnftBiz.java
...java/com/liquidnet/common/third/zxlnft/biz/ZxlnftBiz.java
+49
-1
ZxlnftConstant.java
...iquidnet/common/third/zxlnft/constant/ZxlnftConstant.java
+4
-0
Nft034PublishReqDto.java
...iquidnet/common/third/zxlnft/dto/Nft034PublishReqDto.java
+89
-0
Nft034PublishRespDto.java
...quidnet/common/third/zxlnft/dto/Nft034PublishRespDto.java
+37
-0
Nft054QueryUserAddressBelongToUserReq.java
...zxlnft/dto/nft/Nft054QueryUserAddressBelongToUserReq.java
+1
-1
ZxlnftSdkServiceImpl.java
...ommon/third/zxlnft/service/impl/ZxlnftSdkServiceImpl.java
+1663
-305
No files found.
liquidnet-bus-common/liquidnet-common-base/src/main/java/com/liquidnet/commons/lang/util/BeanUtil.java
View file @
ff4314e4
...
...
@@ -4,6 +4,8 @@
*/
package
com
.
liquidnet
.
commons
.
lang
.
util
;
import
org.apache.http.NameValuePair
;
import
org.apache.http.message.BasicNameValuePair
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.util.LinkedMultiValueMap
;
...
...
@@ -16,7 +18,9 @@ import java.lang.annotation.*;
import
java.lang.reflect.Field
;
import
java.lang.reflect.InvocationTargetException
;
import
java.lang.reflect.Method
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.concurrent.ConcurrentHashMap
;
import
java.util.function.Supplier
;
...
...
@@ -312,4 +316,33 @@ public class BeanUtil {
return
JsonUtils
.
toJson
(
map
);
}
/**
* bean转换为NameValuePair 键值对 只能是String,String
* @param bean
* @return
* @throws IntrospectionException
* @throws IllegalAccessException
* @throws InvocationTargetException
*/
public
static
List
<
NameValuePair
>
convertBeanToNameValuePairList
(
Object
bean
)
{
Map
<
String
,
Object
>
map
=
null
;
try
{
map
=
BeanUtil
.
convertBeanToMap
(
bean
,
false
);
}
catch
(
IntrospectionException
e
)
{
e
.
printStackTrace
();
}
catch
(
IllegalAccessException
e
)
{
e
.
printStackTrace
();
}
catch
(
InvocationTargetException
e
)
{
e
.
printStackTrace
();
}
List
<
NameValuePair
>
params
=
new
ArrayList
<
NameValuePair
>();
// Map集合循环遍历方式三 推荐,尤其是容量大时
for
(
Map
.
Entry
<
String
,
Object
>
m
:
map
.
entrySet
())
{
params
.
add
(
new
BasicNameValuePair
(
m
.
getKey
(),
m
.
getValue
().
toString
()));
}
return
params
;
}
}
liquidnet-bus-common/liquidnet-common-third/liquidnet-common-third-zxlnft/src/main/java/com/liquidnet/common/third/zxlnft/biz/ZxlnftBiz.java
View file @
ff4314e4
...
...
@@ -5,13 +5,19 @@ import com.liquidnet.common.third.zxlnft.config.ZxlnftConfig;
import
com.liquidnet.common.third.zxlnft.dto.wallet.*
;
import
com.liquidnet.common.third.zxlnft.exception.ZxlNftException
;
import
com.liquidnet.common.third.zxlnft.service.WalletSdkService
;
import
com.liquidnet.commons.lang.util.BeanUtil
;
import
com.liquidnet.commons.lang.util.JsonUtils
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.http.NameValuePair
;
import
org.apache.http.client.utils.URIBuilder
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
import
org.springframework.util.MultiValueMap
;
import
java.net.URI
;
import
java.net.URISyntaxException
;
import
java.nio.charset.StandardCharsets
;
import
java.util.List
;
/**
* @author AnJiabin <anjiabin@zhengzai.tv>
...
...
@@ -69,7 +75,7 @@ public class ZxlnftBiz {
log
.
info
(
"buildPlatFormHeader ---> {}"
,
JsonUtils
.
toJson
(
commonHeader
));
}
public
static
<
T
>
T
buildNftRespObj
(
String
response
,
Class
<
T
>
tClass
){
public
<
T
>
T
buildNftRespObj
(
String
response
,
Class
<
T
>
tClass
){
T
resp
=
null
;
try
{
resp
=
tClass
.
newInstance
();
...
...
@@ -105,10 +111,52 @@ public class ZxlnftBiz {
return
resp
.
getSignedData
();
}
/**
* 获取hash
* @param data
* @return
*/
public
String
getHashString
(
String
data
){
SM3HashEncodeReq
req
=
SM3HashEncodeReq
.
getNew
();
req
.
setData
(
data
.
getBytes
(
StandardCharsets
.
UTF_8
));
SM3HashEncodeResp
sm3HashEncodeResp
=
walletSdkService
.
sM3HashEncode
(
req
);
return
sm3HashEncodeResp
.
getDigest
();
}
/**
* 构造GET请求url
* @param requestUrl
* @param tClass
* @param <T>
* @return
*/
public
<
T
>
String
buildGetRequestUrl
(
String
requestUrl
,
Class
<
T
>
tClass
,
Object
obj
){
// List<NameValuePair> params = new ArrayList<NameValuePair>();
// if(StringUtil.isNotEmpty(req.getSeriesName())){
// params.add(new BasicNameValuePair("seriesName", req.getSeriesName()));
// }
// params.add(new BasicNameValuePair("platformIdentification", req.getPlatformIdentification()));
// if(StringUtil.isNotEmpty(req.getUserIdentification())){
// params.add(new BasicNameValuePair("userIdentification", req.getUserIdentification()));
// }
// T reqObj = null;
// try {
// reqObj = tClass.newInstance();
// } catch (InstantiationException e) {
// e.printStackTrace();
// } catch (IllegalAccessException e) {
// e.printStackTrace();
// }
List
<
NameValuePair
>
params
=
BeanUtil
.
convertBeanToNameValuePairList
(
obj
);
//拼接请求url
URI
build
=
null
;
try
{
build
=
new
URIBuilder
(
requestUrl
).
addParameters
(
params
).
build
();
}
catch
(
URISyntaxException
e
)
{
e
.
printStackTrace
();
}
return
build
.
toString
();
}
}
liquidnet-bus-common/liquidnet-common-third/liquidnet-common-third-zxlnft/src/main/java/com/liquidnet/common/third/zxlnft/constant/ZxlnftConstant.java
View file @
ff4314e4
...
...
@@ -240,4 +240,8 @@ public class ZxlnftConstant {
* NFT 售价变更状态查询(方案一)
*/
public
static
String
ZXL_NFT_053_PRICE_UPDATE_RESULT_URL
=
"/api/v1/nft/price/update/result"
;
/**
* 检查地址是否属于同一个用户主体(方案一)
*/
public
static
String
ZXL_NFT_054_PRICE_UPDATE_RESULT_URL
=
"/api/v1/nft/query/user/address/belong_to_user"
;
}
liquidnet-bus-common/liquidnet-common-third/liquidnet-common-third-zxlnft/src/main/java/com/liquidnet/common/third/zxlnft/dto/Nft034PublishReqDto.java
0 → 100644
View file @
ff4314e4
package
com
.
liquidnet
.
common
.
third
.
zxlnft
.
dto
;
import
lombok.Data
;
import
java.io.Serializable
;
/**
* @author AnJiabin <anjiabin@zhengzai.tv>
* @version V1.0
* @Description: 34.发行 NFT
* @class: PublishReq
* @Package com.liquidnet.common.third.zxlnft.dto.nft
* @Copyright: LightNet @ Copyright (c) 2021
* @date 2022/2/18 15:45
*/
@Data
public
class
Nft034PublishReqDto
implements
Serializable
{
/**
* 作者名,中文+英文(数字或符号为非法输入) 不超过30个字符
*/
private
String
author
;
/**
* nft名字,中英文数字均可,不超过256个字符
*/
private
String
name
;
/**
* 介质url,不超过1024个字符
*/
private
String
url
;
/**
* 预览图url,不超过1024个字符。(至信链浏览器展示预览图尺寸为290*290,请上传比例为1:1的图片)
*/
private
String
displayUrl
;
/**
* nft简介,500个字符以内
*/
// @Null(message = "nft简介,500个字符以内")
private
String
desc
;
/**
* 标签,【文创】,游戏,动漫,30个字符以内
* 非必填
*/
private
String
flag
;
/**
* 发行量,如果没有系列,就只能为1,如果有系列从1开始,比如如有100个,系列id范围则为[1-100],单次发行个数不超过1000,
* 同系列下同介质个数总共不能超过3000
*/
private
Long
publishCount
;
/**
* 系列ID
*/
// @Null (message = "系列ID")
private
String
seriesId
;
/**
* 系列子ID从多少开始,没有系列只能填1。有系列情况下,根据系列声明时指定
* seriesBeginFromZero决定是否可以从0开始。总体上不超过系列的最大值,
* (比如系列如果从1开始,最大值为100。系列ID只能从1-100)
*/
private
Integer
seriesBeginIndex
;
/**
* 1:可售 2:不可售
*/
private
Integer
sellStatus
;
/**
* 可售状态下有意义,表示售卖多少积分
*/
// @Null(message = "可售状态下有意义,表示售卖多少积分")
private
Long
sellCount
;
/**
* 请求ID,每个请求需要填唯一的ID,重复请求用相同的ID,为了保证唯一性,必须使用uuid
*/
private
String
operateId
;
/**
* 扩展字段,用户自定义,长度不超过1024个字符
*/
// @Null(message = "扩展字段")
private
String
metaData
;
private
static
final
Nft034PublishReqDto
obj
=
new
Nft034PublishReqDto
();
private
static
final
long
serialVersionUID
=
-
6804495011501136941L
;
public
static
Nft034PublishReqDto
getNew
()
{
try
{
return
(
Nft034PublishReqDto
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
Nft034PublishReqDto
();
}
}
}
liquidnet-bus-common/liquidnet-common-third/liquidnet-common-third-zxlnft/src/main/java/com/liquidnet/common/third/zxlnft/dto/Nft034PublishRespDto.java
0 → 100644
View file @
ff4314e4
package
com
.
liquidnet
.
common
.
third
.
zxlnft
.
dto
;
import
com.liquidnet.commons.lang.util.JsonUtils
;
import
lombok.Data
;
import
java.io.Serializable
;
/**
* @author AnJiabin <anjiabin@zhengzai.tv>
* @version V1.0
* @Description: TODO
* @class: PublishReq
* @Package com.liquidnet.common.third.zxlnft.dto.nft
* @Copyright: LightNet @ Copyright (c) 2021
* @date 2022/2/18 15:45
*/
@Data
public
class
Nft034PublishRespDto
implements
Serializable
{
/**
* 任务ID
*/
private
String
taskId
;
private
static
final
Nft034PublishRespDto
obj
=
new
Nft034PublishRespDto
();
public
static
Nft034PublishRespDto
getNew
()
{
try
{
return
(
Nft034PublishRespDto
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
Nft034PublishRespDto
();
}
}
@Override
public
String
toString
(){
return
JsonUtils
.
toJson
(
this
);
}
}
liquidnet-bus-common/liquidnet-common-third/liquidnet-common-third-zxlnft/src/main/java/com/liquidnet/common/third/zxlnft/dto/nft/Nft054QueryUserAddressBelongToUserReq.java
View file @
ff4314e4
...
...
@@ -7,7 +7,7 @@ import java.io.Serializable;
/**
* @author AnJiabin <anjiabin@zhengzai.tv>
* @version V1.0
* @Description: 检查地址是否属于同一个用户主体接口
* @Description: 检查地址是否属于同一个用户主体接口
GET请求方式
* GET请求方式
* @class: Nft054QueryUserAddressBelongToUser
* @Package com.liquidnet.common.third.zxlnft.dto.nft
...
...
liquidnet-bus-common/liquidnet-common-third/liquidnet-common-third-zxlnft/src/main/java/com/liquidnet/common/third/zxlnft/service/impl/ZxlnftSdkServiceImpl.java
View file @
ff4314e4
package
com
.
liquidnet
.
common
.
third
.
zxlnft
.
service
.
impl
;
import
com.alibaba.fastjson.JSONObject
;
import
com.liquidnet.common.third.zxlnft.biz.ZxlnftBiz
;
import
com.liquidnet.common.third.zxlnft.config.ZxlnftConfig
;
import
com.liquidnet.common.third.zxlnft.constant.ZxlnftConstant
;
...
...
@@ -8,20 +7,14 @@ import com.liquidnet.common.third.zxlnft.dto.nft.*;
import
com.liquidnet.common.third.zxlnft.service.ZxlnftSdkService
;
import
com.liquidnet.commons.lang.util.BeanUtil
;
import
com.liquidnet.commons.lang.util.HttpUtil
;
import
com.liquidnet.commons.lang.util.StringUtil
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.http.NameValuePair
;
import
org.apache.http.client.utils.URIBuilder
;
import
org.apache.http.message.BasicNameValuePair
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.LinkedMultiValueMap
;
import
org.springframework.util.MultiValueMap
;
import
org.springframework.web.client.HttpClientErrorException
;
import
java.net.URI
;
import
java.net.URISyntaxException
;
import
java.util.ArrayList
;
import
java.util.List
;
...
...
@@ -37,374 +30,1158 @@ public class ZxlnftSdkServiceImpl implements ZxlnftSdkService
private
MultiValueMap
<
String
,
String
>
commonHeader
=
new
LinkedMultiValueMap
();
// @Override
// public Nft001RegisterVerifyCodeResp nft001RegisterVerifyCode(Nft001RegisterVerifyCodeReq req) {
// zxlnftBiz.buildHeader(commonHeader);
//
// JSONObject json = new JSONObject();
// json.put("mobile", req.get);
// json.put("apKey", req.getAppKey());
//
// String requestUrl = zxlnftConfig.getNftApiUrl() + ZxlnftConstant.ZXL_NFT_016_IDENTITY_BIND_QUERY_URL;
// log.info("nft001RegisterVerifyCode--->>> request url : {} body : {} ",requestUrl, params.toString());
//
// String response = null;
//// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
// try {
// response = HttpUtil.postJson(requestUrl,json.toString(),commonHeader);
// } catch(HttpClientErrorException e) {
// log.error("nft001RegisterVerifyCode error", e);
// }catch (Exception e) {
// log.error("nft001RegisterVerifyCode error",e);
// }
// log.info("nft001RegisterVerifyCode--->>> response : {} ",response);
//
// if (StringUtils.isEmpty(response)) {
// return null;
// }
//
// Nft001RegisterVerifyCodeResp resp = Nft001RegisterVerifyCodeResp.getNew();
// JSONObject json = JSONObject.parseObject(response);
// if (json.containsKey("retCode") && json.containsKey("data") && json.getInteger("retCode").intValue() == 0) {
// JSONObject data = json.getJSONObject("data");
// resp = JsonUtils.fromJson(data.toJSONString(),Nft001RegisterVerifyCodeResp.class);
// }else {
// if (json.containsKey("retCode") && json.getInteger("retCode").intValue() != 0) {
// throw new ZxlNftException(String.valueOf(json.getInteger("retCode")), json.getString("retMsg") + ", address:" + req.getAddressList());
// }
// throw new ZxlNftException(json.getString("retCode"), json.getString("retMsg") + ", address:" + req.getAddressList());
// }
//
// log.info("nft001RegisterVerifyCode--->>> return result : {} ",resp.toString());
// return resp;
// }
@Override
public
Nft001RegisterVerifyCodeResp
nft001RegisterVerifyCode
(
Nft001RegisterVerifyCodeReq
req
)
{
return
null
;
}
@Override
public
Nft002RegisterPersonResp
nft002RegisterPerson
(
Nft002RegisterPersonReq
req
)
{
return
null
;
}
zxlnftBiz
.
buildHeader
(
commonHeader
);
@Override
public
Nft003RegisterPersonPlatformResp
nft003RegisterPersonPlatform
(
Nft003RegisterPersonPlatformReq
req
)
{
return
null
;
}
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
@Override
public
Nft004BusinessLicenseUploadResp
nft004BusinessLicenseUpload
(
Nft004BusinessLicenseUploadReq
req
)
{
return
null
;
}
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_001_REGISTER_VERIFY_CODE_URL
;
log
.
info
(
"nft001RegisterVerifyCode--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
@Override
public
Nft005BusinessLicenseUploadPlatformResp
nft005BusinessLicenseUploadPlatform
(
Nft005BusinessLicenseUploadPlatformReq
req
)
{
return
null
;
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft001RegisterVerifyCode error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft001RegisterVerifyCode error"
,
e
);
}
log
.
info
(
"nft001RegisterVerifyCode--->>> response : {} "
,
response
);
@Override
public
Nft006OfficialLetterUploadResp
nft006OfficialLetterUpload
(
Nft006OfficialLetterUploadReq
req
)
{
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
@Override
public
Nft007OfficialLetterUploadPlatformResp
nft007OfficialLetterUploadPlatform
(
Nft007OfficialLetterUploadPlatformReq
req
)
{
return
null
;
}
/**
* 构造返回结果
*/
Nft001RegisterVerifyCodeResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft001RegisterVerifyCodeResp
.
class
);
@Override
public
Nft008QueryImageModerationResp
nft008QueryImageModeration
(
Nft008QueryImageModerationReq
req
)
{
return
null
;
log
.
info
(
"nft001RegisterVerifyCode--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft009RegisterCompanyResp
nft009RegisterCompany
(
Nft009RegisterCompanyReq
req
)
{
return
null
;
}
public
Nft002RegisterPersonResp
nft002RegisterPerson
(
Nft002RegisterPersonReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
@Override
public
Nft010RegisterCompanyPlatformResp
nft010RegisterCompanyPlatform
(
Nft010RegisterCompanyPlatformReq
req
)
{
return
null
;
}
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
@Override
public
Nft011UserQueryVerifyCodeResp
nft011UserQueryVerifyCode
(
Nft011UserQueryVerifyCodeReq
req
)
{
return
null
;
}
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_002_REGISTER_PERSON_URL
;
log
.
info
(
"nft002RegisterPerson--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
@Override
public
Nft012UserQueryResp
nft012UserQuery
(
Nft012UserQueryReq
req
)
{
return
null
;
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft002RegisterPerson error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft002RegisterPerson error"
,
e
);
}
log
.
info
(
"nft002RegisterPerson--->>> response : {} "
,
response
);
@Override
public
Nft013IdentityBindSubmitResp
nft013IdentityBindSubmit
(
Nft013IdentityBindSubmitReq
req
)
{
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
@Override
public
Nft014IdentityBindSubmitByTrustedResp
nft014IdentityBindSubmitByTrusted
(
Nft014IdentityBindSubmitByTrustedReq
req
)
{
return
null
;
}
/**
* 构造返回结果
*/
Nft002RegisterPersonResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft002RegisterPersonResp
.
class
);
@Override
public
Nft015IdentityBindPlatformSelfResp
nft015IdentityBindPlatformSelf
(
Nft015IdentityBindPlatformSelfReq
req
)
{
return
null
;
log
.
info
(
"nft002RegisterPerson--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft0
16IdentityBindQueryResp
nft016IdentityBindQuery
(
Nft016IdentityBindQuery
Req
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
public
Nft0
03RegisterPersonPlatformResp
nft003RegisterPersonPlatform
(
Nft003RegisterPersonPlatform
Req
req
)
{
zxlnftBiz
.
build
PlatForm
Header
(
commonHeader
);
MultiValueMap
<
String
,
Object
>
params
=
new
LinkedMultiValueMap
();
List
<
String
>
addressList
=
new
ArrayList
();
addressList
.
add
(
req
.
getAddressList
());
params
.
add
(
"addressList"
,
addressList
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_0
16_IDENTITY_BIND_QUERY
_URL
;
log
.
info
(
"nft0
16IdentityBindQuery--->>> request url : {} body : {} "
,
requestUrl
,
params
.
toString
()
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_0
03_REGISTER_PERSON_PLATFORM
_URL
;
log
.
info
(
"nft0
03RegisterPersonPlatform--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
+
"?addressList="
+
req
.
getAddressList
(),
null
,
commonHeader
);
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft0
16IdentityBindQuery
error"
,
e
);
log
.
error
(
"nft0
03RegisterPersonPlatform
error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft0
16IdentityBindQuery
error"
,
e
);
log
.
error
(
"nft0
03RegisterPersonPlatform
error"
,
e
);
}
log
.
info
(
"nft0
16IdentityBindQuery
--->>> response : {} "
,
response
);
log
.
info
(
"nft0
03RegisterPersonPlatform
--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
// Nft016IdentityBindQueryResp resp = Nft016IdentityBindQueryResp.getNew();
// JSONObject json = JSONObject.parseObject(response);
// if (json.containsKey("retCode") && json.containsKey("data") && json.getInteger("retCode").intValue() == 0) {
// JSONObject data = json.getJSONObject("data");
// resp = JsonUtils.fromJson(data.toJSONString(),Nft016IdentityBindQueryResp.class);
// }else {
// if (json.containsKey("retCode") && json.getInteger("retCode").intValue() != 0) {
// throw new ZxlNftException(String.valueOf(json.getInteger("retCode")), json.getString("retMsg") + ", address:" + req.getAddressList());
// }
// throw new ZxlNftException(json.getString("retCode"), json.getString("retMsg") + ", address:" + req.getAddressList());
// }
/**
* 构造返回结果
*/
Nft0
16IdentityBindQueryResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft016IdentityBindQuery
Resp
.
class
);
Nft0
03RegisterPersonPlatformResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft003RegisterPersonPlatform
Resp
.
class
);
log
.
info
(
"nft0
16IdentityBindQuery
--->>> return result : {} "
,
resp
.
toString
());
log
.
info
(
"nft0
03RegisterPersonPlatform
--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft017IdentityVerifyIdentityResp
nft017IdentityVerifyIdentity
(
Nft017IdentityVerifyIdentityReq
req
)
{
return
null
;
}
public
Nft004BusinessLicenseUploadResp
nft004BusinessLicenseUpload
(
Nft004BusinessLicenseUploadReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
@Override
public
Nft018FaceUrlResp
nft018FaceUrl
(
Nft018FaceUrlReq
req
)
{
return
null
;
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_004_BUSINESS_LICENSE_UPLOAD_URL
;
log
.
info
(
"nft004BusinessLicenseUpload--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft004BusinessLicenseUpload error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft004BusinessLicenseUpload error"
,
e
);
}
log
.
info
(
"nft004BusinessLicenseUpload--->>> response : {} "
,
response
);
@Override
public
Nft019FaceUrlByAddressResp
nft019FaceUrlByAddress
(
Nft019FaceUrlByAddressReq
req
)
{
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
@Override
public
Nft020FaceQueryResp
nft020FaceQuery
(
Nft020FaceQueryReq
req
)
{
return
null
;
/**
* 构造返回结果
*/
Nft004BusinessLicenseUploadResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft004BusinessLicenseUploadResp
.
class
);
log
.
info
(
"nft004BusinessLicenseUpload--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft0
21UploadUrlResp
nft021UploadUrl
(
Nft021UploadUrl
Req
req
)
{
public
Nft0
05BusinessLicenseUploadPlatformResp
nft005BusinessLicenseUploadPlatform
(
Nft005BusinessLicenseUploadPlatform
Req
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
List
<
NameValuePair
>
params
=
new
ArrayList
<
NameValuePair
>();
if
(
StringUtil
.
isNotEmpty
(
req
.
getSeriesName
())){
params
.
add
(
new
BasicNameValuePair
(
"seriesName"
,
req
.
getSeriesName
()));
}
params
.
add
(
new
BasicNameValuePair
(
"platformIdentification"
,
req
.
getPlatformIdentification
()));
if
(
StringUtil
.
isNotEmpty
(
req
.
getUserIdentification
())){
params
.
add
(
new
BasicNameValuePair
(
"userIdentification"
,
req
.
getUserIdentification
()));
}
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_021_UPLOAD_URL_URL
;
log
.
info
(
"nft021UploadUrl--->>> request url : {} body : {} "
,
requestUrl
,
params
.
toString
());
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
//拼接请求url
URI
build
=
null
;
try
{
build
=
new
URIBuilder
(
requestUrl
).
addParameters
(
params
).
build
();
}
catch
(
URISyntaxException
e
)
{
e
.
printStackTrace
();
}
requestUrl
=
build
.
toString
();
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_005_BUSINESS_LICENSE_UPLOAD_PLATFORM_URL
;
log
.
info
(
"nft005BusinessLicenseUploadPlatform--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft0
21UploadUrl
error"
,
e
);
log
.
error
(
"nft0
05BusinessLicenseUploadPlatform
error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft0
21UploadUrl
error"
,
e
);
log
.
error
(
"nft0
05BusinessLicenseUploadPlatform
error"
,
e
);
}
log
.
info
(
"nft0
21UploadUrl
--->>> response : {} "
,
response
);
log
.
info
(
"nft0
05BusinessLicenseUploadPlatform
--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
// Nft016IdentityBindQueryResp resp = Nft016IdentityBindQueryResp.getNew();
// JSONObject json = JSONObject.parseObject(response);
// if (json.containsKey("retCode") && json.containsKey("data") && json.getInteger("retCode").intValue() == 0) {
// JSONObject data = json.getJSONObject("data");
// resp = JsonUtils.fromJson(data.toJSONString(),Nft016IdentityBindQueryResp.class);
// }else {
// if (json.containsKey("retCode") && json.getInteger("retCode").intValue() != 0) {
// throw new ZxlNftException(String.valueOf(json.getInteger("retCode")), json.getString("retMsg") + ", address:" + req.getAddressList());
// }
// throw new ZxlNftException(json.getString("retCode"), json.getString("retMsg") + ", address:" + req.getAddressList());
// }
/**
* 构造返回结果
*/
Nft0
21UploadUrlResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft021UploadUrl
Resp
.
class
);
Nft0
05BusinessLicenseUploadPlatformResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft005BusinessLicenseUploadPlatform
Resp
.
class
);
log
.
info
(
"nft0
21UploadUrl
--->>> return result : {} "
,
resp
.
toString
());
log
.
info
(
"nft0
05BusinessLicenseUploadPlatform
--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft022UploadSecretResp
nft022UploadSecret
(
Nft022UploadSecretReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
// MultiValueMap<String, Object> params = new LinkedMultiValueMap();
// List<String> addressList = new ArrayList();
// if(StringUtil.isNotEmpty(req.getSeriesName())){
// params.add("seriesName", req.getSeriesName());
// }
// params.add("tiemstamp", req.getTiemstamp());
// params.add("pubKey", req.getPubKey());
// params.add("pubSignedData", req.getPubSignedData());
// params.add("userPubKey", req.getUserPubKey());
// params.add("userSignedData", req.getUserSignedData());
public
Nft006OfficialLetterUploadResp
nft006OfficialLetterUpload
(
Nft006OfficialLetterUploadReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
JSONObject
json
=
new
JSONObject
();
if
(
StringUtil
.
isNotEmpty
(
req
.
getSeriesName
())){
json
.
put
(
"seriesName"
,
req
.
getSeriesName
());
}
json
.
put
(
"timestamp"
,
req
.
getTimestamp
());
json
.
put
(
"pubKey"
,
req
.
getPubKey
());
json
.
put
(
"pubSignedData"
,
req
.
getPubSignedData
());
json
.
put
(
"userPubKey"
,
req
.
getUserPubKey
());
json
.
put
(
"userSignedData"
,
req
.
getUserSignedData
());
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_0
22_UPLOAD_SECRET
_URL
;
log
.
info
(
"nft0
22UploadSecret--->>> request url : {} body : {} "
,
requestUrl
,
json
.
toString
()
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_0
06_OFFICIAL_LETTER_UPLOAD
_URL
;
log
.
info
(
"nft0
06OfficialLetterUpload--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
json
.
toString
()
,
commonHeader
);
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft0
22UploadSecret
error"
,
e
);
log
.
error
(
"nft0
06OfficialLetterUpload
error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft0
22UploadSecret
error"
,
e
);
log
.
error
(
"nft0
06OfficialLetterUpload
error"
,
e
);
}
log
.
info
(
"nft0
22UploadSecret
--->>> response : {} "
,
response
);
log
.
info
(
"nft0
06OfficialLetterUpload
--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft022UploadSecretResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft022UploadSecretResp
.
class
);
log
.
info
(
"nft022UploadSecret--->>> return result : {} "
,
resp
.
toString
());
Nft006OfficialLetterUploadResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft006OfficialLetterUploadResp
.
class
);
log
.
info
(
"nft006OfficialLetterUpload--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft023PointApplyResp
nft023PointApply
(
Nft023PointApplyReq
req
)
{
return
null
;
}
public
Nft007OfficialLetterUploadPlatformResp
nft007OfficialLetterUploadPlatform
(
Nft007OfficialLetterUploadPlatformReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
@Override
public
Nft024PointApplyResultResp
nft024PointApplyResult
(
Nft024PointApplyResultReq
req
)
{
return
null
;
}
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
@Override
public
Nft025PointTransferResp
nft025PointTransfer
(
Nft025PointTransferReq
req
)
{
return
null
;
}
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_007_OFFICIAL_LETTER_UPLOAD_PLATFORM_URL
;
log
.
info
(
"nft007OfficialLetterUploadPlatform--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
@Override
public
Nft026PointTransferResultResp
nft026PointTransferResult
(
Nft026PointTransferResultReq
req
)
{
return
null
;
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft007OfficialLetterUploadPlatform error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft007OfficialLetterUploadPlatform error"
,
e
);
}
log
.
info
(
"nft007OfficialLetterUploadPlatform--->>> response : {} "
,
response
);
@Override
public
Nft027PointDestroyResp
nft027PointDestroy
(
Nft027PointDestroyReq
req
)
{
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
@Override
public
Nft028PointDestoryResultResp
nft028PointDestoryResult
(
Nft028PointDestoryResultReq
req
)
{
return
null
;
}
/**
* 构造返回结果
*/
Nft007OfficialLetterUploadPlatformResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft007OfficialLetterUploadPlatformResp
.
class
);
@Override
public
Nft029PointQueryResp
nft029PointQuery
(
Nft029PointQueryReq
req
)
{
return
null
;
log
.
info
(
"nft007OfficialLetterUploadPlatform--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft030SeriesClaimResp
nft030SeriesClaim
(
Nft030SeriesClaimReq
req
)
{
return
null
;
}
public
Nft008QueryImageModerationResp
nft008QueryImageModeration
(
Nft008QueryImageModerationReq
req
)
{
@Override
public
Nft031SeriesClaimResultResp
nft031SeriesClaimResult
(
Nft031SeriesClaimResultReq
req
)
{
return
null
;
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_008_QUERY_IMAGE_MODERATION_URL
;
log
.
info
(
"nft008QueryImageModeration--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft008QueryImageModeration error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft008QueryImageModeration error"
,
e
);
}
log
.
info
(
"nft008QueryImageModeration--->>> response : {} "
,
response
);
@Override
public
Nft032SeriesResp
nft032Series
(
Nft032SeriesReq
req
)
{
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
@Override
public
Nft033SeriesListResp
nft033SeriesList
(
Nft033SeriesListReq
req
)
{
return
null
;
/**
* 构造返回结果
*/
Nft008QueryImageModerationResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft008QueryImageModerationResp
.
class
);
log
.
info
(
"nft008QueryImageModeration--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft034PublishResp
nft034Publish
(
Nft034PublishReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
public
Nft009RegisterCompanyResp
nft009RegisterCompany
(
Nft009RegisterCompanyReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_0
34_PUBLISH
_URL
;
log
.
info
(
"nft0
34Publish--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_0
09_REGISTER_COMPANY
_URL
;
log
.
info
(
"nft0
09RegisterCompany--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft0
34Publish
error"
,
e
);
log
.
error
(
"nft0
09RegisterCompany
error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft0
34Publish
error"
,
e
);
log
.
error
(
"nft0
09RegisterCompany
error"
,
e
);
}
log
.
info
(
"nft034Publish--->>> response : {} "
,
response
);
log
.
info
(
"nft009RegisterCompany--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft009RegisterCompanyResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft009RegisterCompanyResp
.
class
);
log
.
info
(
"nft009RegisterCompany--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft010RegisterCompanyPlatformResp
nft010RegisterCompanyPlatform
(
Nft010RegisterCompanyPlatformReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_010_REGISTER_COMPANY_PLATFORM_URL
;
log
.
info
(
"nft010RegisterCompanyPlatform--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft010RegisterCompanyPlatform error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft010RegisterCompanyPlatform error"
,
e
);
}
log
.
info
(
"nft010RegisterCompanyPlatform--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft010RegisterCompanyPlatformResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft010RegisterCompanyPlatformResp
.
class
);
log
.
info
(
"nft010RegisterCompanyPlatform--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft011UserQueryVerifyCodeResp
nft011UserQueryVerifyCode
(
Nft011UserQueryVerifyCodeReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_011_USER_QUERY_VERIFY_CODE_URL
;
log
.
info
(
"nft011UserQueryVerifyCode--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft011UserQueryVerifyCode error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft011UserQueryVerifyCode error"
,
e
);
}
log
.
info
(
"nft011UserQueryVerifyCode--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft011UserQueryVerifyCodeResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft011UserQueryVerifyCodeResp
.
class
);
log
.
info
(
"nft011UserQueryVerifyCode--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft012UserQueryResp
nft012UserQuery
(
Nft012UserQueryReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_012_USER_QUERY_URL
;
log
.
info
(
"nft012UserQuery--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft012UserQuery--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft012UserQuery error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft012UserQuery error"
,
e
);
}
log
.
info
(
"nft012UserQuery--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft012UserQueryResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft012UserQueryResp
.
class
);
log
.
info
(
"nft012UserQuery--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft013IdentityBindSubmitResp
nft013IdentityBindSubmit
(
Nft013IdentityBindSubmitReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_013_IDENTITY_BIND_SUBMIT_URL
;
log
.
info
(
"nft013IdentityBindSubmit--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft013IdentityBindSubmit error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft013IdentityBindSubmit error"
,
e
);
}
log
.
info
(
"nft013IdentityBindSubmit--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft013IdentityBindSubmitResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft013IdentityBindSubmitResp
.
class
);
log
.
info
(
"nft013IdentityBindSubmit--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft014IdentityBindSubmitByTrustedResp
nft014IdentityBindSubmitByTrusted
(
Nft014IdentityBindSubmitByTrustedReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_014_IDENTITY_BIND_SUBMIT_BY_TRUSTED_URL
;
log
.
info
(
"nft014IdentityBindSubmitByTrusted--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft014IdentityBindSubmitByTrusted error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft014IdentityBindSubmitByTrusted error"
,
e
);
}
log
.
info
(
"nft014IdentityBindSubmitByTrusted--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft014IdentityBindSubmitByTrustedResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft014IdentityBindSubmitByTrustedResp
.
class
);
log
.
info
(
"nft014IdentityBindSubmitByTrusted--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft015IdentityBindPlatformSelfResp
nft015IdentityBindPlatformSelf
(
Nft015IdentityBindPlatformSelfReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_015_IDENTITY_BIND_PLATFORM_SELF_URL
;
log
.
info
(
"nft015IdentityBindPlatformSelf--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft015IdentityBindPlatformSelf error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft015IdentityBindPlatformSelf error"
,
e
);
}
log
.
info
(
"nft015IdentityBindPlatformSelf--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft015IdentityBindPlatformSelfResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft015IdentityBindPlatformSelfResp
.
class
);
log
.
info
(
"nft015IdentityBindPlatformSelf--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft016IdentityBindQueryResp
nft016IdentityBindQuery
(
Nft016IdentityBindQueryReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
MultiValueMap
<
String
,
Object
>
params
=
new
LinkedMultiValueMap
();
List
<
String
>
addressList
=
new
ArrayList
();
addressList
.
add
(
req
.
getAddressList
());
params
.
add
(
"addressList"
,
addressList
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_016_IDENTITY_BIND_QUERY_URL
;
log
.
info
(
"nft016IdentityBindQuery--->>> request url : {} body : {} "
,
requestUrl
,
params
.
toString
());
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
+
"?addressList="
+
req
.
getAddressList
(),
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft016IdentityBindQuery error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft016IdentityBindQuery error"
,
e
);
}
log
.
info
(
"nft016IdentityBindQuery--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft016IdentityBindQueryResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft016IdentityBindQueryResp
.
class
);
log
.
info
(
"nft016IdentityBindQuery--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft017IdentityVerifyIdentityResp
nft017IdentityVerifyIdentity
(
Nft017IdentityVerifyIdentityReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_017_IDENTITY_VERIFY_IDENTITY_URL
;
log
.
info
(
"nft017IdentityVerifyIdentity--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft017IdentityVerifyIdentity error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft017IdentityVerifyIdentity error"
,
e
);
}
log
.
info
(
"nft017IdentityVerifyIdentity--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft017IdentityVerifyIdentityResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft017IdentityVerifyIdentityResp
.
class
);
log
.
info
(
"nft017IdentityVerifyIdentity--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft018FaceUrlResp
nft018FaceUrl
(
Nft018FaceUrlReq
req
){
zxlnftBiz
.
buildHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_018_FACE_URL_URL
;
log
.
info
(
"nft018FaceUrl--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft018FaceUrl error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft018FaceUrl error"
,
e
);
}
log
.
info
(
"nft018FaceUrl--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft018FaceUrlResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft018FaceUrlResp
.
class
);
log
.
info
(
"nft018FaceUrl--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft019FaceUrlByAddressResp
nft019FaceUrlByAddress
(
Nft019FaceUrlByAddressReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_019_FACE_URL_BY_ADDRESS_URL
;
log
.
info
(
"nft019FaceUrlByAddress--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft019FaceUrlByAddress error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft019FaceUrlByAddress error"
,
e
);
}
log
.
info
(
"nft019FaceUrlByAddress--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft019FaceUrlByAddressResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft019FaceUrlByAddressResp
.
class
);
log
.
info
(
"nft019FaceUrlByAddress--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft020FaceQueryResp
nft020FaceQuery
(
Nft020FaceQueryReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_020_FACE_QUERY_URL
;
log
.
info
(
"nft020FaceQuery--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft020FaceQuery--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft020FaceQuery error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft020FaceQuery error"
,
e
);
}
log
.
info
(
"nft020FaceQuery--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft020FaceQueryResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft020FaceQueryResp
.
class
);
log
.
info
(
"nft020FaceQuery--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft021UploadUrlResp
nft021UploadUrl
(
Nft021UploadUrlReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_021_UPLOAD_URL_URL
;
log
.
info
(
"nft021UploadUrl--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft021UploadUrl--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft021UploadUrl error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft021UploadUrl error"
,
e
);
}
log
.
info
(
"nft021UploadUrl--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft021UploadUrlResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft021UploadUrlResp
.
class
);
log
.
info
(
"nft021UploadUrl--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft022UploadSecretResp
nft022UploadSecret
(
Nft022UploadSecretReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
// MultiValueMap<String, Object> params = new LinkedMultiValueMap();
// List<String> addressList = new ArrayList();
// if(StringUtil.isNotEmpty(req.getSeriesName())){
// params.add("seriesName", req.getSeriesName());
// }
// params.add("tiemstamp", req.getTiemstamp());
// params.add("pubKey", req.getPubKey());
// params.add("pubSignedData", req.getPubSignedData());
// params.add("userPubKey", req.getUserPubKey());
// params.add("userSignedData", req.getUserSignedData());
// JSONObject json = new JSONObject();
// if(StringUtil.isNotEmpty(req.getSeriesName())){
// json.put("seriesName", req.getSeriesName());
// }
// json.put("timestamp", req.getTimestamp());
// json.put("pubKey", req.getPubKey());
// json.put("pubSignedData", req.getPubSignedData());
// json.put("userPubKey", req.getUserPubKey());
// json.put("userSignedData", req.getUserSignedData());
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_022_UPLOAD_SECRET_URL
;
log
.
info
(
"nft022UploadSecret--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft022UploadSecret error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft022UploadSecret error"
,
e
);
}
log
.
info
(
"nft022UploadSecret--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft022UploadSecretResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft022UploadSecretResp
.
class
);
log
.
info
(
"nft022UploadSecret--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft023PointApplyResp
nft023PointApply
(
Nft023PointApplyReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_023_POINT_APPLY_URL
;
log
.
info
(
"nft023PointApply--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft023PointApply error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft023PointApply error"
,
e
);
}
log
.
info
(
"nft023PointApply--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft023PointApplyResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft023PointApplyResp
.
class
);
log
.
info
(
"nft023PointApply--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft024PointApplyResultResp
nft024PointApplyResult
(
Nft024PointApplyResultReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_024_POINT_APPLY_RESULT_URL
;
log
.
info
(
"nft024PointApplyResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft024PointApplyResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft024PointApplyResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft024PointApplyResult error"
,
e
);
}
log
.
info
(
"nft024PointApplyResult--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft024PointApplyResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft024PointApplyResultResp
.
class
);
log
.
info
(
"nft024PointApplyResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft025PointTransferResp
nft025PointTransfer
(
Nft025PointTransferReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_025_POINT_TRANSFER_URL
;
log
.
info
(
"nft025PointTransfer--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft025PointTransfer error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft025PointTransfer error"
,
e
);
}
log
.
info
(
"nft025PointTransfer--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft025PointTransferResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft025PointTransferResp
.
class
);
log
.
info
(
"nft025PointTransfer--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft026PointTransferResultResp
nft026PointTransferResult
(
Nft026PointTransferResultReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_026_POINT_TRANSFER_RESULT_URL
;
log
.
info
(
"nft026PointTransferResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft026PointTransferResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft026PointTransferResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft026PointTransferResult error"
,
e
);
}
log
.
info
(
"nft026PointTransferResult--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft026PointTransferResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft026PointTransferResultResp
.
class
);
log
.
info
(
"nft026PointTransferResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft027PointDestroyResp
nft027PointDestroy
(
Nft027PointDestroyReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_027_POINT_DESTROY_URL
;
log
.
info
(
"nft027PointDestroy--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft027PointDestroy error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft027PointDestroy error"
,
e
);
}
log
.
info
(
"nft027PointDestroy--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft027PointDestroyResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft027PointDestroyResp
.
class
);
log
.
info
(
"nft027PointDestroy--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft028PointDestoryResultResp
nft028PointDestoryResult
(
Nft028PointDestoryResultReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_028_POINT_DESTORY_RESULT_URL
;
log
.
info
(
"nft028PointDestoryResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft028PointDestoryResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft028PointDestoryResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft028PointDestoryResult error"
,
e
);
}
log
.
info
(
"nft028PointDestoryResult--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft028PointDestoryResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft028PointDestoryResultResp
.
class
);
log
.
info
(
"nft028PointDestoryResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft029PointQueryResp
nft029PointQuery
(
Nft029PointQueryReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_029_POINT_QUERY_URL
;
log
.
info
(
"nft029PointQuery--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft029PointQuery--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft029PointQuery error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft029PointQuery error"
,
e
);
}
log
.
info
(
"nft029PointQuery--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft029PointQueryResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft029PointQueryResp
.
class
);
log
.
info
(
"nft029PointQuery--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft030SeriesClaimResp
nft030SeriesClaim
(
Nft030SeriesClaimReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_030_SERIES_CLAIM_URL
;
log
.
info
(
"nft030SeriesClaim--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft030SeriesClaim error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft030SeriesClaim error"
,
e
);
}
log
.
info
(
"nft030SeriesClaim--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft030SeriesClaimResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft030SeriesClaimResp
.
class
);
log
.
info
(
"nft030SeriesClaim--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft031SeriesClaimResultResp
nft031SeriesClaimResult
(
Nft031SeriesClaimResultReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_031_SERIES_CLAIM_RESULT_URL
;
log
.
info
(
"nft031SeriesClaimResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft031SeriesClaimResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft031SeriesClaimResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft031SeriesClaimResult error"
,
e
);
}
log
.
info
(
"nft031SeriesClaimResult--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft031SeriesClaimResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft031SeriesClaimResultResp
.
class
);
log
.
info
(
"nft031SeriesClaimResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft032SeriesResp
nft032Series
(
Nft032SeriesReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_032_SERIES_URL
;
log
.
info
(
"nft032Series--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft032Series--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft032Series error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft032Series error"
,
e
);
}
log
.
info
(
"nft032Series--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft032SeriesResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft032SeriesResp
.
class
);
log
.
info
(
"nft032Series--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft033SeriesListResp
nft033SeriesList
(
Nft033SeriesListReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_033_SERIES_LIST_URL
;
log
.
info
(
"nft033SeriesList--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft033SeriesList--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft033SeriesList error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft033SeriesList error"
,
e
);
}
log
.
info
(
"nft033SeriesList--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft033SeriesListResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft033SeriesListResp
.
class
);
log
.
info
(
"nft033SeriesList--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft034PublishResp
nft034Publish
(
Nft034PublishReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_034_PUBLISH_URL
;
log
.
info
(
"nft034Publish--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft034Publish error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft034Publish error"
,
e
);
}
log
.
info
(
"nft034Publish--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
...
...
@@ -438,103 +1215,684 @@ public class ZxlnftSdkServiceImpl implements ZxlnftSdkService
// json.put("platformSignature", req.getPlatformSignature());
}
@Override
public
Nft035PublishResultResp
nft035PublishResult
(
Nft035PublishResultReq
req
)
{
return
null
;
@Override
public
Nft035PublishResultResp
nft035PublishResult
(
Nft035PublishResultReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_035_PUBLISH_RESULT_URL
;
log
.
info
(
"nft035PublishResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft035PublishResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft035PublishResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft035PublishResult error"
,
e
);
}
log
.
info
(
"nft035PublishResult--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft035PublishResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft035PublishResultResp
.
class
);
log
.
info
(
"nft035PublishResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft036InfoResp
nft036Info
(
Nft036InfoReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_036_INFO_URL
;
log
.
info
(
"nft036Info--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft036Info--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft036Info error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft036Info error"
,
e
);
}
log
.
info
(
"nft036Info--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft036InfoResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft036InfoResp
.
class
);
log
.
info
(
"nft036Info--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft037AddressListResp
nft037AddressList
(
Nft037AddressListReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_037_ADDRESS_LIST_URL
;
log
.
info
(
"nft037AddressList--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft037AddressList--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft037AddressList error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft037AddressList error"
,
e
);
}
log
.
info
(
"nft037AddressList--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft037AddressListResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft037AddressListResp
.
class
);
log
.
info
(
"nft037AddressList--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft038AddressWithoutSeriesListResp
nft038AddressWithoutSeriesList
(
Nft038AddressWithoutSeriesListReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_038_ADDRESS_WITHOUT_SERIES_LIST_URL
;
log
.
info
(
"nft038AddressWithoutSeriesList--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft038AddressWithoutSeriesList--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft038AddressWithoutSeriesList error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft038AddressWithoutSeriesList error"
,
e
);
}
log
.
info
(
"nft038AddressWithoutSeriesList--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft038AddressWithoutSeriesListResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft038AddressWithoutSeriesListResp
.
class
);
log
.
info
(
"nft038AddressWithoutSeriesList--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft039TradeListResp
nft039TradeList
(
Nft039TradeListReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_039_TRADE_LIST_URL
;
log
.
info
(
"nft039TradeList--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft039TradeList--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft039TradeList error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft039TradeList error"
,
e
);
}
log
.
info
(
"nft039TradeList--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft039TradeListResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft039TradeListResp
.
class
);
log
.
info
(
"nft039TradeList--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft040TradeInListResp
nft040TradeInList
(
Nft040TradeInListReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_040_TRADE_IN_LIST_URL
;
log
.
info
(
"nft040TradeInList--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft040TradeInList--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft040TradeInList error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft040TradeInList error"
,
e
);
}
log
.
info
(
"nft040TradeInList--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft040TradeInListResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft040TradeInListResp
.
class
);
log
.
info
(
"nft040TradeInList--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft041TradeOutListResp
nft041TradeOutList
(
Nft041TradeOutListReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_041_TRADE_OUT_LIST_URL
;
log
.
info
(
"nft041TradeOutList--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft041TradeOutList--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft041TradeOutList error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft041TradeOutList error"
,
e
);
}
log
.
info
(
"nft041TradeOutList--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft041TradeOutListResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft041TradeOutListResp
.
class
);
log
.
info
(
"nft041TradeOutList--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft042TradeAllListResp
nft042TradeAllList
(
Nft042TradeAllListReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_042_TRADE_ALL_LIST_URL
;
log
.
info
(
"nft042TradeAllList--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft042TradeAllList--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft042TradeAllList error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft042TradeAllList error"
,
e
);
}
log
.
info
(
"nft042TradeAllList--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft042TradeAllListResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft042TradeAllListResp
.
class
);
log
.
info
(
"nft042TradeAllList--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft043BuyResp
nft043Buy
(
Nft043BuyReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_043_BUY_URL
;
log
.
info
(
"nft043Buy--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft043Buy error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft043Buy error"
,
e
);
}
log
.
info
(
"nft043Buy--->>> response : {} "
,
response
);
@Override
public
Nft036InfoResp
nft036Info
(
Nft036InfoReq
req
)
{
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft043BuyResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft043BuyResp
.
class
);
@Override
public
Nft037AddressListResp
nft037AddressList
(
Nft037AddressListReq
req
)
{
return
null
;
log
.
info
(
"nft043Buy--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft038AddressWithoutSeriesListResp
nft038AddressWithoutSeriesList
(
Nft038AddressWithoutSeriesListReq
req
)
{
return
null
;
public
Nft044BuyResultResp
nft044BuyResult
(
Nft044BuyResultReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_044_BUY_RESULT_URL
;
log
.
info
(
"nft044BuyResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft044BuyResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft044BuyResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft044BuyResult error"
,
e
);
}
log
.
info
(
"nft044BuyResult--->>> response : {} "
,
response
);
@Override
public
Nft039TradeListResp
nft039TradeList
(
Nft039TradeListReq
req
)
{
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft044BuyResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft044BuyResultResp
.
class
);
@Override
public
Nft040TradeInListResp
nft040TradeInList
(
Nft040TradeInListReq
req
)
{
return
null
;
log
.
info
(
"nft044BuyResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft041TradeOutListResp
nft041TradeOutList
(
Nft041TradeOutListReq
req
)
{
return
null
;
public
Nft045BuyPayResultResp
nft045BuyPayResult
(
Nft045BuyPayResultReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_045_BUY_PAY_RESULT_URL
;
log
.
info
(
"nft045BuyPayResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft045BuyPayResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft045BuyPayResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft045BuyPayResult error"
,
e
);
}
log
.
info
(
"nft045BuyPayResult--->>> response : {} "
,
response
);
@Override
public
Nft042TradeAllListResp
nft042TradeAllList
(
Nft042TradeAllListReq
req
)
{
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft045BuyPayResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft045BuyPayResultResp
.
class
);
@Override
public
Nft043BuyResp
nft043Buy
(
Nft043BuyReq
req
)
{
return
null
;
log
.
info
(
"nft045BuyPayResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft044BuyResultResp
nft044BuyResult
(
Nft044BuyResultReq
req
)
{
return
null
;
public
Nft046TransferResp
nft046Transfer
(
Nft046TransferReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_046_TRANSFER_URL
;
log
.
info
(
"nft046Transfer--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft046Transfer error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft046Transfer error"
,
e
);
}
log
.
info
(
"nft046Transfer--->>> response : {} "
,
response
);
@Override
public
Nft045BuyPayResultResp
nft045BuyPayResult
(
Nft045BuyPayResultReq
req
)
{
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
@Override
public
Nft046TransferResp
nft046Transfer
(
Nft046TransferReq
req
)
{
return
null
;
/**
* 构造返回结果
*/
Nft046TransferResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft046TransferResp
.
class
);
log
.
info
(
"nft046Transfer--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft047SelfTransferResp
nft047SelfTransfer
(
Nft047SelfTransferReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_047_SELF_TRANSFER_URL
;
log
.
info
(
"nft047SelfTransfer--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft047SelfTransfer error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft047SelfTransfer error"
,
e
);
}
log
.
info
(
"nft047SelfTransfer--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft047SelfTransferResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft047SelfTransferResp
.
class
);
log
.
info
(
"nft047SelfTransfer--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft048BatchTransferResp
nft048BatchTransfer
(
Nft048BatchTransferReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_048_BATCH_TRANSFER_URL
;
log
.
info
(
"nft048BatchTransfer--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft048BatchTransfer error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft048BatchTransfer error"
,
e
);
}
log
.
info
(
"nft048BatchTransfer--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft048BatchTransferResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft048BatchTransferResp
.
class
);
log
.
info
(
"nft048BatchTransfer--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft049TransferResultResp
nft049TransferResult
(
Nft049TransferResultReq
req
)
{
zxlnftBiz
.
buildHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_049_TRANSFER_RESULT_URL
;
log
.
info
(
"nft049TransferResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft049TransferResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft049TransferResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft049TransferResult error"
,
e
);
}
log
.
info
(
"nft049TransferResult--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft049TransferResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft049TransferResultResp
.
class
);
log
.
info
(
"nft049TransferResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft050StatusUpdateResp
nft050StatusUpdate
(
Nft050StatusUpdateReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_050_STATUS_UPDATE_URL
;
log
.
info
(
"nft050StatusUpdate--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft050StatusUpdate error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft050StatusUpdate error"
,
e
);
}
log
.
info
(
"nft050StatusUpdate--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft050StatusUpdateResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft050StatusUpdateResp
.
class
);
log
.
info
(
"nft050StatusUpdate--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft051StatusUpdateResultResp
nft051StatusUpdateResult
(
Nft051StatusUpdateResultReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_051_STATUS_UPDATE_RESULT_URL
;
log
.
info
(
"nft051StatusUpdateResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft051StatusUpdateResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft051StatusUpdateResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft051StatusUpdateResult error"
,
e
);
}
log
.
info
(
"nft051StatusUpdateResult--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft051StatusUpdateResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft051StatusUpdateResultResp
.
class
);
log
.
info
(
"nft051StatusUpdateResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft052PriceUpdateResp
nft052PriceUpdate
(
Nft052PriceUpdateReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
//构造请求参数
String
reqJsonStr
=
BeanUtil
.
convertBeanToJsonString
(
req
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_052_PRICE_UPDATE_URL
;
log
.
info
(
"nft052PriceUpdate--->>> request url : {} body : {} "
,
requestUrl
,
reqJsonStr
);
String
response
=
null
;
try
{
response
=
HttpUtil
.
postJson
(
requestUrl
,
reqJsonStr
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft052PriceUpdate error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft052PriceUpdate error"
,
e
);
}
log
.
info
(
"nft052PriceUpdate--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft052PriceUpdateResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft052PriceUpdateResp
.
class
);
log
.
info
(
"nft052PriceUpdate--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft053PriceUpdateResultResp
nft053PriceUpdateResult
(
Nft053PriceUpdateResultReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_053_PRICE_UPDATE_RESULT_URL
;
log
.
info
(
"nft053PriceUpdateResult--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft053PriceUpdateResult--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft053PriceUpdateResult error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft053PriceUpdateResult error"
,
e
);
}
log
.
info
(
"nft053PriceUpdateResult--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft053PriceUpdateResultResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft053PriceUpdateResultResp
.
class
);
log
.
info
(
"nft053PriceUpdateResult--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
@Override
public
Nft054QueryUserAddressBelongToUserResp
nft054QueryUserAddressBelongToUser
(
Nft054QueryUserAddressBelongToUserReq
req
)
{
zxlnftBiz
.
buildPlatFormHeader
(
commonHeader
);
String
requestUrl
=
zxlnftConfig
.
getNftApiUrl
()
+
ZxlnftConstant
.
ZXL_NFT_054_PRICE_UPDATE_RESULT_URL
;
log
.
info
(
"nft054QueryUserAddressBelongToUser--->>> request url : {} body : {} "
,
requestUrl
,
req
.
toString
());
requestUrl
=
zxlnftBiz
.
buildGetRequestUrl
(
requestUrl
,
Nft021UploadUrlReq
.
class
,
req
);
log
.
info
(
"nft054QueryUserAddressBelongToUser--->>> new request url : {} "
,
requestUrl
);
String
response
=
null
;
// ObjectNode objectNode = JsonUtils.OM().createObjectNode();
try
{
response
=
HttpUtil
.
get
(
requestUrl
,
null
,
commonHeader
);
}
catch
(
HttpClientErrorException
e
)
{
log
.
error
(
"nft054QueryUserAddressBelongToUser error"
,
e
);
}
catch
(
Exception
e
)
{
log
.
error
(
"nft054QueryUserAddressBelongToUser error"
,
e
);
}
log
.
info
(
"nft054QueryUserAddressBelongToUser--->>> response : {} "
,
response
);
if
(
StringUtils
.
isEmpty
(
response
))
{
return
null
;
}
/**
* 构造返回结果
*/
Nft054QueryUserAddressBelongToUserResp
resp
=
zxlnftBiz
.
buildNftRespObj
(
response
,
Nft054QueryUserAddressBelongToUserResp
.
class
);
log
.
info
(
"nft054QueryUserAddressBelongToUser--->>> return result : {} "
,
resp
.
toString
());
return
resp
;
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment