The Device Info API is used to return various device parameters, such as the device Operating System name and number, or the version number of the Appoxee SDK installed on this device.
You can also use the API to set device parameters, for example: increase the number of products purchased through this device.
Each Method is called through "Appoxee.methodName", since they are all public static methods.
Each call to the methods must be under AsyncTask. For example :
new AsyncTask<Void, Void, Void>() { @Override protected Void doInBackground(Void... params) { String result = getDeviceOsName(); //Do what is needed with the returned result... return null; } }.execute(); |
Returns the name of the Operating System installed on the device.
public static String getDeviceOsName() |
A string containing the name of the device Operating System.
Returns the version number of the Operating System installed on the device.
public static String getDeviceOsNumber() |
A string containing the version number of the device Operating System.
Returns the type of hardware installed on the device.
public static String getHardwareType() |
A string containing the type of the device hardware.
Returns the device locale.
public static String getDeviceLocale() |
A string containing the device locale.
Returns the device country location, in any of the following formats:
public static String getDeviceCountry() |
A string containing the device location.
Returns the device platform.
public static String getDevicePlatform() |
A string containing the device platform.
Returns the version number of the Appoxee SDK installed on the device.
public static String getDeviceSdkVersion() |
A string containing the version number of the Appoxee SDK installed on the device.
Returns the device resolution.
public static String getDeviceResolution() |
A string containing the device resolution.
Returns the device screen density.
public static String getDeviceDensity() |
A string containing the device density.
Returns the total sum of all payments made through the application.
public static Double getInAppPayment() |
A decimal number indicating the total sum of all payments made through the application.
Returns the number of products purchased through your app on this device.
public static Integer getNumProductPurchased() |
An integer indicating the number of products purchased.
Updates the total sum of all payments made through your app, by adding the given float value to the current in-app payment.
Call this method for each approved purchase.
public static boolean increaseInAppPayment(float value) |
float value - the value by which the total in-app payment sum is to be increased.
true if the app payment was increased successfully; false otherwise.
Updates the total number of products purchased through your app, by adding the given integer value to the current number of products purchased.
Call this method for each approved purchase.
public static boolean increaseNumProductPurchased(int value) |
int value - the number to be added to the thetotal number of products purchased.
true if the number of products purchased was updated successfully; false otherwise.