Module com.github.f4b6a3.uuid
Class TimeOrderedFactory
- java.lang.Object
-
- com.github.f4b6a3.uuid.factory.UuidFactory
-
- com.github.f4b6a3.uuid.factory.AbstTimeBasedFactory
-
- com.github.f4b6a3.uuid.factory.rfc4122.TimeOrderedFactory
-
- All Implemented Interfaces:
NoArgsFactory
public final class TimeOrderedFactory extends AbstTimeBasedFactory
Factory that creates ordered gregorian time-based UUIDs. RFC-4122 version: 6. IETF Draft: https://tools.ietf.org/html/draft-peabody-dispatch-new-uuid-format
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classTimeOrderedFactory.Builder
-
Field Summary
-
Fields inherited from class com.github.f4b6a3.uuid.factory.AbstTimeBasedFactory
clockseqFunction, EPOCH_GREG, EPOCH_UNIX, epochTimestamp, nodeidFunction, timeFunction
-
Fields inherited from class com.github.f4b6a3.uuid.factory.UuidFactory
version, versionMask
-
-
Constructor Summary
Constructors Constructor Description TimeOrderedFactory()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static TimeOrderedFactory.Builderbuilder()protected longformatMostSignificantBits(long timestamp)Returns the timestamp bits of the UUID version 6, keeping its byte order unchanged.-
Methods inherited from class com.github.f4b6a3.uuid.factory.AbstTimeBasedFactory
create, create, formatLeastSignificantBits, selectNodeIdFunction
-
Methods inherited from class com.github.f4b6a3.uuid.factory.UuidFactory
getUuid, getUuid, getVersion
-
-
-
-
Method Detail
-
builder
public static TimeOrderedFactory.Builder builder()
-
formatMostSignificantBits
protected long formatMostSignificantBits(long timestamp)
Returns the timestamp bits of the UUID version 6, keeping its byte order unchanged.- Overrides:
formatMostSignificantBitsin classAbstTimeBasedFactory- Parameters:
timestamp- a timestamp- Returns:
- the MSB
-
-