void consume(Purchase itemInfo) throws IabException {
        checkNotDisposed();
        checkSetupDone("consume");

        if (!itemInfo.mItemType.equals(ITEM_TYPE_INAPP)) {
            throw new IabException(IABHELPER_INVALID_CONSUMPTION,
                    "Items of type '" + itemInfo.mItemType + "' can't be consumed.");
        }

        try {
            String token = itemInfo.getToken();
            String sku = itemInfo.getSku();
            if (token == null || token.equals("")) {
               logError("Can't consume "+ sku + ". No token.");
               throw new IabException(IABHELPER_MISSING_TOKEN, "PurchaseInfo is missing token for sku: "
                   + sku + " " + itemInfo);
            }

            logDebug("Consuming sku: " + sku + ", token: " + token);
            int response = mService.consumePurchase(3, mContext.getPackageName(), token);
            if (response == BILLING_RESPONSE_RESULT_OK) {
               logDebug("Successfully consumed sku: " + sku);
            }
            else {
               logDebug("Error consuming consuming sku " + sku + ". " + getResponseDesc(response));
               throw new IabException(response, "Error consuming sku " + sku);
            }
        }
        catch (RemoteException e) {
            throw new IabException(IABHELPER_REMOTE_EXCEPTION, "Remote exception while consuming. PurchaseInfo: " + itemInfo, e);
        }
    }
void consume ( Purchase itemInfo ) throws IabException { checkNotDisposed ( ) ; checkSetupDone ( "consume" ) ; if ( ! itemInfo . mItemType . equals ( ITEM_TYPE_INAPP ) ) { throw new IabException ( IABHELPER_INVALID_CONSUMPTION , "Items of type '" + itemInfo . mItemType + "' can't be consumed." ) ; } try { String token = itemInfo . getToken ( ) ; String sku = itemInfo . getSku ( ) ; if ( token == null || token . equals ( "" ) ) { logError ( "Can't consume " + sku + ". No token." ) ; throw new IabException ( IABHELPER_MISSING_TOKEN , "PurchaseInfo is missing token for sku: " + sku + " " + itemInfo ) ; } logDebug ( "Consuming sku: " + sku + ", token: " + token ) ; int response = mService . consumePurchase ( 3 , mContext . getPackageName ( ) , token ) ; if ( response == BILLING_RESPONSE_RESULT_OK ) { logDebug ( "Successfully consumed sku: " + sku ) ; } else { logDebug ( "Error consuming consuming sku " + sku + ". " + getResponseDesc ( response ) ) ; throw new IabException ( response , "Error consuming sku " + sku ) ; } } catch ( RemoteException e ) { throw new IabException ( IABHELPER_REMOTE_EXCEPTION , "Remote exception while consuming. PurchaseInfo: " + itemInfo , e ) ; } }
Consumes a given in-app product. Consuming can only be done on an item
that's owned, and as a result of consumption, the user will no longer own it.
This method may block or take long to return. Do not call from the UI thread.
For that, see {@link #consumeAsync}.

@param itemInfo The PurchaseInfo that represents the item to consume.
@throws IabException if there is a problem during consumption.