Esempio n. 1
0
        /// <summary>
        /// Attempts to peek the next available value from the back of the buffer.
        /// </summary>
        static public bool TryPeekBack <T>(this IRingBuffer <T> inBuffer, out T outValue)
        {
            if (inBuffer.Count <= 0)
            {
                outValue = default(T);
                return(false);
            }

            outValue = inBuffer.PeekBack();
            return(true);
        }