Skip to content

Commit 8046373

Browse files
committed
feature: finish delete sign interface
1 parent e89359e commit 8046373

File tree

2 files changed

+25
-25
lines changed

2 files changed

+25
-25
lines changed

example/main/java/cn/jsms/api/JSMSExample.java

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ public static void main(String[] args) {
4747
// testCreateSign();pass
4848
// testUpdateSign();no pass
4949
// testCheckSign();pass
50+
testDeleteSign();
5051
// testSendVoiceSMSCode();
5152
// testSendTemplateSMS();
5253
}
@@ -464,20 +465,19 @@ public static void testCheckSign(){
464465
}
465466
}
466467

467-
// public static void testDefaultSign(){
468-
// try {
469-
// SMSClient client = new SMSClient(masterSecret, appkey);
470-
// DefaultSignPayload payload = DefaultSignPayload.newBuilder().
471-
// id(10859).name("SDK6").build();
472-
// ResponseWrapper result = client.setDefaultSign(payload);
473-
// LOG.info(result.toString());
474-
// }catch (APIConnectionException e) {
475-
// LOG.error("Connection error. Should retry later. ", e);
476-
// } catch (APIRequestException e) {
477-
// LOG.error("Error response from JPush server. Should review and fix it. ", e);
478-
// LOG.info("HTTP Status: " + e.getStatus());
479-
// LOG.info("Error Message: " + e.getMessage());
480-
// }
481-
// }
468+
public static void testDeleteSign(){
469+
try {
470+
SMSClient client = new SMSClient(masterSecret, appkey);
471+
ResponseWrapper result = client.deleteSign(10859);
472+
LOG.info(result.toString());
473+
}catch (APIConnectionException e) {
474+
LOG.error("Connection error. Should retry later. ", e);
475+
} catch (APIRequestException e) {
476+
LOG.error("Error response from JPush server. Should review and fix it. ", e);
477+
LOG.info("HTTP Status: " + e.getStatus());
478+
LOG.info("Error Message: " + e.getMessage());
479+
}
480+
}
481+
482482

483483
}

src/main/java/cn/jsms/api/JSMSClient.java

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -285,14 +285,14 @@ public SignInfoResult checkSign(int signId) throws APIConnectionException, APIRe
285285
return _smsClient.checkSign(signId);
286286
}
287287

288-
/**
289-
* set default sign
290-
* @param payload
291-
* @return
292-
* @throws APIConnectionException
293-
* @throws APIRequestException
294-
*/
295-
public ResponseWrapper setDefaultSign(DefaultSignPayload payload) throws APIConnectionException, APIRequestException{
296-
return _smsClient.setDefaultSign(payload);
297-
}
288+
// /**
289+
// * set default sign
290+
// * @param payload
291+
// * @return
292+
// * @throws APIConnectionException
293+
// * @throws APIRequestException
294+
// */
295+
// public ResponseWrapper setDefaultSign(DefaultSignPayload payload) throws APIConnectionException, APIRequestException{
296+
// return _smsClient.setDefaultSign(payload);
297+
// }
298298
}

0 commit comments

Comments
 (0)