Record Class ProjectionAstNode

java.lang.Object
java.lang.Record
org.impulsegraph.compiler.cel.ProjectionAstNode

public record ProjectionAstNode(String targetStateField, Reducer reducer, String coReducerParam, CelAstNode rhsExpression) extends Record
Represents a single parsed state projection assignment and reduction rule.
  • Constructor Details

    • ProjectionAstNode

      public ProjectionAstNode(String targetStateField, Reducer reducer, String coReducerParam, CelAstNode rhsExpression)
      Creates an instance of a ProjectionAstNode record class.
      Parameters:
      targetStateField - the value for the targetStateField record component
      reducer - the value for the reducer record component
      coReducerParam - the value for the coReducerParam record component
      rhsExpression - the value for the rhsExpression record component
  • Method Details

    • 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.
    • targetStateField

      public String targetStateField()
      Returns the value of the targetStateField record component.
      Returns:
      the value of the targetStateField record component
    • reducer

      public Reducer reducer()
      Returns the value of the reducer record component.
      Returns:
      the value of the reducer record component
    • coReducerParam

      public String coReducerParam()
      Returns the value of the coReducerParam record component.
      Returns:
      the value of the coReducerParam record component
    • rhsExpression

      public CelAstNode rhsExpression()
      Returns the value of the rhsExpression record component.
      Returns:
      the value of the rhsExpression record component