|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sponsorpay.sdk.android.publisher.AbstractConnector
com.sponsorpay.sdk.android.publisher.unlock.SponsorPayUnlockConnector
public class SponsorPayUnlockConnector
Provides services to access the SponsorPay Unlock Server.
| Field Summary | |
|---|---|
private SPUnlockResponseListener |
mUserListener
SPUnlockResponseListener registered by the developer's code to be notified of the
result of requests to the back end. |
private static java.lang.String |
SP_UNLOCK_REQUEST_RESOURCE
|
private static java.lang.String |
SP_UNLOCK_SERVER_PRODUCTION_BASE_URL
|
private static java.lang.String |
SP_UNLOCK_SERVER_STAGING_BASE_URL
|
| Fields inherited from class com.sponsorpay.sdk.android.publisher.AbstractConnector |
|---|
mContext, mCustomParameters, mHostInfo, mSecurityToken, mUserId, remoteResourceUrl, URL_PARAM_KEY_TIMESTAMP |
| Constructor Summary | |
|---|---|
SponsorPayUnlockConnector(Context context,
java.lang.String userId,
SPUnlockResponseListener userListener,
HostInfo hostInfo,
java.lang.String securityToken)
Initializes a new SponsorPayUnlockConnector instance. |
|
| Method Summary | |
|---|---|
void |
fetchItemsStatus()
Sends a request to fetch the status of the Unlock items. |
void |
onAsyncRequestComplete(AsyncRequest requestTask)
|
void |
onSPUnlockItemsStatusResponseReceived(UnlockedItemsResponse response)
Implemented from SPUnlockResponseListener. |
void |
onSPUnlockRequestError(AbstractResponse response)
Implemented from SPUnlockResponseListener. |
| Methods inherited from class com.sponsorpay.sdk.android.publisher.AbstractConnector |
|---|
getCurrentUnixTimestampAsString, setCustomParameters |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static final java.lang.String SP_UNLOCK_SERVER_STAGING_BASE_URL
private static final java.lang.String SP_UNLOCK_SERVER_PRODUCTION_BASE_URL
private static final java.lang.String SP_UNLOCK_REQUEST_RESOURCE
private SPUnlockResponseListener mUserListener
SPUnlockResponseListener registered by the developer's code to be notified of the
result of requests to the back end.
| Constructor Detail |
|---|
public SponsorPayUnlockConnector(Context context,
java.lang.String userId,
SPUnlockResponseListener userListener,
HostInfo hostInfo,
java.lang.String securityToken)
context - Android application context.userId - User ID.userListener - Listener which will be notified of asynchronous responses to the requests sent by
this app.hostInfo - HostInfo containing information about the host app and device.securityToken - Security token used to sign the requests and verify the server responses.| Method Detail |
|---|
public void fetchItemsStatus()
public void onAsyncRequestComplete(AsyncRequest requestTask)
onAsyncRequestComplete in interface AsyncRequest.AsyncRequestResultListenerpublic void onSPUnlockRequestError(AbstractResponse response)
SPUnlockResponseListener. Forwards the call to the user listener.
onSPUnlockRequestError in interface SPUnlockResponseListenerpublic void onSPUnlockItemsStatusResponseReceived(UnlockedItemsResponse response)
SPUnlockResponseListener. Forwards the call to the user listener.
onSPUnlockItemsStatusResponseReceived in interface SPUnlockResponseListener
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||