Class JexlNode

    • Field Detail

      • lc

        private int lc
    • Constructor Detail

      • JexlNode

        public JexlNode​(int id)
      • JexlNode

        @Deprecated
        public JexlNode​(Parser p,
                        int id)
        Deprecated.
        Constructs a new instance.
        Parameters:
        p - not used.
        id - the node type identifier
    • Method Detail

      • clearCache

        public void clearCache()
        Clears any cached value of type JexlProperty{G,S}et or JexlMethod.

        This is called when the engine detects the evaluation of a script occurs with a class loader different that the one that created it.

      • getColumn

        public int getColumn()
      • getLine

        public int getLine()
      • isConstant

        public boolean isConstant()
        Whether this node is a constant node.

        Its value can not change after the first evaluation and can be cached indefinitely.

        Returns:
        true if constant, false otherwise
      • isConstant

        protected boolean isConstant​(boolean literal)
      • isGlobalVar

        public boolean isGlobalVar()
        Returns:
        true if this node looks like a global var
      • isLeftValue

        public boolean isLeftValue()
        Whether this node is a left value.
        Returns:
        true if node is assignable, false otherwise
      • isSafeLhs

        public boolean isSafeLhs​(boolean safe)
        Whether this node is the left-hand side of a safe access identifier as in. For instance, in 'x?.y' , 'x' is safe.
        Parameters:
        safe - whether the engine is in safe-navigation mode
        Returns:
        true if safe lhs, false otherwise
      • isStrictOperator

        public boolean isStrictOperator​(JexlArithmetic arithmetic)
        Checks whether this node is an operator that accepts a null argument even when arithmetic is in strict mode. The default cases are equals and not equals.
        Parameters:
        arithmetic - the node to test
        Returns:
        true if node accepts null arguments, false otherwise
      • jexlInfo

        public JexlInfo jexlInfo()
        Gets the associated JexlInfo instance.
        Returns:
        the info
      • jjtSetFirstToken

        public void jjtSetFirstToken​(Token t)
      • jjtSetLastToken

        public void jjtSetLastToken​(Token t)