Example #1
0
 /// <summary>
 /// Creates a new heap of the given size
 /// </summary>
 /// <param name="memoryManager">The memory manager</param>
 /// <param name="managedObjectReferences">The managed object references</param>
 /// <param name="size">The size of the heap</param>
 public ManagedHeap(MemoryManager memoryManager, ManagedObjectReferences managedObjectReferences, int size)
 {
     this.managedObjectReferences = managedObjectReferences;
     this.dataPage       = memoryManager.CreatePage(size);
     this.nextAllocation = this.dataPage.Start;
 }
 /// <summary>
 /// Creates a new collector generation
 /// </summary>
 /// <param name="memoryManager">The memory manager</param>
 /// <param name="managedObjectReferences">The managed object references</param>
 /// <param name="size">The size of the heap</param>
 public CollectorGeneration(MemoryManager memoryManager, ManagedObjectReferences managedObjectReferences, int size)
 {
     this.managedObjectReferences = managedObjectReferences;
     this.Heap = new ManagedHeap(memoryManager, managedObjectReferences, size);
 }