Class IOSInAppBillingService
java.lang.Object
com.gluonhq.attach.inappbilling.impl.IOSInAppBillingService
- All Implemented Interfaces:
InAppBillingService
-
Property Summary
Properties -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionRetrieves the details for the current list of available in-app products.javafx.concurrent.Worker<Product>finish(ProductOrder productOrder) Finish a product order for aconsumableproduct.voidinitialize(String androidPublicKey, List<Product> registeredProducts) Correctly initialize the In-App Billing service on the device.booleanisReady()Gets the value of the property ready.booleanReturns true if the device supports in-app billing.javafx.concurrent.Worker<ProductOrder>Place a new order for the specified product.javafx.beans.property.ReadOnlyBooleanPropertyvoidSet a query listener to listen for results of asynchronous queries of the registered in-app products.voidsetRegisteredProducts(List<Product> registeredProducts) Updates the list of available products that are configured in the in-app product sections of the application configuration for iOS and Android.
-
Property Details
-
ready
public javafx.beans.property.ReadOnlyBooleanProperty readyProperty- Specified by:
readyPropertyin interfaceInAppBillingService- See Also:
-
-
Constructor Details
-
IOSInAppBillingService
public IOSInAppBillingService()
-
-
Method Details
-
isSupported
public boolean isSupported()Description copied from interface:InAppBillingServiceReturns true if the device supports in-app billing.- Specified by:
isSupportedin interfaceInAppBillingService- Returns:
- True if the device supports in-app billing.
-
setQueryResultListener
Description copied from interface:InAppBillingServiceSet a query listener to listen for results of asynchronous queries of the registered in-app products.- Specified by:
setQueryResultListenerin interfaceInAppBillingService- Parameters:
listener- the query listener to set
-
setRegisteredProducts
Description copied from interface:InAppBillingServiceUpdates the list of available products that are configured in the in-app product sections of the application configuration for iOS and Android.- Specified by:
setRegisteredProductsin interfaceInAppBillingService- Parameters:
registeredProducts- a list of available in-app products
-
initialize
Description copied from interface:InAppBillingServiceCorrectly initialize the In-App Billing service on the device. This makes sure that everything is in place before you can start interacting with the methods that deal with the actual in-app products.When initialization completed successfully, a query will be triggered to fetch the initial purchase details for each registered in-app product. You should
set a query listenerto act upon the results of that query.- Specified by:
initializein interfaceInAppBillingService- Parameters:
androidPublicKey- the license key of your Android application which can be found in the Google Play developer console.registeredProducts- a list of available in-app products that are configured in your application configuration for iOS and Android
-
isReady
public boolean isReady()Gets the value of the property ready.- Specified by:
isReadyin interfaceInAppBillingService- Property description:
-
readyProperty
public javafx.beans.property.ReadOnlyBooleanProperty readyProperty()- Specified by:
readyPropertyin interfaceInAppBillingService- See Also:
-
fetchProductDetails
Description copied from interface:InAppBillingServiceRetrieves the details for the current list of available in-app products. In case a product from the list of registered products could not be queried, they will not be listed in the returned list. This method must be called to get the details of each registered product, like the title, description and localised price and currency. You can use these details to build up your UI.- Specified by:
fetchProductDetailsin interfaceInAppBillingService- Returns:
- A list of products for which the details could be fetched, wrapped in a Worker.
-
order
Description copied from interface:InAppBillingServicePlace a new order for the specified product. The returned Worker can be used to determine if the order was successful.- Specified by:
orderin interfaceInAppBillingService- Parameters:
product- the product to place an order for- Returns:
- A ProductOrder containing details about the processed order, wrapped in a Worker.
-
finish
Description copied from interface:InAppBillingServiceFinish a product order for aconsumableproduct. The product order will not have been processed (and no money will have been transferred) until the order is finished.- Specified by:
finishin interfaceInAppBillingService- Parameters:
productOrder- the product order to finish- Returns:
- The product that was ordered with in the provided ProductOrder with updated details, wrapped in a Worker.
-