Read the specified bufferLength number of bytes from the input sequence of the specified streamBuf, as if by a call to `streamBuf‐>sgetn(buffer.

Synopsis

Declared in <balber_berutil.h>

static
int
getChars(
    char* buffer,
    std::streambuf* streamBuf,
    int bufferLength);

Description

bufferLength)`, and load the bytes into successive elements of the specified buffer, starting at the first element. Return 0 on success, and a non‐zero value otherwise. The operation succeeds if length bytes are successfully read from the input sequence of the streamBuf without the read position becoming unavailable. If less than bufferLength bytes are read, the number of bytes loaded into buffer is not specified. The behavior is undefined unless 0 <= bufferLength and buffer is the address of a sequence of at least bufferLength bytes.

Return Value

0 on success, and a non‐zero value otherwise

Parameters

Name

Description

buffer

destination byte buffer

streamBuf

input stream buffer

bufferLength

number of bytes to read

Created with MrDocs