Record Class SegmentIdStat

java.lang.Object
java.lang.Record
me.ahoo.cosid.stat.generator.SegmentIdStat
All Implemented Interfaces:
IdGeneratorStat, Stat

public record SegmentIdStat(String kind, long fetchTime, long maxId, long offset, long sequence, long step, boolean isExpired, boolean isOverflow, boolean isAvailable, GroupedKey groupedKey, Stat converter) extends Record implements IdGeneratorStat
  • Constructor Summary

    Constructors
    Constructor
    Description
    SegmentIdStat(String kind, long fetchTime, long maxId, long offset, long sequence, long step, boolean isExpired, boolean isOverflow, boolean isAvailable, GroupedKey groupedKey, Stat converter)
    Creates an instance of a SegmentIdStat record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the value of the converter record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    long
    Returns the value of the fetchTime record component.
    Returns the value of the groupedKey record component.
    final int
    Returns a hash code value for this object.
    boolean
    Returns the value of the isAvailable record component.
    boolean
    Returns the value of the isExpired record component.
    boolean
    Returns the value of the isOverflow record component.
    Returns the value of the kind record component.
    long
    Returns the value of the maxId record component.
    long
    Returns the value of the offset record component.
    long
    Returns the value of the sequence record component.
    long
    Returns the value of the step record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface me.ahoo.cosid.stat.generator.IdGeneratorStat

    actual
  • Constructor Details

    • SegmentIdStat

      public SegmentIdStat(String kind, long fetchTime, long maxId, long offset, long sequence, long step, boolean isExpired, boolean isOverflow, boolean isAvailable, GroupedKey groupedKey, Stat converter)
      Creates an instance of a SegmentIdStat record class.
      Parameters:
      kind - the value for the kind record component
      fetchTime - the value for the fetchTime record component
      maxId - the value for the maxId record component
      offset - the value for the offset record component
      sequence - the value for the sequence record component
      step - the value for the step record component
      isExpired - the value for the isExpired record component
      isOverflow - the value for the isOverflow record component
      isAvailable - the value for the isAvailable record component
      groupedKey - the value for the groupedKey record component
      converter - the value for the converter record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • kind

      public String kind()
      Returns the value of the kind record component.
      Specified by:
      kind in interface Stat
      Returns:
      the value of the kind record component
    • fetchTime

      public long fetchTime()
      Returns the value of the fetchTime record component.
      Returns:
      the value of the fetchTime record component
    • maxId

      public long maxId()
      Returns the value of the maxId record component.
      Returns:
      the value of the maxId record component
    • offset

      public long offset()
      Returns the value of the offset record component.
      Returns:
      the value of the offset record component
    • sequence

      public long sequence()
      Returns the value of the sequence record component.
      Returns:
      the value of the sequence record component
    • step

      public long step()
      Returns the value of the step record component.
      Returns:
      the value of the step record component
    • isExpired

      public boolean isExpired()
      Returns the value of the isExpired record component.
      Returns:
      the value of the isExpired record component
    • isOverflow

      public boolean isOverflow()
      Returns the value of the isOverflow record component.
      Returns:
      the value of the isOverflow record component
    • isAvailable

      public boolean isAvailable()
      Returns the value of the isAvailable record component.
      Returns:
      the value of the isAvailable record component
    • groupedKey

      public GroupedKey groupedKey()
      Returns the value of the groupedKey record component.
      Returns:
      the value of the groupedKey record component
    • converter

      public Stat converter()
      Returns the value of the converter record component.
      Specified by:
      converter in interface IdGeneratorStat
      Returns:
      the value of the converter record component