Skip to content

ArcBufferReader.Peek(Span<byte>)

Peek(Span<byte>)

View source
public ReadOnlySpan<byte> Peek(scoped in Span<byte> destination)
Attempts to read the provided number of bytes from the buffer.

Parameters

destinationSpan<byte>
The destination, which may be used to hold the requested data if the data needs to be copied.

Returns

A span of either zero length, if the data is unavailable, or the requested length if the data is available.