public final class IgniteUuid extends Object implements Comparable<IgniteUuid>, Iterable<IgniteUuid>, Cloneable, Externalizable, Binarylizable
UUID. On basic tests this version is at least
10x time faster for ID creation. It uses extra memory for 8-byte counter additionally to
internal UUID.| Constructor and Description |
|---|
IgniteUuid()
Empty constructor required for
Externalizable. |
IgniteUuid(UUID gid,
long locId)
Constructs
GridUuid from a global and local identifiers. |
| Modifier and Type | Method and Description |
|---|---|
Object |
clone() |
int |
compareTo(IgniteUuid o) |
boolean |
equals(Object obj) |
static IgniteUuid |
fromString(String s)
Converts string into
GridUuid. |
static IgniteUuid |
fromUuid(UUID id)
Constructs new
GridUuid based on global and local ID portions. |
UUID |
globalId()
Gets global ID portion of this
GridUuid. |
int |
hashCode() |
org.apache.ignite.internal.util.lang.GridIterator<IgniteUuid> |
iterator() |
static long |
lastLocalId()
Gets last generated local ID.
|
long |
localId()
Gets local ID portion of this
GridUuid. |
static IgniteUuid |
randomUuid()
Creates new pseudo-random ID.
|
void |
readBinary(BinaryReader reader)
Reads fields from provided reader.
|
void |
readExternal(ObjectInput in) |
String |
shortString()
Gets a short string version of this ID.
|
String |
toString() |
static UUID |
vmId()
Gets
UUID associated with local VM. |
void |
writeBinary(BinaryWriter writer)
Writes fields to provided writer.
|
void |
writeExternal(ObjectOutput out) |
finalize, getClass, notify, notifyAll, wait, wait, waitforEach, spliteratorpublic static final UUID VM_ID
public IgniteUuid()
Externalizable.public IgniteUuid(UUID gid, long locId)
GridUuid from a global and local identifiers.gid - UUID.locId - Counter.public static UUID vmId()
UUID associated with local VM.UUID associated with local VM.public static long lastLocalId()
public static IgniteUuid randomUuid()
public static IgniteUuid fromUuid(UUID id)
GridUuid based on global and local ID portions.id - UUID instance.public static IgniteUuid fromString(String s)
GridUuid. The String must be in the format generated
by GridUuid.toString() method.s - String to convert to GridUuid.GridUuid instance representing given string.public String shortString()
public UUID globalId()
GridUuid.GridUuid.public long localId()
GridUuid.GridUuid.public void writeExternal(ObjectOutput out) throws IOException
writeExternal in interface ExternalizableIOExceptionpublic void readExternal(ObjectInput in) throws IOException
readExternal in interface ExternalizableIOExceptionpublic int compareTo(IgniteUuid o)
compareTo in interface Comparable<IgniteUuid>public org.apache.ignite.internal.util.lang.GridIterator<IgniteUuid> iterator()
iterator in interface Iterable<IgniteUuid>public void writeBinary(BinaryWriter writer) throws BinaryObjectException
writeBinary in interface Binarylizablewriter - Binary object writer.BinaryObjectException - In case of error.public void readBinary(BinaryReader reader) throws BinaryObjectException
readBinary in interface Binarylizablereader - Binary object reader.BinaryObjectException - In case of error.public Object clone() throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedException
GridGain In-Memory Computing Platform : ver. 8.9.26 Release Date : October 16 2025