Example #1
0
 protected BinaryNode(Node leftNode, Node rightNode)
 {
     Debug.Assert(leftNode != null);
     Debug.Assert(rightNode != null);
     this.leftNode = leftNode;
     this.rightNode = rightNode;
 }
Example #2
0
        protected TernaryNode(Node firstNode, Node secondNode, Node thirdNode)
        {
            Debug.Assert(firstNode != null);
            Debug.Assert(secondNode != null);
            Debug.Assert(thirdNode != null);

            this.firstNode = firstNode;
            this.secondNode = secondNode;
            this.thirdNode = thirdNode;
        }
Example #3
0
 public NotNode(Node node)
     : base(node)
 {
 }
        // turn the expression into an AST each time it changes (not each time our Convert methods are called)
        private void EnsureExpressionNode()
        {
            if (this.expressionNode != null || string.IsNullOrEmpty(this.expression))
            {
                return;
            }

            using (var stringReader = new StringReader(this.expression))
            using (var tokenizer = new Tokenizer(stringReader))
            using (var parser = new Parser(tokenizer))
            {
                this.expressionNode = parser.ParseExpression();
            }
        }
Example #5
0
 public NegateNode(Node node)
     : base(node)
 {
 }
 public TernaryConditionalNode(Node firstNode, Node secondNode, Node thirdNode)
     : base(firstNode, secondNode, thirdNode)
 {
 }
 public ComplementNode(Node node)
     : base(node)
 {
 }
 protected WideningBinaryNode(Node leftNode, Node rightNode)
     : base(leftNode, rightNode)
 {
 }
 protected ConditionalBinaryNode(Node leftNode, Node rightNode)
     : base(leftNode, rightNode)
 {
 }
Example #10
0
 public ShiftNode(Node leftNode, Node rightNode)
     : base(leftNode, rightNode)
 {
 }
Example #11
0
 protected UnaryNode(Node node)
 {
     Debug.Assert(node != null);
     this.node = node;
 }