ערוך

שתף באמצעות


PrintQueueStream.Read(Byte[], Int32, Int32) Method

Definition

Reads a sequence of bytes from the stream and advances the read/write position in the stream by the number of bytes that were read.

public:
 override int Read(cli::array <System::Byte> ^ buffer, int offset, int count);
[System.Security.SecurityCritical]
public override int Read (byte[] buffer, int offset, int count);
public override int Read (byte[] buffer, int offset, int count);
[<System.Security.SecurityCritical>]
override this.Read : byte[] * int * int -> int
override this.Read : byte[] * int * int -> int
Public Overrides Function Read (buffer As Byte(), offset As Integer, count As Integer) As Integer

Parameters

buffer
Byte[]

An array of bytes.

offset
Int32

The zero-based byte offset in the buffer where you want to begin storing the data that is read from the stream.

count
Int32

The maximum number of bytes to be read from the stream.

Returns

An Int32 that holds the total number of bytes that are read into the buffer.

Attributes

Remarks

The return value can be less than the number of requested bytes if that many bytes are not currently available; or the number can be zero (0) if the read/write position is at the end of the stream.

When this method returns, buffer contains the specified byte array and the values between offset and (offset + count - 1) are replaced by the bytes that are read from the source.

Applies to