Record Class SnapshotDiff.DiffSummary

java.lang.Object
java.lang.Record
com.tnsai.context.snapshot.SnapshotDiff.DiffSummary
Enclosing class:
SnapshotDiff

public static record SnapshotDiff.DiffSummary(int bdiAdded, int bdiRemoved, int entitiesAdded, int entitiesRemoved, int variableChanges, Duration timeElapsed) extends Record
Summary of changes between snapshots.
  • Constructor Summary

    Constructors
    Constructor
    Description
    DiffSummary(int bdiAdded, int bdiRemoved, int entitiesAdded, int entitiesRemoved, int variableChanges, Duration timeElapsed)
    Creates an instance of a DiffSummary record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Returns the value of the bdiAdded record component.
    int
    Returns the value of the bdiRemoved record component.
    int
    Returns the value of the entitiesAdded record component.
    int
    Returns the value of the entitiesRemoved record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    Returns the value of the timeElapsed record component.
    Returns a string representation of this record class.
    int
     
    int
     
    int
    Returns the value of the variableChanges record component.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • DiffSummary

      public DiffSummary(int bdiAdded, int bdiRemoved, int entitiesAdded, int entitiesRemoved, int variableChanges, Duration timeElapsed)
      Creates an instance of a DiffSummary record class.
      Parameters:
      bdiAdded - the value for the bdiAdded record component
      bdiRemoved - the value for the bdiRemoved record component
      entitiesAdded - the value for the entitiesAdded record component
      entitiesRemoved - the value for the entitiesRemoved record component
      variableChanges - the value for the variableChanges record component
      timeElapsed - the value for the timeElapsed record component
  • Method Details

    • totalBDIChanges

      public int totalBDIChanges()
    • totalEntityChanges

      public int totalEntityChanges()
    • toString

      public 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.
    • bdiAdded

      public int bdiAdded()
      Returns the value of the bdiAdded record component.
      Returns:
      the value of the bdiAdded record component
    • bdiRemoved

      public int bdiRemoved()
      Returns the value of the bdiRemoved record component.
      Returns:
      the value of the bdiRemoved record component
    • entitiesAdded

      public int entitiesAdded()
      Returns the value of the entitiesAdded record component.
      Returns:
      the value of the entitiesAdded record component
    • entitiesRemoved

      public int entitiesRemoved()
      Returns the value of the entitiesRemoved record component.
      Returns:
      the value of the entitiesRemoved record component
    • variableChanges

      public int variableChanges()
      Returns the value of the variableChanges record component.
      Returns:
      the value of the variableChanges record component
    • timeElapsed

      public Duration timeElapsed()
      Returns the value of the timeElapsed record component.
      Returns:
      the value of the timeElapsed record component