예제 #1
0
 internal override void RemoveChild(Node child)
 {
     if (_token_ == child)
     {
         _token_ = null;
         return;
     }
     if (_cond_ == child)
     {
         _cond_ = null;
         return;
     }
     if (_then_ == child)
     {
         _then_ = null;
         return;
     }
     if (_else_ == child)
     {
         _else_ = null;
         return;
     }
 }
예제 #2
0
        public void SetToken(TQuestionmark node)
        {
            if (_token_ != null)
            {
                _token_.Parent(null);
            }

            if (node != null)
            {
                if (node.Parent() != null)
                {
                    node.Parent().RemoveChild(node);
                }

                node.Parent(this);
            }

            _token_ = node;
        }
예제 #3
0
 public virtual void CaseTQuestionmark(TQuestionmark node)
 {
     DefaultCase(node);
 }
예제 #4
0
 public AIfExp(
         TQuestionmark _token_,
         PExp _cond_,
         PExp _then_,
         PExp _else_
 )
 {
     SetToken(_token_);
     SetCond(_cond_);
     SetThen(_then_);
     SetElse(_else_);
 }
예제 #5
0
 public override void CaseTQuestionmark(TQuestionmark node)
 {
     index = 64;
 }