Package me.ahoo.cosid.segment
Class MergedIdSegment
java.lang.Object
me.ahoo.cosid.segment.MergedIdSegment
- All Implemented Interfaces:
Comparable<IdSegment>
,Grouped
,IdSegment
Merged IdSegment.
-
Field Summary
Fields inherited from interface me.ahoo.cosid.segment.IdSegment
SEQUENCE_OVERFLOW, TIME_TO_LIVE_FOREVER
-
Constructor Summary
-
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface me.ahoo.cosid.segment.IdSegment
compareTo, ensureNextIdSegment, isAvailable, isExpired, isOverflow, isOverflow
-
Constructor Details
-
MergedIdSegment
-
-
Method Details
-
group
-
getSegments
public int getSegments() -
getSingleStep
public long getSingleStep() -
getFetchTime
public long getFetchTime()ID segment fetch time. unitTimeUnit.MILLISECONDS
- Specified by:
getFetchTime
in interfaceIdSegment
- Returns:
- Fetch Time
-
getMaxId
public long getMaxId() -
getOffset
public long getOffset() -
getSequence
public long getSequence()- Specified by:
getSequence
in interfaceIdSegment
-
getStep
public long getStep() -
getTtl
public long getTtl()Description copied from interface:IdSegment
the id segment time to live. unitTimeUnit.SECONDS
-
incrementAndGet
public long incrementAndGet()- Specified by:
incrementAndGet
in interfaceIdSegment
-
toString
-