IOS_$SET_LOCATE_BUFFER_SIZE Domain/OS IOS_$SET_LOCATE_BUFFER_SIZE
NAME
ios_$set_locate_buffer_size - set the locate buffer size
SYNOPSIS (C)
#include <apollo/base.h>
#include <apollo/ios.h>
void ios_$set_locate_buffer_size(
ios_$id_t &stream_id,
short &buffer_size,
status_$t *status )
SYNOPSIS (Pascal)
%include '/sys/ins/base.ins.pas';
%include '/sys/ins/ios.ins.pas';
procedure ios_$set_locate_buffer_size(
in stream_id: ios_$id_t;
in buffer_size: integer;
out status: status_$t );
SYNOPSIS (FORTRAN)
%include '/sys/ins/base.ins.ftn'
%include '/sys/ins/ios.ins.ftn'
integer*2 stream_id, buffer_size
integer*4 status
call ios_$locate_buffer_size( stream_id, buffer_size, status )
DESCRIPTION
Ios_$set_locate_buffer_size sets the size of the input buffer allocated
by ios_$locate for the stream open on stream_id. After a call to
ios_$locate_buffer_size, the size of the input buffer remains at
buffer_size for as long as the stream is open.
stream_id
The ID of the stream. Ios_$locat_buffer_size sets the size of the
locate buffer associated with stream_id.
buffer_size
The new size of the locate buffer in bytes.
status
The completion status.
NOTES
Normally, ios_$locate just gets a pointer to the next unread byte in a
stream. However, if the manager of the stream does not support the
internal buffering necessary for ios_$locate to work this way, then
ios_$locate must create a buffer and call ios_$get to move data from the
stream to the buffer. After the ios_$get completes, ios_$locate returns
a pointer to the buffer it created.
By default, ios_$locate allocates 1024 bytes for the buffer. If a call
to ios_$locate asks for more than 1024 bytes and ios_$locate is forced to
buffer the input, then it will only be able to read 1024 bytes and will
return the ios_$buffer_too_small error. To change the default, call
ios_$locate_buffer_size with a sufficiently large buffer_size argument
before making the ios_$locate call.