This reference document contains details, parameters, and usage of startConnection()
, endConnection()
, isReady()
, and isFeatureSupported
methods.
void startConnection (BillingClientStateListener listener)
The startConnection
method starts the BillingClient setup process asynchronously, and the BillingClientStateListener is used to notify when the setup process is completed.
Parameters | |
---|---|
listener | BillingClientStateListener – notifies when the setup is complete |
void endConnection ()
The endConnection
method is used to perform cleanup and release all resources, such as Service Connections. This method should be called after you have completed the processes that utilize the BillingClient reference.
boolean isReady ()
The isReady()
method is used to check the readiness of the service. It checks if the client is connected to the service so that other methods can be called. If the service is connected and the isready()
method returns true, it also means that in-app products are available for purchasing, querying, and other actions.
Returns TRUE
; if the client is connected to the service. Otherwise, returns FALSE
int isFeatureSupported (String feature)
The isFeatureSupported
method checks if the specified feature or capability is supported by the now.gg Billing Service
Parameters | Usage Description | Returns |
---|---|---|
feature | String: BillingClient.FeatureType | 0 = supported, Otherwise -2 |
Payments Module
Payments Module
Document Rev. 1.0