DevicesLicense.getHostHardwareCode Method

Module: DevicesLicense

Definition

Retrieves the hardware code of the device using the requested hardware code type.

This function retrieves the hardware code of the device you run the library on.

The optional parameter is required:

  • On Android, it must be the JNIEnv* pointer cast as a void*.

  • In other cases, it must be set to NULL.

@staticmethod
get_host_hardware_code(hardware_code_type: LicenseHardwareCodeType) -> str

Parameters

hardware_code_type LicenseHardwareCodeType
in The requested hardware code type.

Returns

str
The device hardware code.

Exceptions

An error has occurred during Devices Library execution.
static String getHostHardwareCode(LicenseHardwareCodeType hardwareCodeType)

Parameters

hardwareCodeType LicenseHardwareCodeType
in The requested hardware code type.

Returns

String
The device hardware code.

Exceptions

An error has occurred during Devices Library execution.
public static string GetHostHardwareCode(LicenseHardwareCodeType hardwareCodeType)

Parameters

hardwareCodeType LicenseHardwareCodeType
in The requested hardware code type.

Returns

string
The device hardware code.

Exceptions

An error has occurred during Devices Library execution.
public static String getHostHardwareCode(LicenseHardwareCodeType hardwareCodeType) throws DevicesException

Parameters

hardwareCodeType LicenseHardwareCodeType
in The requested hardware code type.

Returns

String
The device hardware code.

Exceptions

An error has occurred during Devices Library execution.
int id3DevicesLicense_GetHostHardwareCode (
    id3DevicesLicenseHardwareCodeType eHardwareCodeType,
    char * code,
    int * codeSize,
    void * optionalParameter)

Parameters

in The requested hardware code type.

code char *
out The device hardware code.

codeSize int *
in Size of the ‘code’ buffer. Receives the minimum required buffer size to hold the ‘code’ string if the given one is too small (including the terminating NULL character), otherwise receives the number of characters in ‘code’ (excluding terminating NULL character).

optionalParameter void *
in Only used on Android for JNIEnv* pointer. Ignored for other devices (NULL).

Returns

int
An error code.
See id3DevicesError file for the list of possible error codes.