org.openmdx.kernel.id.plugin
Class TimeBasedUUIDGeneratorUsingIP4Address

java.lang.Object
  extended by org.openmdx.kernel.id.spi.TimeBasedIdBuilder
      extended by org.openmdx.kernel.id.spi.TimeBasedIdGenerator
          extended by org.openmdx.kernel.id.plugin.TimeBasedUUIDGeneratorUsingIP4Address
All Implemented Interfaces:
UUIDGenerator

public class TimeBasedUUIDGeneratorUsingIP4Address
extends TimeBasedIdGenerator
implements UUIDGenerator

Time Based UUID Provider using IP 4 Address Based Nodes

This implementation follow the guidelines of http://www.ietf.org/internet-drafts/draft-mealling-uuid-urn-03.txt and avoids conflicts with TimeBasedUUIDGeneratorUsingRandomBasedNodes by setting the bit next to the MAC address multicast bit.


Constructor Summary
TimeBasedUUIDGeneratorUsingIP4Address()
           
 
Method Summary
protected  long getNode()
          The 48 bit node value is used to set the node field of this UUID.
 UUID next()
           
 
Methods inherited from class org.openmdx.kernel.id.spi.TimeBasedIdGenerator
getClockSequence, getRandom, getRandomBasedNode, getSystemTimeFrame, getTimeFrame, getTimestamp
 
Methods inherited from class org.openmdx.kernel.id.spi.TimeBasedIdBuilder
nextLeastSignificantBits, nextMostSignificantBits
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TimeBasedUUIDGeneratorUsingIP4Address

public TimeBasedUUIDGeneratorUsingIP4Address()
Method Detail

getNode

protected long getNode()
Description copied from class: TimeBasedIdBuilder
The 48 bit node value is used to set the node field of this UUID. This field is intended to hold the IEEE 802 address of the machine that generated this UUID to guarantee spatial uniqueness.

The node id has to be provided by a subclass.

Overrides:
getNode in class TimeBasedIdGenerator
Returns:
this UUID prvider's host id.

next

public UUID next()
Specified by:
next in interface UUIDGenerator


This software is published under the BSD license. Copyright © 2003-2007, OMEX AG, Switzerland, All rights reserved. Use is subject to license terms.