Module aya.base

Record Class SerDef.Fn

java.lang.Object
java.lang.Record
org.aya.core.serde.SerDef.Fn
All Implemented Interfaces:
Serializable, SerDef, SerShapable
Enclosing interface:
SerDef

public static record SerDef.Fn(@NotNull SerDef.QName name, @NotNull kala.collection.immutable.ImmutableSeq<SerTerm.SerParam> telescope, @NotNull kala.control.Either<SerTerm,kala.collection.immutable.ImmutableSeq<SerPat.Clause>> body, @NotNull EnumSet<Modifier> modifiers, @NotNull SerTerm result, @Nullable SerDef.SerShapeResult shapeResult) extends Record implements SerDef, SerShapable
See Also:
  • Constructor Details

    • Fn

      public Fn(@NotNull @NotNull SerDef.QName name, @NotNull @NotNull kala.collection.immutable.ImmutableSeq<SerTerm.SerParam> telescope, @NotNull @NotNull kala.control.Either<SerTerm,kala.collection.immutable.ImmutableSeq<SerPat.Clause>> body, @NotNull @NotNull EnumSet<Modifier> modifiers, @NotNull @NotNull SerTerm result, @Nullable @Nullable SerDef.SerShapeResult shapeResult)
      Creates an instance of a Fn record class.
      Parameters:
      name - the value for the name record component
      telescope - the value for the telescope record component
      body - the value for the body record component
      modifiers - the value for the modifiers record component
      result - the value for the result record component
      shapeResult - the value for the shapeResult record component
  • Method Details

    • de

      @NotNull public @NotNull Def de(@NotNull SerTerm.DeState state)
      Specified by:
      de in interface SerDef
    • 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.
    • name

      @NotNull public @NotNull SerDef.QName name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • telescope

      @NotNull public @NotNull kala.collection.immutable.ImmutableSeq<SerTerm.SerParam> telescope()
      Returns the value of the telescope record component.
      Returns:
      the value of the telescope record component
    • body

      @NotNull public @NotNull kala.control.Either<SerTerm,kala.collection.immutable.ImmutableSeq<SerPat.Clause>> body()
      Returns the value of the body record component.
      Returns:
      the value of the body record component
    • modifiers

      @NotNull public @NotNull EnumSet<Modifier> modifiers()
      Returns the value of the modifiers record component.
      Returns:
      the value of the modifiers record component
    • result

      @NotNull public @NotNull SerTerm result()
      Returns the value of the result record component.
      Returns:
      the value of the result record component
    • shapeResult

      @Nullable public @Nullable SerDef.SerShapeResult shapeResult()
      Returns the value of the shapeResult record component.
      Specified by:
      shapeResult in interface SerShapable
      Returns:
      the value of the shapeResult record component