패키지 | mx.utils |
클래스 | public class UIDUtil |
상속 | UIDUtil Object |
언어 버전: | ActionScript 3.0 |
제품 버전: | Flex 3 |
런타임 버전: | Flash Player 9, AIR 1.1 |
UIDUtil.createUID()
method.
Note: If you have a dynamic object that has no [Bindable] properties
(which force the object to implement the IUID interface), Flex adds an
mx_internal_uid
property that contains a UID to the object.
To avoid having this field
in your dynamic object, make it [Bindable], implement the IUID interface
in the object class, or set a property with a value.
메서드 | 정의 주체 | ||
---|---|---|---|
[정적]
Generates a UID (unique identifier) based on ActionScript's
pseudo-random number generator and the current time. | UIDUtil | ||
[정적]
Converts a 128-bit UID encoded as a ByteArray to a String representation. | UIDUtil | ||
[정적]
Returns the UID (unique identifier) for the specified object. | UIDUtil | ||
지정된 속성이 객체에 정의되어 있는지 여부를 나타냅니다. | Object | ||
Object 클래스의 인스턴스가 매개 변수로 지정된 객체의 프로토타입 체인에 있는지 여부를 나타냅니다. | Object | ||
[정적]
A utility method to check whether a String value represents a
correctly formatted UID value. | UIDUtil | ||
지정된 속성이 존재하고 열거 가능한지 여부를 나타냅니다. | Object | ||
루프 작업에서 동적 속성을 사용할 수 있는지 여부를 설정합니다. | Object | ||
[정적]
Converts a UID formatted String to a ByteArray. | UIDUtil | ||
로캘별 규칙에 따라 서식이 지정된 이 객체의 문자열 표현을 반환합니다. | Object | ||
지정된 객체의 문자열 표현을 반환합니다. | Object | ||
지정된 객체의 프리미티브 값을 반환합니다. | Object |
createUID | () | 메서드 |
public static function createUID():String
언어 버전: | ActionScript 3.0 |
제품 버전: | Flex 3 |
런타임 버전: | Flash Player 9, AIR 1.1 |
Generates a UID (unique identifier) based on ActionScript's pseudo-random number generator and the current time.
The UID has the form
"XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
where X is a hexadecimal digit (0-9, A-F).
This UID will not be truly globally unique; but it is the best we can do without player support for UID generation.
반환값String — The newly-generated UID.
|
fromByteArray | () | 메서드 |
public static function fromByteArray(ba:ByteArray):String
언어 버전: | ActionScript 3.0 |
제품 버전: | Flex 3 |
런타임 버전: | Flash Player 9, AIR 1.1 |
Converts a 128-bit UID encoded as a ByteArray to a String representation. The format matches that generated by createUID. If a suitable ByteArray is not provided, null is returned.
매개 변수
ba:ByteArray — ByteArray 16 bytes in length representing a 128-bit UID.
|
String — String representation of the UID, or null if an invalid
ByteArray is provided.
|
getUID | () | 메서드 |
public static function getUID(item:Object):String
언어 버전: | ActionScript 3.0 |
제품 버전: | Flex 3 |
런타임 버전: | Flash Player 9, AIR 1.1 |
Returns the UID (unique identifier) for the specified object. If the specified object doesn't have an UID then the method assigns one to it. If a map is specified this method will use the map to construct the UID. As a special case, if the item passed in is null, this method returns a null UID.
매개 변수
item:Object — Object that we need to find the UID for.
|
String — The UID that was either found or generated.
|
isUID | () | 메서드 |
public static function isUID(uid:String):Boolean
언어 버전: | ActionScript 3.0 |
제품 버전: | Flex 3 |
런타임 버전: | Flash Player 9, AIR 1.1 |
A utility method to check whether a String value represents a correctly formatted UID value. UID values are expected to be in the format generated by createUID(), implying that only capitalized A-F characters in addition to 0-9 digits are supported.
매개 변수
uid:String — The value to test whether it is formatted as a UID.
|
Boolean — Returns true if the value is formatted as a UID.
|
toByteArray | () | 메서드 |
public static function toByteArray(uid:String):ByteArray
언어 버전: | ActionScript 3.0 |
제품 버전: | Flex 3 |
런타임 버전: | Flash Player 9, AIR 1.1 |
Converts a UID formatted String to a ByteArray. The UID must be in the format generated by createUID, otherwise null is returned.
매개 변수
uid:String — representing a 128-bit UID
|
ByteArray — ByteArray 16 bytes in length representing the 128-bits of the
UID or null if the uid could not be converted.
|
Tue Jun 12 2018, 03:17 PM Z