org.sadun.util
Class UniqueIdGenerator
java.lang.Object
org.sadun.util.UniqueIdGenerator
- public class UniqueIdGenerator
- extends java.lang.Object
A generator of IDs unique even across different machines.
- Author:
- Cristiano Sadun
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UniqueIdGenerator
protected UniqueIdGenerator()
getInstance
public static UniqueIdGenerator getInstance()
- Return the JVM-unique instance of the generator.
- Returns:
- the JVM-unique instance of the generator.
getNextId
public java.lang.String getNextId(java.lang.String hint)
getNextId
public java.lang.String getNextId()
main
public static void main(java.lang.String[] args)