Google Play Android Developer API v1 (revision 10)



com.google.api.services.androidpublisher
Class Androidpublisher.Purchases.Get

java.lang.Object
  extended by java.util.AbstractMap<String,Object>
      extended by com.google.api.client.util.GenericData
          extended by com.google.api.client.googleapis.services.AbstractGoogleClientRequest<T>
              extended by com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest<T>
                  extended by com.google.api.services.androidpublisher.AndroidpublisherRequest<SubscriptionPurchase>
                      extended by com.google.api.services.androidpublisher.Androidpublisher.Purchases.Get
All Implemented Interfaces:
Cloneable, Map<String,Object>
Enclosing class:
Androidpublisher.Purchases

public class Androidpublisher.Purchases.Get
extends AndroidpublisherRequest<SubscriptionPurchase>


Nested Class Summary
 
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
GenericData.Flags
 
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
 
Nested classes/interfaces inherited from interface java.util.Map
Map.Entry<K,V>
 
Constructor Summary
protected Androidpublisher.Purchases.Get(String packageName, String subscriptionId, String token)
          Checks whether a user's subscription purchase is valid and returns its expiry time.
 
Method Summary
 HttpRequest buildHttpRequestUsingHead()
           
 HttpResponse executeUsingHead()
           
 String getPackageName()
          The package name of the application for which this subscription was purchased (for example, 'com.some.thing').
 String getSubscriptionId()
          The purchased subscription ID (for example, 'monthly001').
 String getToken()
          The token provided to the user's device when the subscription was purchased.
 Androidpublisher.Purchases.Get setAlt(String alt)
          Data format for the response.
 Androidpublisher.Purchases.Get setFields(String fields)
          Selector specifying which fields to include in a partial response.
 Androidpublisher.Purchases.Get setKey(String key)
          API key.
 Androidpublisher.Purchases.Get setOauthToken(String oauthToken)
          OAuth 2.0 token for the current user.
 Androidpublisher.Purchases.Get setPackageName(String packageName)
          The package name of the application for which this subscription was purchased (for example, 'com.some.thing').
 Androidpublisher.Purchases.Get setPrettyPrint(Boolean prettyPrint)
          Returns response with indentations and line breaks.
 Androidpublisher.Purchases.Get setQuotaUser(String quotaUser)
          Available to use for quota purposes for server-side applications.
 Androidpublisher.Purchases.Get setSubscriptionId(String subscriptionId)
          The purchased subscription ID (for example, 'monthly001').
 Androidpublisher.Purchases.Get setToken(String token)
          The token provided to the user's device when the subscription was purchased.
 Androidpublisher.Purchases.Get setUserIp(String userIp)
          IP address of the site where the request originates.
 
Methods inherited from class com.google.api.services.androidpublisher.AndroidpublisherRequest
getAbstractGoogleClient, getAlt, getFields, getKey, getOauthToken, getPrettyPrint, getQuotaUser, getUserIp, setDisableGZipContent, setRequestHeaders
 
Methods inherited from class com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest
getJsonContent, newExceptionOnError, queue
 
Methods inherited from class com.google.api.client.googleapis.services.AbstractGoogleClientRequest
buildHttpRequest, buildHttpRequestUrl, execute, executeAndDownloadTo, executeAsInputStream, executeMedia, executeMediaAndDownloadTo, executeMediaAsInputStream, executeUnparsed, getDisableGZipContent, getHttpContent, getLastResponseHeaders, getLastStatusCode, getLastStatusMessage, getMediaHttpDownloader, getMediaHttpUploader, getRequestHeaders, getRequestMethod, getResponseClass, getUriTemplate, initializeMediaDownload, initializeMediaUpload, queue
 
Methods inherited from class com.google.api.client.util.GenericData
clone, entrySet, get, getClassInfo, getUnknownKeys, put, putAll, remove, set, setUnknownKeys
 
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, equals, hashCode, isEmpty, keySet, size, toString, values
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Androidpublisher.Purchases.Get

