Module aya.base
Package org.aya.tyck

Record Class TyckState

java.lang.Object
java.lang.Record
org.aya.tyck.TyckState

public record TyckState(@NotNull kala.collection.mutable.MutableList<TyckState.Eqn> eqns, @NotNull kala.collection.mutable.MutableList<org.aya.util.error.WithPos<org.aya.syntax.ref.MetaVar>> activeMetas, @NotNull kala.collection.mutable.MutableMap<org.aya.syntax.ref.MetaVar,org.aya.syntax.core.term.Term> solutions, @NotNull ShapeFactory shapeFactory, @NotNull PrimFactory primFactory) extends Record
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static final record 
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    TyckState(@NotNull kala.collection.mutable.MutableList<TyckState.Eqn> eqns, @NotNull kala.collection.mutable.MutableList<org.aya.util.error.WithPos<org.aya.syntax.ref.MetaVar>> activeMetas, @NotNull kala.collection.mutable.MutableMap<org.aya.syntax.ref.MetaVar,org.aya.syntax.core.term.Term> solutions, @NotNull ShapeFactory shapeFactory, @NotNull PrimFactory primFactory)
    Creates an instance of a TyckState record class.
    TyckState(@NotNull ShapeFactory shapeFactory, @NotNull PrimFactory primFactory)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    @NotNull kala.collection.mutable.MutableList<org.aya.util.error.WithPos<org.aya.syntax.ref.MetaVar>>
    Returns the value of the activeMetas record component.
    void
     
    @NotNull org.aya.syntax.core.term.Term
    computeSolution(@NotNull org.aya.syntax.core.term.call.MetaCall meta, @NotNull UnaryOperator<org.aya.syntax.core.term.Term> f)
     
    @NotNull kala.collection.mutable.MutableList<TyckState.Eqn>
    Returns the value of the eqns record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    @NotNull PrimFactory
    Returns the value of the primFactory record component.
    @NotNull ShapeFactory
    Returns the value of the shapeFactory record component.
    @NotNull kala.collection.mutable.MutableMap<org.aya.syntax.ref.MetaVar,org.aya.syntax.core.term.Term>
    Returns the value of the solutions record component.
    void
    solve(org.aya.syntax.ref.MetaVar meta, org.aya.syntax.core.term.Term candidate)
     
    void
    solveMetas(@NotNull org.aya.util.reporter.Reporter reporter)
     
    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
  • Constructor Details

    • TyckState

      public TyckState(@NotNull @NotNull ShapeFactory shapeFactory, @NotNull @NotNull PrimFactory primFactory)
    • TyckState

      public TyckState(@NotNull @NotNull kala.collection.mutable.MutableList<TyckState.Eqn> eqns, @NotNull @NotNull kala.collection.mutable.MutableList<org.aya.util.error.WithPos<org.aya.syntax.ref.MetaVar>> activeMetas, @NotNull @NotNull kala.collection.mutable.MutableMap<org.aya.syntax.ref.MetaVar,org.aya.syntax.core.term.Term> solutions, @NotNull @NotNull ShapeFactory shapeFactory, @NotNull @NotNull PrimFactory primFactory)
      Creates an instance of a TyckState record class.
      Parameters:
      eqns - the value for the eqns record component
      activeMetas - the value for the activeMetas record component
      solutions - the value for the solutions record component
      shapeFactory - the value for the shapeFactory record component
      primFactory - the value for the primFactory record component
  • Method Details

    • solve

      @Internal public void solve(org.aya.syntax.ref.MetaVar meta, org.aya.syntax.core.term.Term candidate)
    • solveMetas

      public void solveMetas(@NotNull @NotNull org.aya.util.reporter.Reporter reporter)
    • computeSolution

      @NotNull public @NotNull org.aya.syntax.core.term.Term computeSolution(@NotNull @NotNull org.aya.syntax.core.term.call.MetaCall meta, @NotNull @NotNull UnaryOperator<org.aya.syntax.core.term.Term> f)
    • addEqn

      public void addEqn(TyckState.Eqn eqn)
    • 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.
    • eqns

      @NotNull public @NotNull kala.collection.mutable.MutableList<TyckState.Eqn> eqns()
      Returns the value of the eqns record component.
      Returns:
      the value of the eqns record component
    • activeMetas

      @NotNull public @NotNull kala.collection.mutable.MutableList<org.aya.util.error.WithPos<org.aya.syntax.ref.MetaVar>> activeMetas()
      Returns the value of the activeMetas record component.
      Returns:
      the value of the activeMetas record component
    • solutions

      @NotNull public @NotNull kala.collection.mutable.MutableMap<org.aya.syntax.ref.MetaVar,org.aya.syntax.core.term.Term> solutions()
      Returns the value of the solutions record component.
      Returns:
      the value of the solutions record component
    • shapeFactory

      @NotNull public @NotNull ShapeFactory shapeFactory()
      Returns the value of the shapeFactory record component.
      Returns:
      the value of the shapeFactory record component
    • primFactory

      @NotNull public @NotNull PrimFactory primFactory()
      Returns the value of the primFactory record component.
      Returns:
      the value of the primFactory record component