StatePair (Lucene 10.5.0 core API)
Description: declaration: package: org.apache.lucene.util.automaton, class: StatePair

Package org.apache.lucene.util.automaton

# Class StatePair

java.lang.Object
org.apache.lucene.util.automaton.StatePair

public class StatePair extends Object
Pair of states.

WARNING: This API is experimental and might change in incompatible ways in the next release.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `final int`
  `s1`
  first state
  `final int`
  `s2`
  second state

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `StatePair(int s1, int s2)`
  Constructs a new state pair.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `equals(Object obj)`
  Checks for equality.
  `int`
  `hashCode()`
  Returns hash code.
  `String`
  `toString()`

  ### Methods inherited from class java.lang.Object

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

- ## Field Details

  - ### s1

    public final int s1
    first state

  - ### s2

    public final int s2
    second state

- ## Constructor Details

  - ### StatePair

    public StatePair(int s1, int s2)
    Constructs a new state pair.
    Parameters:
      `s1` - first state
      `s2` - second state

- ## Method Details

  - ### equals

    public boolean equals(Object obj)
    Checks for equality.
    Overrides:
      `equals` in class `Object`
    Parameters:
      `obj` - object to compare with
    Returns:
      true if `obj` represents the same pair of states as this pair

  - ### hashCode

    public int hashCode()
    Returns hash code.
    Overrides:
      `hashCode` in class `Object`
    Returns:
      hash code

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`