Class Hierarchy Previous Next Index
Interface COM.cloudscape.types.UUID
- public interface UUID
- extends java.io.Externalizable
Copyright © 1998-2000, Informix Software, Inc. All rights reserved.
An interface for accessing Cloudscape UUIDs, universally
unique identifiers. A Cloudscape UUID is expected to be unique
across all Cloudscape databases.
The values in the
system catalog held in ID columns with a type of CHAR(36) are the
string representations of these UUIDs. CHAR(36) is used in the
system catalog since in the current release, Java data types are
not indexable.
If you do not need your id column indexed, you can use this type directly
for the column type; if you need an index, then you can create UUIDs
with this class and store their toString values in indexed CHAR(36)
columns.
A UUID implements equals() and hashCode based on value equality.
The toString() method produces a string representation of this UUID which
can be passed to UUIDFactory.recreateUUID later on
to reconstruct it.
UUID_BYTE_LENGTH- UUID_BYTE_LENGTH
The number of bytes in the array toByteArray returns.
cloneMe()
- Clone this UUID.
getLong(int)
- Represent this UUID as 3 longs, numbered 0-2.
toANSIidentifier()
- Produce a string representation of this UUID which
is suitable for use as a unique ANSI identifier.
toByteArray()
- Produce a byte array representation of this UUID
which can be passed to UUIDFactory.recreateUUID later
on to reconstruct it.
toHexString()
- Create a hex string representation of this UUID.
UUID_BYTE_LENGTH
public static final int UUID_BYTE_LENGTH
UUID_BYTE_LENGTH
The number of bytes in the array toByteArray returns.
toANSIidentifier
public java.lang.String toANSIidentifier()
Produce a string representation of this UUID which
is suitable for use as a unique ANSI identifier.
toByteArray
public byte[] toByteArray()
Produce a byte array representation of this UUID
which can be passed to UUIDFactory.recreateUUID later
on to reconstruct it.
cloneMe
public UUID cloneMe()
Clone this UUID.
- Returns:
- a copy of this UUID
toHexString
public java.lang.String toHexString()
Create a hex string representation of this UUID.
getLong
public long getLong(int longIndex)
Represent this UUID as 3 longs, numbered 0-2. Return the ith
long.
- Parameters:
longIndex
- which long to get. numbered 0-2
- Returns:
- the corresponding long
Class Hierarchy Previous Next Index