libopc
Typedefs | Functions
inputstream.h File Reference
#include <opc/config.h>

Go to the source code of this file.

Typedefs

typedef struct OPC_CONTAINER_INPUTSTREAM_STRUCT opcContainerInputStream
 

Functions

opcContainerInputStreamopcContainerOpenInputStream (opcContainer *container, const xmlChar *name)
 
opc_uint32_t opcContainerReadInputStream (opcContainerInputStream *stream, opc_uint8_t *buffer, opc_uint32_t buffer_len)
 
opc_error_t opcContainerCloseInputStream (opcContainerInputStream *stream)
 
opcCompressionOption_t opcContainerGetInputStreamCompressionOption (opcContainerInputStream *stream)
 

Typedef Documentation

Internal type which represents a binary input stream.

Function Documentation

opc_error_t opcContainerCloseInputStream ( opcContainerInputStream stream)

Closes the input stream and releases all system resources.

Examples:
opc_extract.c, opc_generate.c, opc_image.c, and opc_part.c.
opcCompressionOption_t opcContainerGetInputStreamCompressionOption ( opcContainerInputStream stream)

Returns the type of compression used for the stream.

opcContainerInputStream* opcContainerOpenInputStream ( opcContainer container,
const xmlChar *  name 
)

Opens the part name of the container for reading.

Examples:
opc_extract.c, opc_generate.c, opc_image.c, and opc_part.c.
opc_uint32_t opcContainerReadInputStream ( opcContainerInputStream stream,
opc_uint8_t buffer,
opc_uint32_t  buffer_len 
)

Reads maximal buffer_len bytes from the input stream to buffer.

Returns
The number of byes read or "0" in case of an error or end-of-stream.
Examples:
opc_extract.c, opc_generate.c, opc_image.c, and opc_part.c.