Class TtcAddition


  • public final class TtcAddition
    extends TtcBinaryOperation
    Immutable class representing a TTC addition in a MAL language.
    Since:
    1.0.0
    • Constructor Detail

      • TtcAddition

        public TtcAddition​(TtcExpression lhs,
                           TtcExpression rhs)
        Constructs a new TtcAddition object.
        Parameters:
        lhs - the left-hand side of the addition
        rhs - the right-hand side of the addition
        Throws:
        NullPointerException - if lhs or rhs is null
        Since:
        1.0.0
    • Method Detail

      • getMeanTtc

        public double getMeanTtc()
        Description copied from class: TtcExpression
        Returns the mean TTC of this TtcExpression object.
        Overrides:
        getMeanTtc in class TtcExpression
        Returns:
        the mean TTC of this TtcExpression object
      • toJson

        public JsonObject toJson()
        Description copied from class: TtcExpression
        Returns the JSON representation of this TtcExpression object.
        Specified by:
        toJson in class TtcExpression
        Returns:
        the JSON representation of this TtcExpression object