public class JPushClient extends Object
| 构造器和说明 |
|---|
JPushClient(String masterSecret,
String appKey)
Create a JPush Client.
|
JPushClient(String masterSecret,
String appKey,
boolean apnsProduction,
long timeToLive)
Create a JPush Client with global settings.
|
JPushClient(String masterSecret,
String appKey,
int maxRetryTimes) |
public JPushClient(String masterSecret, String appKey)
masterSecret - API access secret of the appKey.appKey - The KEY of one application on JPush.public JPushClient(String masterSecret, String appKey, boolean apnsProduction, long timeToLive)
masterSecret - API access secret of the appKey.appKey - The KEY of one application on JPush.apnsProduction - Global APNs environment setting. It will override PushPayload Options.timeToLive - Global time_to_live setting. It will override PushPayload Options.public PushResult sendPush(PushPayload pushPayload) throws APIConnectionException, APIRequestException
pushPayload - payload object of a push.APIConnectionExceptionAPIRequestExceptionpublic PushResult sendPush(String payloadString) throws APIConnectionException, APIRequestException
payloadString - payload of a push.APIConnectionExceptionAPIRequestExceptionpublic ReceivedsResult getReportReceiveds(String msgIds) throws APIConnectionException, APIRequestException
msgIds - 100 msgids to batch getting is supported.APIConnectionExceptionAPIRequestExceptionpublic UsersResult getReportUsers(TimeUnit timeUnit, String start, int duration) throws APIConnectionException, APIRequestException
public MessagesResult getReportMessages(String msgIds) throws APIConnectionException, APIRequestException
public PushResult sendNotificationAll(String alert) throws APIConnectionException, APIRequestException
public PushResult sendAndroidNotificationWithAlias(String title, String alert, Map<String,String> extras, String... alias) throws APIConnectionException, APIRequestException
public PushResult sendAndroidNotificationWithRegistrationID(String title, String alert, Map<String,String> extras, String... registrationID) throws APIConnectionException, APIRequestException
public PushResult sendIosNotificationWithAlias(String alert, Map<String,String> extras, String... alias) throws APIConnectionException, APIRequestException
public PushResult sendIosNotificationWithRegistrationID(String alert, Map<String,String> extras, String... registrationID) throws APIConnectionException, APIRequestException
public PushResult sendMessageAll(String msgContent) throws APIConnectionException, APIRequestException
public PushResult sendAndroidMessageWithAlias(String title, String msgContent, String... alias) throws APIConnectionException, APIRequestException
public PushResult sendAndroidMessageWithRegistrationID(String title, String msgContent, String... registrationID) throws APIConnectionException, APIRequestException
public PushResult sendIosMessageWithAlias(String title, String msgContent, String... alias) throws APIConnectionException, APIRequestException
public PushResult sendIosMessageWithRegistrationID(String title, String msgContent, String... registrationID) throws APIConnectionException, APIRequestException
Copyright © 2014. All Rights Reserved.