Beispiel #1
0
 public SubSetSearchState(int pos, int d, ITerm t, SubSetSearchState father)
 {
     this.pos = pos;
     this.d   = d;
     value    = t;
     f        = father;
 }
Beispiel #2
0
                public List <ITerm> GetAsList()
                {
                    List <ITerm>      np = new List <ITerm>();
                    SubSetSearchState c  = this;

                    while (c.value != null)
                    {
                        np.Insert(0, c.value);
                        c = c.f;
                    }
                    return(np);
                }
Beispiel #3
0
            //public List<ITerm> Next()
            //{
            //    if (next == null)
            //    {
            //        GetNext();
            //    }
            //    List<ITerm> r = next;
            //    return r;
            //}

            void GetNext()
            {
                while (!(open.Count == 0))
                {
                    SubSetSearchState s = open.First();
                    open.RemoveAt(0);
                    if (s.d == 0)
                    {
                        next = s.GetAsList();
                        return;
                    }
                    else
                    {
                        s.AddNexts();
                    }
                }
                next = null;
            }