Record Class SnapshotDeletionsInProgress.Entry

java.lang.Object
java.lang.Record
org.elasticsearch.cluster.SnapshotDeletionsInProgress.Entry
All Implemented Interfaces:
Writeable, RepositoryOperation
Enclosing class:
SnapshotDeletionsInProgress

public static record SnapshotDeletionsInProgress.Entry(String repoName, List<SnapshotId> snapshots, long startTime, long repositoryStateId, SnapshotDeletionsInProgress.State state, String uuid) extends Record implements Writeable, RepositoryOperation
A class representing a snapshot deletion request entry in the cluster state.
  • Constructor Details

    • Entry

      public Entry(String repoName, List<SnapshotId> snapshots, long startTime, long repositoryStateId, SnapshotDeletionsInProgress.State state)
    • Entry

      public Entry(String repoName, List<SnapshotId> snapshots, long startTime, long repositoryStateId, SnapshotDeletionsInProgress.State state, String uuid)
      Creates an instance of a Entry record class.
      Parameters:
      repoName - the value for the repoName record component
      snapshots - the value for the snapshots record component
      startTime - the value for the startTime record component
      repositoryStateId - the value for the repositoryStateId record component
      state - the value for the state record component
      uuid - the value for the uuid record component
  • Method Details

    • readFrom

      public static SnapshotDeletionsInProgress.Entry readFrom(StreamInput in) throws IOException
      Throws:
      IOException
    • started

    • withAddedSnapshots

      public SnapshotDeletionsInProgress.Entry withAddedSnapshots(Collection<SnapshotId> newSnapshots)
    • withSnapshots

      public SnapshotDeletionsInProgress.Entry withSnapshots(Collection<SnapshotId> snapshots)
    • withRepoGen

      public SnapshotDeletionsInProgress.Entry withRepoGen(long repoGen)
    • writeTo

      public void writeTo(StreamOutput out) throws IOException
      Description copied from interface: Writeable
      Write this into the StreamOutput.
      Specified by:
      writeTo in interface Writeable
      Throws:
      IOException
    • repository

      public String repository()
      Description copied from interface: RepositoryOperation
      Name of the repository affected.
      Specified by:
      repository in interface RepositoryOperation
    • repositoryStateId

      public long repositoryStateId()
      Returns the value of the repositoryStateId record component.
      Specified by:
      repositoryStateId in interface RepositoryOperation
      Returns:
      the value of the repositoryStateId record component
    • 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.
    • repoName

      public String repoName()
      Returns the value of the repoName record component.
      Returns:
      the value of the repoName record component
    • snapshots

      public List<SnapshotId> snapshots()
      Returns the value of the snapshots record component.
      Returns:
      the value of the snapshots record component
    • startTime

      public long startTime()
      Returns the value of the startTime record component.
      Returns:
      the value of the startTime record component
    • state

      Returns the value of the state record component.
      Returns:
      the value of the state record component
    • uuid

      public String uuid()
      Returns the value of the uuid record component.
      Returns:
      the value of the uuid record component