private MemoryBin NewBin(int initialSize, IGrowthStrategy strategy) { MemoryStorage storage = new MemoryStorage(strategy); MemoryBin bin = (MemoryBin)storage.Open(new BinConfiguration(Uri, false, initialSize , false)); return bin; }
private MemoryBin NewBin(int initialSize, IGrowthStrategy strategy) { var storage = new MemoryStorage(strategy); var bin = (MemoryBin)storage.Open(new BinConfiguration(Uri, false, initialSize , false)); return(bin); }
/// <summary> /// Constructor if ArrayList taking the default size and /// the growth strategy to use /// </summary> /// <param name="size">The size to start the array</param> /// <param name="growth">The growth strategy to use</param> public ArrayList(int size, IGrowthStrategy growth) { if (size < 0) { throw new ArgumentOutOfRangeException("size", "The size of the array must be 0 or greater"); } _data = new T[size]; _growth = growth; Count = 0; }
public MemoryBin(byte[] bytes, IGrowthStrategy growthStrategy) { _bytes = bytes; _length = bytes.Length; _growthStrategy = growthStrategy; }
public MemoryBin(int initialSize, IGrowthStrategy growthStrategy) : this(new byte [initialSize], growthStrategy) { }
public MemoryStorage(IGrowthStrategy growthStrategy) { _growthStrategy = growthStrategy; }