com.amazon.inapp.purchasing
Enum PurchaseResponse.PurchaseRequestStatus

java.lang.Object
  extended by java.lang.Enum<PurchaseResponse.PurchaseRequestStatus>
      extended by com.amazon.inapp.purchasing.PurchaseResponse.PurchaseRequestStatus
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<PurchaseResponse.PurchaseRequestStatus>
Enclosing class:
PurchaseResponse

public static enum PurchaseResponse.PurchaseRequestStatus
extends java.lang.Enum<PurchaseResponse.PurchaseRequestStatus>

Indicates the result of a purchase operation initiated via PurchasingManager.initiatePurchaseRequest(String).


Enum Constant Summary
ALREADY_ENTITLED
          Indicates that the customer already owns the provided SKU.
FAILED
          Indicates that the purchase failed for a reason outside your control.
INVALID_SKU
          Indicates that the SKU originally provided to the PurchasingManager.initiatePurchaseRequest(String) method is not valid.
SUCCESSFUL
          Indicates that the purchase was successfully completed.
 
Method Summary
static PurchaseResponse.PurchaseRequestStatus valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static PurchaseResponse.PurchaseRequestStatus[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

SUCCESSFUL

public static final PurchaseResponse.PurchaseRequestStatus SUCCESSFUL
Indicates that the purchase was successfully completed.


FAILED

public static final PurchaseResponse.PurchaseRequestStatus FAILED
Indicates that the purchase failed for a reason outside your control. You may attempt another purchase only if it is explicitly initiated by the customer.


INVALID_SKU

public static final PurchaseResponse.PurchaseRequestStatus INVALID_SKU
Indicates that the SKU originally provided to the PurchasingManager.initiatePurchaseRequest(String) method is not valid.


ALREADY_ENTITLED

public static final PurchaseResponse.PurchaseRequestStatus ALREADY_ENTITLED
Indicates that the customer already owns the provided SKU. To determine what the customer already owns, use PurchasingManager.initiatePurchaseUpdatesRequest(Offset). Note that you will never receive this error for consumable items, since they can be purchased an unlimited number of times.n

Method Detail

values

public static PurchaseResponse.PurchaseRequestStatus[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (PurchaseResponse.PurchaseRequestStatus c : PurchaseResponse.PurchaseRequestStatus.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static PurchaseResponse.PurchaseRequestStatus valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null