/** * Requests the purchase of the specified subscription item with optional automatic confirmation. * * @param context * @param itemId id of the item to be purchased. * @param confirm if true, the transaction will be confirmed automatically. If false, the * transaction will have to be confirmed with a call to {@link #confirmNotifications(Context, * String)}. * @param developerPayload a developer-specified string that contains supplemental information * about the order. * @see IBillingObserver#onPurchaseIntent(String, PendingIntent) */ public static void requestSubscription( Context context, String itemId, boolean confirm, String developerPayload) { if (confirm) { automaticConfirmations.add(itemId); } BillingService.requestSubscription(context, itemId, developerPayload); }