Exemplo n.º 1
0
        public void Append(int lastPtr, Heap rhs)
        {
            TotalSize += rhs.TotalSize;

            rhs.ReallocPointers(lastPtr);

            Heaplist.InsertRange(lastPtr, rhs.Heaplist);
        }
Exemplo n.º 2
0
        private int AddHeapElement(HeapElement hpe)
        {
            int index = FindFree();

            if (ProtoCore.DSASM.Constants.kInvalidIndex == index)
            {
                Heaplist.Add(hpe);
                index = Heaplist.Count - 1;
            }
            else
            {
                Heaplist[index].Active = true;
                Heaplist[index]        = hpe;
            }
            return(index);
        }
Exemplo n.º 3
0
 public void Free()
 {
     TotalSize = 0;
     Heaplist.Clear();
     freeList = new List <int>();
 }