/// <summary> /// Gets a value that indicates whether the concurrent stack is empty. /// </summary> #pragma warning disable CA1707 // Identifiers should not contain underscores #pragma warning disable SA1300 // Element should begin with upper-case letter #pragma warning disable IDE1006 // Naming Styles public static bool get_IsEmpty(SystemConcurrent.ConcurrentStack <T> concurrentStack) #pragma warning restore IDE1006 // Naming Styles #pragma warning restore SA1300 // Element should begin with upper-case letter #pragma warning restore CA1707 // Identifiers should not contain underscores { Helper.Interleave(); return(concurrentStack.IsEmpty); }
/// <summary> /// Inserts multiple objects at the top of the concurrent stack atomically. /// </summary> public static void PushRange(SystemConcurrent.ConcurrentStack <T> concurrentStack, T[] items, int startIndex, int count) { Helper.Interleave(); concurrentStack.PushRange(items, startIndex, count); }
/// <summary> /// Inserts multiple objects at the top of the concurrent stack atomically. /// </summary> public static void PushRange(SystemConcurrent.ConcurrentStack <T> concurrentStack, T[] items) { Helper.Interleave(); concurrentStack.PushRange(items); }
/// <summary> /// Inserts an object at the top of the concurrent stack. /// </summary> public static void Push(SystemConcurrent.ConcurrentStack <T> concurrentStack, T item) { Helper.Interleave(); concurrentStack.Push(item); }
/// <summary> /// Returns an enumerator that iterates through the concurrent stack. /// </summary> public static SystemGenerics.IEnumerator <T> GetEnumerator(SystemConcurrent.ConcurrentStack <T> concurrentStack) { Helper.Interleave(); return(concurrentStack.GetEnumerator()); }
/// <summary> /// Copies the concurrent stack elements to an existing one-dimensional array, /// starting at the specified array index. /// </summary> public static void CopyTo(SystemConcurrent.ConcurrentStack <T> concurrentStack, T[] array, int index) { Helper.Interleave(); concurrentStack.CopyTo(array, index); }
/// <summary> /// Removes all objects from the concurrent stack. /// </summary> public static void Clear(SystemConcurrent.ConcurrentStack <T> concurrentStack) { Helper.Interleave(); concurrentStack.Clear(); }
/// <summary> /// Attempts to pop and return multiple objects from the top of the concurrent stack atomically. /// </summary> public static int TryPopRange(SystemConcurrent.ConcurrentStack <T> concurrentStack, T[] items) { Helper.Interleave(); return(concurrentStack.TryPopRange(items)); }
/// <summary> /// Attempts to pop and return multiple objects from the top of the concurrent stack atomically. /// </summary> public static int TryPopRange(SystemConcurrent.ConcurrentStack <T> concurrentStack, T[] items, int startIndex, int count) { Helper.Interleave(); return(concurrentStack.TryPopRange(items, startIndex, count)); }
/// <summary> /// Attempt to pop and return the object at the top of the concurrent stack. /// </summary> public static bool TryPop(SystemConcurrent.ConcurrentStack <T> concurrentStack, out T result) { Helper.Interleave(); return(concurrentStack.TryPop(out result)); }
/// <summary> /// Copies the elements stored in the concurrent stack to a new array. /// </summary> public static T[] ToArray(SystemConcurrent.ConcurrentStack <T> concurrentStack) { Helper.Interleave(); return(concurrentStack.ToArray()); }