public class UUID
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static int |
UUID_LENGTH |
static int |
UUID_LENGTH_BINARY |
| Constructor and Description |
|---|
UUID(byte[] buf,
int off)
Class constructor
|
UUID(long lowBits,
long highBits)
Class constructor
|
UUID(java.lang.String id)
Class constructor
|
UUID(java.lang.String id,
int ver)
Class constructor
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
compareTo(UUID id)
Compare a UUID with the current UUID
|
static java.lang.String |
generateUUIDString(byte[] buf)
Generate a UUID string from the binary representation
|
byte[] |
getBytes()
Return the UUID as a byte array
|
java.lang.String |
getUUID()
Return the UUID string
|
int |
getVersion()
Return the interface version
|
boolean |
isValid()
Determine if the UUID is valid
|
void |
setVersion(int ver)
Set the interface version
|
int |
storeUUID(byte[] buf,
int off,
boolean writeVer)
Write the binary UUID to the specified buffer, and optionally the UUID version
|
java.lang.String |
toString()
Return the UUID as a string
|
static boolean |
validateUUID(java.lang.String idStr)
Validate a UUID string
|
public static final int UUID_LENGTH
public static final int UUID_LENGTH_BINARY
public UUID(java.lang.String id)
id - Stringpublic UUID(java.lang.String id,
int ver)
id - Stringver - intpublic UUID(byte[] buf,
int off)
buf - byte[]off - intpublic UUID(long lowBits,
long highBits)
lowBits - longhighBits - longpublic final boolean isValid()
public final java.lang.String getUUID()
public final int getVersion()
public final void setVersion(int ver)
ver - intpublic final byte[] getBytes()
public static final boolean validateUUID(java.lang.String idStr)
idStr - Stringpublic static final java.lang.String generateUUIDString(byte[] buf)
buf - byte[]public final boolean compareTo(UUID id)
id - UUIDpublic final int storeUUID(byte[] buf,
int off,
boolean writeVer)
buf - byte[]off - intwriteVer - booleanpublic java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.