public static void Push(StoreProcessor item) { //lock (_pool) //{ item.Update(true); _pool.Push(item); //} }
//public static void Push(Entity.CurrencyInfo value) //{ // Init(); // var index = Convert.ToInt32(Interlocked.Increment(ref _index) % capacity); // var store = _pool[index]; // store.Add(value); //} static void Init() { for (int i = 0; i < capacity; i++) { var item = new StoreProcessor(i); _pool.Push(item); } }