Esempio n. 1
0
        public void addtoEnd(Process data1)
        {
            node temp = new node(data1);

            if (tail != null)
            {
                tail.setNext(temp);
                temp.setPrevious(tail);
            }
            tail = temp;
            if (chain == null)
            {
                chain = tail;
            }
        }
Esempio n. 2
0
        public void add(Process data1)
        {
            node temp = new node(data1);

            temp.setNext(chain);
            if (chain != null)
            {
                chain.setPrevious(temp);
            }
            chain = temp;
            if (tail == null)
            {
                tail = chain;
            }
        }