Beispiel #1
0
        /// <summary>
        /// Pop from head and invoke every action in the deque.
        /// </summary>
        public static void PopHeadInvokeAll(this LockedDeque <Action> actions)
        {
            Action current;

            while (actions.TryPopHead(out current))
            {
                current.Invoke();
            }
        }
Beispiel #2
0
 public Enumerator(LockedDeque <T> lockedDeque)
 {
     _enumerator = lockedDeque._deque.GetEnumerator();
     _lock       = lockedDeque._lock;
     _lock.AcquireShared();
 }