protected Androidpublisher.Purchases.Get(String packageName,
                                         String subscriptionId,
                                         String token)
Checks whether a user's subscription purchase is valid and returns its expiry time. Create a request for the method "purchases.get". This request holds the parameters needed by the the androidpublisher server. After setting any optional parameters, call the AbstractGoogleClientRequest.execute() method to invoke the remote operation.

Androidpublisher.initialize(AbstractGoogleClientRequest) must be called to initialize this instance immediately after invoking the constructor.

Parameters:
packageName - The package name of the application for which this subscription was purchased (for example, 'com.some.thing').
subscriptionId - The purchased subscription ID (for example, 'monthly001').
token - The token provided to the user's device when the subscription was purchased.
Since:
1.13
Method Detail

executeUsingHead

public HttpResponse executeUsingHead()
                              throws IOException
Overrides:
executeUsingHead in class AbstractGoogleClientRequest<SubscriptionPurchase>
Throws:
IOException

buildHttpRequestUsingHead

public HttpRequest buildHttpRequestUsingHead()
                                      throws IOException
Overrides:
buildHttpRequestUsingHead in class AbstractGoogleClientRequest<SubscriptionPurchase>
Throws:
IOException

setAlt

public Androidpublisher.Purchases.Get setAlt(String alt)
Description copied from class: AndroidpublisherRequest
Data format for the response.

Overrides:
setAlt in class AndroidpublisherRequest<SubscriptionPurchase>

setFields

public Androidpublisher.Purchases.Get setFields(String fields)
Description copied from class: AndroidpublisherRequest
Selector specifying which fields to include in a partial response.

Overrides:
setFields in class AndroidpublisherRequest<SubscriptionPurchase>

setKey

public Androidpublisher.Purchases.Get setKey(String key)
Description copied from class: AndroidpublisherRequest
API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.

Overrides:
setKey in class AndroidpublisherRequest<SubscriptionPurchase>

setOauthToken

public Androidpublisher.Purchases.Get setOauthToken(String oauthToken)
Description copied from class: AndroidpublisherRequest
OAuth 2.0 token for the current user.

Overrides:
setOauthToken in class AndroidpublisherRequest<SubscriptionPurchase>

setPrettyPrint

public Androidpublisher.Purchases.Get setPrettyPrint(Boolean prettyPrint)
Description copied from class: AndroidpublisherRequest
Returns response with indentations and line breaks.

Overrides:
setPrettyPrint in class AndroidpublisherRequest<SubscriptionPurchase>

setQuotaUser

public Androidpublisher.Purchases.Get setQuotaUser(String quotaUser)
Description copied from class: AndroidpublisherRequest
Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

Overrides:
setQuotaUser in class AndroidpublisherRequest<SubscriptionPurchase>

setUserIp

public Androidpublisher.Purchases.Get setUserIp(String userIp)
Description copied from class: AndroidpublisherRequest
IP address of the site where the request originates. Use this if you want to enforce per-user limits.

Overrides:
setUserIp in class AndroidpublisherRequest<SubscriptionPurchase>

getPackageName

public String getPackageName()
The package name of the application for which this subscription was purchased (for example, 'com.some.thing').


setPackageName

public Androidpublisher.Purchases.Get setPackageName(String packageName)
The package name of the application for which this subscription was purchased (for example, 'com.some.thing').


getSubscriptionId

public String getSubscriptionId()
The purchased subscription ID (for example, 'monthly001').


setSubscriptionId

public Androidpublisher.Purchases.Get setSubscriptionId(String subscriptionId)
The purchased subscription ID (for example, 'monthly001').


getToken

public String getToken()
The token provided to the user's device when the subscription was purchased.


setToken

public Androidpublisher.Purchases.Get setToken(String token)
The token provided to the user's device when the subscription was purchased.