MapTrip SDK Android Manual 9.9.7
Licence Class Reference

This class handles the Licencing of the SDK. It enables you to request online licences, request device and licence information
More...

Static Public Member Functions

static void addLicenceListener (LicenceListener listener)
 
static void addTaskListener (TaskListener listener)
 
static native ApiError checkLicence ()
 
static native boolean checkSpecialLicence (SpecialLicence licenceType)
 
static native Date getExpiryDate ()
 
static native Iterable< LicenceFeaturegetFeatures ()
 
static native String getHardwareKey ()
 
static native int getLastError ()
 
static native String getOrderNumber ()
 
static void removeAllLicenceListeners ()
 
static void removeAllTaskListeners ()
 
static void removeLicenceListener (LicenceListener listener)
 
static void removeTaskListener (TaskListener listener)
 
static native Task< Void > requireLicenceOnline ()
 
static Task< Void > setDeviceName (final String name)
 

Detailed Description

Member Function Documentation

◆ addLicenceListener()

static void addLicenceListener ( LicenceListener  listener)
static

◆ addTaskListener()

static void addTaskListener ( TaskListener  listener)
static

◆ checkLicence()

static native ApiError checkLicence ( )
static

Checks whether the application has a valid licence.

If your application has no valid licence, call Licence.requireLicenceOnline() for online licensing.

Returns
Errorcode

◆ checkSpecialLicence()

static native boolean checkSpecialLicence ( SpecialLicence  licenceType)
static

Test if a specific feature defined in SpecialLicence is licenced

Parameters
licenceType- defines which licence shall be checked
Returns
  • true if the application has a valid licence,
  • false if the application has no valid licence

◆ getExpiryDate()

static native Date getExpiryDate ( )
static

Returns
the expiry date of the licence

◆ getFeatures()

static native Iterable< LicenceFeature > getFeatures ( )
static

Returns
all licenced features

◆ getHardwareKey()

static native String getHardwareKey ( )
static

Returns
hardwareKey - unique identifier of the device

◆ getLastError()

static native int getLastError ( )
static

Returns
last error code regarding licencing

◆ getOrderNumber()

static native String getOrderNumber ( )
static

Returns
the order number of the licence

◆ removeAllLicenceListeners()

static void removeAllLicenceListeners ( )
static

◆ removeAllTaskListeners()

static void removeAllTaskListeners ( )
static

◆ removeLicenceListener()

static void removeLicenceListener ( LicenceListener  listener)
static

◆ removeTaskListener()

static void removeTaskListener ( TaskListener  listener)
static

◆ requireLicenceOnline()

static native Task< Void > requireLicenceOnline ( )
static

Gets a licence. This function needs an online connection. Once your application has a valid licence there is no need to call this function again. To check if your application has a valid licence, call Licence.checkLicence(). If your application has no valid licence, all functions except initialization will return ApiError.NO_LICENCE.

Returns
Errorcode

◆ setDeviceName()

static Task< Void > setDeviceName ( final String  name)
static

Makes the current device known as a user defined name by the licence server.

Parameters
nameidentifier to be used by the licence server.
Returns
Errorcode

The documentation for this class was generated from the following file: