SequenceReference implements Comparable<SequenceReference> { public Date toDate() { return SequenceReferences.toDate( value ); } SequenceReference(long value); long getValue(); @Override int compareTo(SequenceReference o); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); Date toDate(); Time toTime(); static final long GLOBAL_TIME_PADDING; static final long LOCAL_WRITER_ID_PADDING; static final long TIME_RESOLUTION; }
@Test public void testProductionSequence() throws Exception { SequenceReference sequenceReference = new SequenceReference(1461629328629600000L); String timestamp = ISO8601.format(sequenceReference.toDate()); assertEquals("2016-04-26T00:08:48Z", timestamp); }