Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 45effb9

Browse files
committed
文本反垃圾API增加参数
1 parent 85738f7 commit 45effb9

34 files changed

+3345
-1
lines changed

aliyun-java-sdk-green/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<groupId>com.aliyun</groupId>
44
<artifactId>aliyun-java-sdk-green</artifactId>
55
<packaging>jar</packaging>
6-
<version>2.2.0</version>
6+
<version>2.3.0</version>
77
<name>aliyun-java-sdk-green</name>
88
<url>http://www.aliyun.com</url>
99
<description>Aliyun Open API SDK for Java
Lines changed: 175 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,175 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one
3+
* or more contributor license agreements. See the NOTICE file
4+
* distributed with this work for additional information
5+
* regarding copyright ownership. The ASF licenses this file
6+
* to you under the Apache License, Version 2.0 (the
7+
* "License"); you may not use this file except in compliance
8+
* with the License. You may obtain a copy of the License at
9+
*
10+
* http://www.apache.org/licenses/LICENSE-2.0
11+
*
12+
* Unless required by applicable law or agreed to in writing,
13+
* software distributed under the License is distributed on an
14+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
* KIND, either express or implied. See the License for the
16+
* specific language governing permissions and limitations
17+
* under the License.
18+
*/
19+
package com.aliyuncs.green.model.v20161124;
20+
21+
import com.aliyuncs.RpcAcsRequest;
22+
import java.util.List;
23+
import com.aliyuncs.http.MethodType;
24+
25+
/**
26+
* @author auto create
27+
* @version
28+
*/
29+
public class AntispamDetectionRequest extends RpcAcsRequest<AntispamDetectionResponse> {
30+
31+
public AntispamDetectionRequest() {
32+
super("Green", "2016-11-24", "AntispamDetection", "green");
33+
setMethod(MethodType.POST);
34+
}
35+
36+
private String dataId;
37+
38+
private String postId;
39+
40+
private String sceneId;
41+
42+
private String postNick;
43+
44+
private String postIp;
45+
46+
private String postMac;
47+
48+
private Long postTime;
49+
50+
private String machineCode;
51+
52+
private String parentDataId;
53+
54+
private String title;
55+
56+
private String postContent;
57+
58+
private List<String> imageUrls;
59+
60+
public String getDataId() {
61+
return this.dataId;
62+
}
63+
64+
public void setDataId(String dataId) {
65+
this.dataId = dataId;
66+
putQueryParameter("DataId", dataId);
67+
}
68+
69+
public String getPostId() {
70+
return this.postId;
71+
}
72+
73+
public void setPostId(String postId) {
74+
this.postId = postId;
75+
putQueryParameter("PostId", postId);
76+
}
77+
78+
public String getSceneId() {
79+
return this.sceneId;
80+
}
81+
82+
public void setSceneId(String sceneId) {
83+
this.sceneId = sceneId;
84+
putQueryParameter("SceneId", sceneId);
85+
}
86+
87+
public String getPostNick() {
88+
return this.postNick;
89+
}
90+
91+
public void setPostNick(String postNick) {
92+
this.postNick = postNick;
93+
putQueryParameter("PostNick", postNick);
94+
}
95+
96+
public String getPostIp() {
97+
return this.postIp;
98+
}
99+
100+
public void setPostIp(String postIp) {
101+
this.postIp = postIp;
102+
putQueryParameter("PostIp", postIp);
103+
}
104+
105+
public String getPostMac() {
106+
return this.postMac;
107+
}
108+
109+
public void setPostMac(String postMac) {
110+
this.postMac = postMac;
111+
putQueryParameter("PostMac", postMac);
112+
}
113+
114+
public Long getPostTime() {
115+
return this.postTime;
116+
}
117+
118+
public void setPostTime(Long postTime) {
119+
this.postTime = postTime;
120+
putQueryParameter("PostTime", postTime);
121+
}
122+
123+
public String getMachineCode() {
124+
return this.machineCode;
125+
}
126+
127+
public void setMachineCode(String machineCode) {
128+
this.machineCode = machineCode;
129+
putQueryParameter("MachineCode", machineCode);
130+
}
131+
132+
public String getParentDataId() {
133+
return this.parentDataId;
134+
}
135+
136+
public void setParentDataId(String parentDataId) {
137+
this.parentDataId = parentDataId;
138+
putQueryParameter("ParentDataId", parentDataId);
139+
}
140+
141+
public String getTitle() {
142+
return this.title;
143+
}
144+
145+
public void setTitle(String title) {
146+
this.title = title;
147+
putQueryParameter("Title", title);
148+
}
149+
150+
public String getPostContent() {
151+
return this.postContent;
152+
}
153+
154+
public void setPostContent(String postContent) {
155+
this.postContent = postContent;
156+
putQueryParameter("PostContent", postContent);
157+
}
158+
159+
public List<String> getImageUrls() {
160+
return this.imageUrls;
161+
}
162+
163+
public void setImageUrls(List<String> imageUrls) {
164+
this.imageUrls = imageUrls;
165+
for (int i = 0; i < imageUrls.size(); i++) {
166+
putQueryParameter("ImageUrl." + (i + 1) , imageUrls.get(i));
167+
}
168+
}
169+
170+
@Override
171+
public Class<AntispamDetectionResponse> getResponseClass() {
172+
return AntispamDetectionResponse.class;
173+
}
174+
175+
}
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one
3+
* or more contributor license agreements. See the NOTICE file
4+
* distributed with this work for additional information
5+
* regarding copyright ownership. The ASF licenses this file
6+
* to you under the Apache License, Version 2.0 (the
7+
* "License"); you may not use this file except in compliance
8+
* with the License. You may obtain a copy of the License at
9+
*
10+
* http://www.apache.org/licenses/LICENSE-2.0
11+
*
12+
* Unless required by applicable law or agreed to in writing,
13+
* software distributed under the License is distributed on an
14+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
* KIND, either express or implied. See the License for the
16+
* specific language governing permissions and limitations
17+
* under the License.
18+
*/
19+
package com.aliyuncs.green.model.v20161124;
20+
21+
import com.aliyuncs.AcsResponse;
22+
import com.aliyuncs.green.transform.v20161124.AntispamDetectionResponseUnmarshaller;
23+
import com.aliyuncs.transform.UnmarshallerContext;
24+
25+
/**
26+
* @author auto create
27+
* @version
28+
*/
29+
public class AntispamDetectionResponse extends AcsResponse {
30+
31+
private String code;
32+
33+
private String msg;
34+
35+
private String dataId;
36+
37+
private String status;
38+
39+
private Integer resultCode;
40+
41+
private Integer label;
42+
43+
public String getCode() {
44+
return this.code;
45+
}
46+
47+
public void setCode(String code) {
48+
this.code = code;
49+
}
50+
51+
public String getMsg() {
52+
return this.msg;
53+
}
54+
55+
public void setMsg(String msg) {
56+
this.msg = msg;
57+
}
58+
59+
public String getDataId() {
60+
return this.dataId;
61+
}
62+
63+
public void setDataId(String dataId) {
64+
this.dataId = dataId;
65+
}
66+
67+
public String getStatus() {
68+
return this.status;
69+
}
70+
71+
public void setStatus(String status) {
72+
this.status = status;
73+
}
74+
75+
public Integer getResultCode() {
76+
return this.resultCode;
77+
}
78+
79+
public void setResultCode(Integer resultCode) {
80+
this.resultCode = resultCode;
81+
}
82+
83+
public Integer getLabel() {
84+
return this.label;
85+
}
86+
87+
public void setLabel(Integer label) {
88+
this.label = label;
89+
}
90+
91+
@Override
92+
public AntispamDetectionResponse getInstance(UnmarshallerContext context) {
93+
return AntispamDetectionResponseUnmarshaller.unmarshall(this, context);
94+
}
95+
}
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one
3+
* or more contributor license agreements. See the NOTICE file
4+
* distributed with this work for additional information
5+
* regarding copyright ownership. The ASF licenses this file
6+
* to you under the Apache License, Version 2.0 (the
7+
* "License"); you may not use this file except in compliance
8+
* with the License. You may obtain a copy of the License at
9+
*
10+
* http://www.apache.org/licenses/LICENSE-2.0
11+
*
12+
* Unless required by applicable law or agreed to in writing,
13+
* software distributed under the License is distributed on an
14+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
* KIND, either express or implied. See the License for the
16+
* specific language governing permissions and limitations
17+
* under the License.
18+
*/
19+
package com.aliyuncs.green.model.v20161124;
20+
21+
import com.aliyuncs.RpcAcsRequest;
22+
import java.util.List;
23+
import com.aliyuncs.http.MethodType;
24+
25+
/**
26+
* @author auto create
27+
* @version
28+
*/
29+
public class AntispamResultsRequest extends RpcAcsRequest<AntispamResultsResponse> {
30+
31+
public AntispamResultsRequest() {
32+
super("Green", "2016-11-24", "AntispamResults", "green");
33+
setMethod(MethodType.POST);
34+
}
35+
36+
private List<String> dataIds;
37+
38+
public List<String> getDataIds() {
39+
return this.dataIds;
40+
}
41+
42+
public void setDataIds(List<String> dataIds) {
43+
this.dataIds = dataIds;
44+
for (int i = 0; i < dataIds.size(); i++) {
45+
putQueryParameter("DataId." + (i + 1) , dataIds.get(i));
46+
}
47+
}
48+
49+
@Override
50+
public Class<AntispamResultsResponse> getResponseClass() {
51+
return AntispamResultsResponse.class;
52+
}
53+
54+
}

0 commit comments

Comments
 (0)