|
|||||||||
| Home >> All >> java >> rmi >> [ server overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.rmi.server
Class UID

java.lang.Objectjava.rmi.server.UID
- All Implemented Interfaces:
- java.io.Serializable
- public final class UID
- extends java.lang.Object
- implements java.io.Serializable
- extends java.lang.Object
Represents the unique identifier over time for the host which has generated it. It contains time (when created), counter (the number of the UID creation order) and virtual machine id components. The UID can also be constructed specifying a "well known" identifier in the for of short: this identifier defines the UID uniqueness alone.
| Field Summary | |
private short |
count
The UID number in the UID creation sequence. |
private static long |
last
The time, when the last UID has been created. |
private static int |
machineId
This constant tries to be the unique identifier of the virtual machine. |
private static long |
serialVersionUID
Use the serial version uid for interoperability. |
private long |
time
The time stamp, when the UID was created. |
private static short |
uidCounter
The UID counter (the ordinary number in the sequence of number of UID's, created during the recent millisecond). |
private int |
unique
Always gets the uniqueNr value. |
| Constructor Summary | |
UID()
Create the new UID that would have the described features of the uniqueness. |
|
UID(short wellKnownId)
Create the new UID with the well known id (number). |
|
| Method Summary | |
boolean |
equals(java.lang.Object other)
Compare this UID with another UID for equality (not equal to other types of objects). |
(package private) static int |
getMachineId()
Do our best to get the Id of this virtual machine. |
int |
hashCode()
Get the hashCode of this UID. |
static UID |
read(java.io.DataInput in)
|
java.lang.String |
toString()
Get the string representation of this UID. |
void |
write(java.io.DataOutput out)
|
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
serialVersionUID
private static final long serialVersionUID
- Use the serial version uid for interoperability.
- See Also:
- Constant Field Values
uidCounter
private static short uidCounter
- The UID counter (the ordinary number in the sequence of number of UID's,
created during the recent millisecond). In the next millisecond, it
starts from the minimal value again. In the unlikely case of creating
more than 65536 uids per millisecond the process pauses till the next
ms.
last
private static long last
- The time, when the last UID has been created.
machineId
private static final int machineId
- This constant tries to be the unique identifier of the virtual machine.
count
private short count
- The UID number in the UID creation sequence.
unique
private int unique
- Always gets the uniqueNr value.
time
private long time
- The time stamp, when the UID was created.
| Constructor Detail |
UID
public UID()
- Create the new UID that would have the described features of the
uniqueness.
UID
public UID(short wellKnownId)
- Create the new UID with the well known id (number). All UIDs, creates
with the this constructor having the same parameter are equal to each
other (regardless to the host and time where they were created.
| Method Detail |
hashCode
public int hashCode()
- Get the hashCode of this UID.
equals
public boolean equals(java.lang.Object other)
- Compare this UID with another UID for equality (not equal to other types of
objects).
read
public static UID read(java.io.DataInput in) throws java.io.IOException
write
public void write(java.io.DataOutput out) throws java.io.IOException
getMachineId
static int getMachineId()
- Do our best to get the Id of this virtual machine.
toString
public java.lang.String toString()
- Get the string representation of this UID.
|
|||||||||
| Home >> All >> java >> rmi >> [ server overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
java.rmi.server.UID