コード例 #1
0
 //internal Queue<Term> Changed;
 private void AddChanged(Term t)
 {
     if (!Changed.Contains(t))
     {
         Changed.Enqueue(t);
     }
     //Changed.Enqueue(t);
     //Changed.MoveToEnd(t);
 }
コード例 #2
0
        //internal Queue<Term> Changed;

        /*private void AddAllChanged(List<Term> l) {
         *      foreach(Term t in l) {
         *              if(!Changed.Contains(t)) Changed.Enqueue(t);
         *      }
         * }*/
        private void AddChanged(Term t)
        {
            /*foreach(Term s in t.Parents) {
             *      Changed.Enqueue(s);
             * }
             * Changed.Enqueue(t);*/
            foreach (Term s in t.Parents)
            {
                //Changed.Enqueue(s);
                if (!Changed.Contains(s))
                {
                    Changed.Enqueue(s);
                }
                //Changed.MoveToEnd(s);
            }
            if (!Changed.Contains(t))
            {
                Changed.Enqueue(t);
            }
            //Changed.Enqueue(t);
        }