System.IO.BufferedStream.ReadFromBuffer C# (CSharp) Méthode

ReadFromBuffer() private méthode

private ReadFromBuffer ( byte array, int offset, int count ) : int
array byte
offset int
count int
Résultat int
        private int ReadFromBuffer(byte[] array, int offset, int count)
        {
            int readbytes = _readLen - _readPos;
            Debug.Assert(readbytes >= 0);

            if (readbytes == 0)
                return 0;

            Debug.Assert(readbytes > 0);

            if (readbytes > count)
                readbytes = count;
            Buffer.BlockCopy(_buffer, _readPos, array, offset, readbytes);
            _readPos += readbytes;

            return readbytes;
        }

Same methods

BufferedStream::ReadFromBuffer ( Byte array, int offset, int count, Exception &error ) : int