Package | com.myflashlab.air.extensions.udid |
Class | public class UDID |
Inheritance | UDID Object |
Property | Defined By | ||
---|---|---|---|
androidId : String [static] [read-only]
On Android, A 64-bit number (as a hex string) that is randomly generated when the user first sets up the device and should
remain constant for the lifetime of the user's device. | UDID | ||
OS : String [static] [read-only]
Indicates the running OS of your device. | UDID | ||
serialNumber : String [static] [read-only]
On Android, A hardware serial number, if available. | UDID | ||
telephonyManagerDeviceId : String [static] [read-only]
On Android, Returns the unique device ID, for example, the IMEI for GSM and the MEID or ESN for CDMA phones. | UDID | ||
telephonyManagerSubscriberId : String [static] [read-only]
On Android, Returns the unique subscriber ID, for example, the IMSI for a GSM phone. | UDID | ||
UUID : String [static] [read-only]
On Android, UUID is an immutable representation of a 128-bit universally unique identifier (UUID). | UDID | ||
vendorId : String [static] [read-only]
On iOS, An alphanumeric string that uniquely identifies a device to the app's vendor. | UDID |
Method | Defined By | ||
---|---|---|---|
init():void [static]
To use this extension, you must first initialize it with this method. | UDID | ||
initTelephonyManager():void [static]
On Android, Initializes the TelephonyManager class. | UDID | ||
retriveAdId($onResult:Function):void [static]
On iOS and Android, Retrieves the advertising ID and indicates whether the user has limited ad tracking or not. | UDID |
Constant | Defined By | ||
---|---|---|---|
ANDROID : String = android [static] | UDID | ||
EXTENSION_ID : String = com.myflashlab.air.extensions.udid [static] | UDID | ||
IOS : String = ios [static] | UDID | ||
VERSION : String = 2.0.4 [static] | UDID |
androidId | property |
androidId:String
[read-only]
On Android, A 64-bit number (as a hex string) that is randomly generated when the user first sets up the device and should remain constant for the lifetime of the user's device. The value may change if a factory reset is performed on the device.
Note: When a device has multiple users (available on certain devices running Android 4.2 or higher), each user appears as a completely separate device, so the UDID.androidId value is unique to each user.
public static function get androidId():String
OS | property |
OS:String
[read-only] Indicates the running OS of your device.
public static function get OS():String
serialNumber | property |
serialNumber:String
[read-only] On Android, A hardware serial number, if available. Alphanumeric only, case-insensitive.
public static function get serialNumber():String
telephonyManagerDeviceId | property |
telephonyManagerDeviceId:String
[read-only] On Android, Returns the unique device ID, for example, the IMEI for GSM and the MEID or ESN for CDMA phones. Return null if device ID is not available.
public static function get telephonyManagerDeviceId():String
telephonyManagerSubscriberId | property |
telephonyManagerSubscriberId:String
[read-only] On Android, Returns the unique subscriber ID, for example, the IMSI for a GSM phone. Return null if it is unavailable.
public static function get telephonyManagerSubscriberId():String
UUID | property |
UUID:String
[read-only] On Android, UUID is an immutable representation of a 128-bit universally unique identifier (UUID). This property returns a variant 2, version 4 (randomly generated number) UUID as per RFC 4122.
public static function get UUID():String
vendorId | property |
vendorId:String
[read-only] On iOS, An alphanumeric string that uniquely identifies a device to the app's vendor. The value of this property is the same for apps that come from the same vendor running on the same device. A different value is returned for apps on the same device that come from different vendors, and for apps on different devices regardless of vendor. Normally, the vendor is determined by data provided by the App Store. If the app was not installed from the app store (such as enterprise apps and apps still in development), then a vendor identifier is calculated based on the app's bundle ID.
public static function get vendorId():String
init | () | method |
public static function init():void
To use this extension, you must first initialize it with this method.
initTelephonyManager | () | method |
public static function initTelephonyManager():void
On Android, Initializes the TelephonyManager class.
retriveAdId | () | method |
public static function retriveAdId($onResult:Function):void
On iOS and Android, Retrieves the advertising ID and indicates whether the user has limited ad tracking or not. Unlike the vendorId property for iOS, the same value is returned to all vendors. This identifier may change—for example, if the user erases the device—so you should not cache it. In iOS 10.0 and later, the value of adId is all zeroes when the user has limited ad tracking. If the value is null, wait and get the value again later.
Parameters
$onResult:Function |
UDID.retriveAdId(onResult); function onResult($id:String, $isLimitAdTrackingEnabled:Boolean):void { trace("ad ID = " + $id); trace("isLimitAdTrackingEnabled = " + $isLimitAdTrackingEnabled); }
ANDROID | Constant |
public static const ANDROID:String = android
EXTENSION_ID | Constant |
public static const EXTENSION_ID:String = com.myflashlab.air.extensions.udid
IOS | Constant |
public static const IOS:String = ios
VERSION | Constant |
public static const VERSION:String = 2.0.4