Record Class WebEngineStats.Snapshot

java.lang.Object
java.lang.Record
com.iizix.server.webengine.WebEngineStats.Snapshot
Record Components:
since - When counting started: the server start.
totals - The totals of every status, all four present.
rows - The group rows: ENDED first, then BEHIND, then the others, within a status the row with the most connects first.
Enclosing class:
WebEngineStats

public static record WebEngineStats.Snapshot(Instant since, Map<WebEngineStatus.Status, WebEngineStats.Totals> totals, List<WebEngineStats.Row> rows) extends Record
The counts at one moment, detached from the live instance.
Author:
Christopher Mindus
  • Constructor Details

  • Method Details

    • of

      Gets the totals of a status.
      Parameters:
      status - The status.
      Returns:
      The totals, never null.
    • unpatched

      public WebEngineStats.Totals unpatched()
      Gets the totals of the sessions ServerAdmin counts as unpatched: BEHIND and ENDED together.
      Returns:
      The totals.
    • 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. All components in this record class are compared with Objects::equals(Object,Object).
      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.
    • since

      public Instant since()
      Returns the value of the since record component.
      Returns:
      the value of the since record component
    • totals

      Returns the value of the totals record component.
      Returns:
      the value of the totals record component
    • rows

      public List<WebEngineStats.Row> rows()
      Returns the value of the rows record component.
      Returns:
      the value of the rows record component