Class Monad

    • Constructor Detail

      • Monad

        public Monad​(boolean postFix)
      • Monad

        public Monad​(boolean postFix,
                     TokenPosition tokenPosition)
      • Monad

        public Monad​(int operatorType,
                     boolean isPostFix)
      • Monad

        public Monad​(int operatorType,
                     boolean isPostFix,
                     TokenPosition tokenPosition)
      • Monad

        public Monad​(int operatorType,
                     ExpressionNode argument)
        Constructor for making a post fix monad.
        Parameters:
        operatorType -
        argument -
      • Monad

        public Monad​(int operatorType,
                     ExpressionNode argument,
                     boolean isPostFix)
        Constructor for specifying the type of operator.
        Parameters:
        operatorType -
        argument -
        isPostFix -
    • Method Detail

      • isPostFix

        public boolean isPostFix()
      • setPostFix

        public void setPostFix​(boolean postFix)
      • isSigned

        public boolean isSigned()
      • getSignedLongValue

        public Long getSignedLongValue()
      • getSignedDecimalValue

        public BigDecimal getSignedDecimalValue()
      • getNodeType

        public int getNodeType()
        Description copied from interface: ExpressionInterface
        QDL is not strongly typed but Java is, so each node type should have a unique integer and conditionals should use that, not the instanceof operator. This allows for efficient programming with switch statements rather than a bevy of conditionals (potentially each of which gets done even if the correct case has been handled).
        Returns: