public EventPool(EventPoolMode eventPoolMode, int maxOperatorNumber = 64) { events = new Dictionary <int, EventHandler <T> >(); eventList = new SafetyQueue <LE_Event <T> >(); this.eventPoolMode = eventPoolMode; this.maxOperatorNumber = maxOperatorNumber; }
public void Init() { threads = new Thread[Number]; for (int i = 0; i < Number; i++) { threads[i] = new Thread(Add) { Name = i.ToString() }; } queue = new SafetyQueue <A0>(); }