BEPUutilities2.ResourceManagement.Allocator.Allocator C# (CSharp) Метод

Allocator() публичный Метод

Creates a new memory pool.
public Allocator ( long memoryPoolSize, BufferPool idBufferPool = null, BufferPool allocationBufferPool = null, BufferPool tableBufferPool = null ) : System
memoryPoolSize long Size of the pool in elements.
idBufferPool BufferPool Buffer pool to use in the allocator. If null, the allocator picks.
allocationBufferPool BufferPool Buffer pool to use in the allocator. If null, the allocator picks.
tableBufferPool BufferPool Buffer pool to use in the allocator. If null, the allocator picks.
Результат System
        public Allocator(long memoryPoolSize,
            BufferPool<ulong> idBufferPool = null, BufferPool<Allocation> allocationBufferPool = null, BufferPool<int> tableBufferPool = null)
        {
            this.memoryPoolSize = memoryPoolSize;
            if (idBufferPool == null)
                idBufferPool = BufferPools<ulong>.Locking;
            if (allocationBufferPool == null)
                allocationBufferPool = BufferPools<Allocation>.Locking;
            if (tableBufferPool == null)
                tableBufferPool = BufferPools<int>.Locking;
            allocations = new QuickDictionary<ulong, Allocation>(idBufferPool, allocationBufferPool, tableBufferPool);
        }