Record Class QuestionDetails

java.lang.Object
java.lang.Record
org.ek9lang.compiler.ir.QuestionDetails

public record QuestionDetails(String result, OperandEvaluation operandEvaluation, String nullCheckCondition, OperandEvaluation nullCaseEvaluation, OperandEvaluation setCaseEvaluation, BasicDetails basicDetails) extends Record
Just holds the details relating to the 'is set' functionality. While there is an operator '_isSet' (?), the same concept is used elsewhere. For example in guard assignment statements and also in guarded if/for/while etc.
  • Constructor Details

    • QuestionDetails

      public QuestionDetails(String result, OperandEvaluation operandEvaluation, String nullCheckCondition, OperandEvaluation nullCaseEvaluation, OperandEvaluation setCaseEvaluation, BasicDetails basicDetails)
      Creates an instance of a QuestionDetails record class.
      Parameters:
      result - the value for the result record component
      operandEvaluation - the value for the operandEvaluation record component
      nullCheckCondition - the value for the nullCheckCondition record component
      nullCaseEvaluation - the value for the nullCaseEvaluation record component
      setCaseEvaluation - the value for the setCaseEvaluation record component
      basicDetails - the value for the basicDetails 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.
    • result

      public String result()
      Returns the value of the result record component.
      Returns:
      the value of the result record component
    • operandEvaluation

      public OperandEvaluation operandEvaluation()
      Returns the value of the operandEvaluation record component.
      Returns:
      the value of the operandEvaluation record component
    • nullCheckCondition

      public String nullCheckCondition()
      Returns the value of the nullCheckCondition record component.
      Returns:
      the value of the nullCheckCondition record component
    • nullCaseEvaluation

      public OperandEvaluation nullCaseEvaluation()
      Returns the value of the nullCaseEvaluation record component.
      Returns:
      the value of the nullCaseEvaluation record component
    • setCaseEvaluation

      public OperandEvaluation setCaseEvaluation()
      Returns the value of the setCaseEvaluation record component.
      Returns:
      the value of the setCaseEvaluation record component
    • basicDetails

      public BasicDetails basicDetails()
      Returns the value of the basicDetails record component.
      Returns:
      the value of the basicDetails record component