iDRS™ SDK 16
Loading...
Searching...
No Matches
IStreamFactory_interface.h File Reference

Interface for IStreamFactory wrapper. More...

Go to the source code of this file.

Functions

IStreamFactory IStreamFactory_Create (PtrCreateStreamFn ptrCreateStreamFn, PtrCloseStreamFn ptrCloseStreamFn, idrs_exception *pargException)
 Creates a new IStreamFactory object.
 
void IStreamFactory_Destroy (IStreamFactory argIStreamFactory, idrs_exception *pargException)
 Destroys a IStreamFactory handle.
 
IByteStream IStreamFactory_CreateStream (IStreamFactory argIStreamFactory, idrs_exception *pargException)
 CreateStream is instantiating a new stream that should be opened for write/read.
 
void IStreamFactory_CloseStream (IStreamFactory argIStreamFactory, IByteStream pStream, idrs_exception *pargException)
 CloseStream is closing an output stream.
 

Detailed Description

Interface for IStreamFactory wrapper.

Function Documentation

◆ IStreamFactory_CloseStream()

void IStreamFactory_CloseStream ( IStreamFactory  argIStreamFactory,
IByteStream  pStream,
idrs_exception *  pargException 
)

CloseStream is closing an output stream.

This method is called automatically when closing a stream created using

See also
CreateStream
Parameters
argIStreamFactoryIStreamFactory handle
pStreamStream to close
pargExceptionPointer to exception structure that will be filled if an exception occurs

◆ IStreamFactory_Create()

IStreamFactory IStreamFactory_Create ( PtrCreateStreamFn  ptrCreateStreamFn,
PtrCloseStreamFn  ptrCloseStreamFn,
idrs_exception *  pargException 
)

Creates a new IStreamFactory object.

Parameters
ptrCreateStreamFnCreateStream function pointer
ptrCloseStreamFnCloseStream function pointer
pargExceptionPointer to exception structure that will be filled if an exception occurs
Returns
The newly created IStreamFactory

◆ IStreamFactory_CreateStream()

IByteStream IStreamFactory_CreateStream ( IStreamFactory  argIStreamFactory,
idrs_exception *  pargException 
)

CreateStream is instantiating a new stream that should be opened for write/read.

The output stream can be a file stream (CFileStream), a memory stream (CMemoryStream) or a custom defined stream

The method is expected to return a pointer to the created stream. The class inheriting IStreamFactory should take the necessary precautions to keep the pointer valid until

See also
CloseStream is called
Returns
Pointer to the created IByteStream object
Parameters
argIStreamFactoryIStreamFactory handle
pargExceptionPointer to exception structure that will be filled if an exception occurs

◆ IStreamFactory_Destroy()

void IStreamFactory_Destroy ( IStreamFactory  argIStreamFactory,
idrs_exception *  pargException 
)

Destroys a IStreamFactory handle.

Parameters
argIStreamFactoryIStreamFactory handle to destroy
pargExceptionPointer to exception structure that will be filled if an exception occurs