Beispiel #1
0
        /// <summary>
        /// Attempts to pop the next available value from the back of the buffer.
        /// </summary>
        static public bool TryPopBack <T>(this IRingBuffer <T> ioBuffer, out T outValue)
        {
            if (ioBuffer.Count <= 0)
            {
                outValue = default(T);
                return(false);
            }

            outValue = ioBuffer.PopBack();
            return(true);
        }