Redzen.IO.MemoryBlockStream.ReadByte C# (CSharp) Метод

ReadByte() публичный Метод

Reads a byte from the stream.
public ReadByte ( ) : int
Результат int
        public override int ReadByte()
        {
            if(!this._isOpen) throw new ObjectDisposedException("Stream is closed.");

            // Test for end of stream (or beyond end).
            if(_position >= _length) {
                return -1;
            }

            // Read byte.
            int blkIdx = _position / _blockSize;
            int blkOffset = _position++ % _blockSize;
            return _blockList[blkIdx][blkOffset];
        }