GetDataContainer() 공개 메소드

Finds and virtually allocates a GATManagedData instance before returning it as a GATData reference. First, the algorithm looks at the free chunks bin of appropriate size. If the bin doesn't hold any chunk, it will check if there is enough unfragmented space. If there isn't, it will look at bins holding larger chunks and fragment one if found. Finally, it will attempt defragmenting and run again, before logging an out of memory error.
public GetDataContainer ( int size ) : GATData
size int /// Size of the chunk to virtually allocate. ///
리턴 GATData
예제 #1
0
파일: GATManager.cs 프로젝트: r618/G-Audio
 /// <summary>
 /// Convenience method to request a chunk of virtual memory from the default
 /// GATDataAllocator instance.
 /// </summary>
 public static GATData GetDataContainer(int length)
 {
     return(__allocator.GetDataContainer(length));
 }