Class AltCombGuidCreator
- java.lang.Object
-
- com.github.f4b6a3.uuid.creator.AbstractUuidCreator
-
- com.github.f4b6a3.uuid.creator.AbstractRandomBasedUuidCreator
-
- com.github.f4b6a3.uuid.creator.nonstandard.AltCombGuidCreator
-
- All Implemented Interfaces:
NoArgumentsUuidCreator
public class AltCombGuidCreator extends AbstractRandomBasedUuidCreator
Factory that creates alternate COMB GUIDs. A COMB GUID is a UUID that combines a creation time with random bits. The creation time is a PREFIX at the MOST significant bits. The Cost of GUIDs as Primary Keys (COMB GUID inception): http://www.informit.com/articles/article.aspx?p=25862
-
-
Field Summary
-
Fields inherited from class com.github.f4b6a3.uuid.creator.AbstractRandomBasedUuidCreator
random
-
Fields inherited from class com.github.f4b6a3.uuid.creator.AbstractUuidCreator
version, versionBits
-
-
Constructor Summary
Constructors Constructor Description AltCombGuidCreator()AltCombGuidCreator(UuidVersion version)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UUIDcreate()Returns a COMB GUID.-
Methods inherited from class com.github.f4b6a3.uuid.creator.AbstractRandomBasedUuidCreator
withFastRandomGenerator, withRandomGenerator
-
Methods inherited from class com.github.f4b6a3.uuid.creator.AbstractUuidCreator
applyVariantBits, applyVersionBits, getVersion
-
-
-
-
Constructor Detail
-
AltCombGuidCreator
public AltCombGuidCreator()
-
AltCombGuidCreator
public AltCombGuidCreator(UuidVersion version)
-
-
Method Detail
-
create
public UUID create()
Returns a COMB GUID. It combines creation time with random bits. The creation time is a PREFIX at the MOST significant bits.- Specified by:
createin interfaceNoArgumentsUuidCreator- Overrides:
createin classAbstractRandomBasedUuidCreator- Returns:
- a random-based UUID
-
-