GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> QLSM / V2-0-1 > qlsm / rhel5-32
Classes | |
struct | _QLSM_istreamDsc |
Descriptor for the read object. More... | |
Typedefs | |
typedef struct _QLSM_istream | QLSM_istream |
Typedef for struct _QLSM_istream. | |
typedef struct _CCSDS_istream | CCSDS_istream |
typedef struct _QLSM_istreamDsc | QLSM_istreamDsc |
Typedef for struct _QLSM_istreamDsc. | |
Functions | |
int | QLSM_istreamSizeof (void) |
Returns the size, in bytes, of QLSM_istream handle. | |
QLSM_istream * | QLSM_istreamNew (void) |
Allocates a QLSM_istream handle. | |
int | QLSM_istreamConstruct (QLSM_istream *istream, CCSDS_istream *ccsds) |
Opens a QLSM file or data for reading. | |
int | QLSM_istreamRead (QLSM_istream *istream, QLSM_istreamDsc *dsc, unsigned int filter) |
Reads the next object in the QLSM stream. | |
int | QLSM_istreamClose (QLSM_istream *istream) |
Closes the stream. | |
int | QLSM_istreamDelete (QLSM_istream *istream) |
Deletes the QLSM_istream. | |
int | QLSM_istreamFileOpen (QLSM_istream *istream, const char *filename, unsigned int options, unsigned char *buf, unsigned int buf_size) |
Convenience routine to construct a QLSM_istreamFileOpen to read from the specified name file filename. |
CVS $Id: QLSM_istream.h,v 1.1 2008/09/20 00:39:15 russell Exp $
int QLSM_istreamClose | ( | QLSM_istream * | stream | ) |
Closes the stream.
This function only closes the file.To free the memory associated with the contents of the file, the user must call QLSM_istreamFree().
int QLSM_istreamConstruct | ( | QLSM_istream * | istream, | |
CCSDS_istream * | ccsds | |||
) |
Opens a QLSM file or data for reading.
0,success | ||
!= | 0, failure |
istream | The stream handle to construct | |
ccsds | A previously construct CCSDS_istream |
References _QLSM_istream::apidDsc, _QLSM_istream::buffer, _QLSM_istream::ccsds, _QLSM_istream::cur, _QLSM_istream::dgm_left32, and _QLSM_istream::pkt_left.
Referenced by QLSM_istreamFileOpen().
int QLSM_istreamDelete | ( | QLSM_istream * | istream | ) |
Deletes the QLSM_istream.
istream | The event builder stream handle |
References mem_free().
int QLSM_istreamFileOpen | ( | QLSM_istream * | istream, | |
const char * | filename, | |||
unsigned int | options, | |||
unsigned char * | buf, | |||
unsigned int | buf_size | |||
) |
Convenience routine to construct a QLSM_istreamFileOpen to read from the specified name file filename.
0,If | successful | |
-1,If | could not allocate a new stream (i.e. out of memory) | |
-2,If | the file does not exist |
istream | The target CCSDS_istream | |
filename | The name of the file to open | |
options | Bit list of options, currently unused, specify as 0 | |
buf | Optional parameter specifying the FILE's input read buffer | |
buf_size | Optional parameter specifying the size of buf |
References _QLSM_istream::ccsds, and QLSM_istreamConstruct().
int QLSM_istreamRead | ( | QLSM_istream * | istream, | |
QLSM_istreamDsc * | dsc, | |||
unsigned int | filter | |||
) |
Reads the next object in the QLSM stream.
0,if | successful | |
-1,if | not |
istream | A previously opened event builder stream handle | |
dsc | If successful, filled in with a description of the read object. This includes its
| |
filter | A bit mask of the object(s) the user wishes to have returned. |
References _QLSM_istream::apidDsc, _QLSM_istream::cur, _QLSM_istreamDsc::dat, _QLSM_istream::dgm_left32, get_datagram(), _QLSM_istreamDsc::len32, _QLSM_istream::pkt_left, _QLSM_istreamDsc::type, and _QLSM_istreamDsc::version.
int QLSM_istreamSizeof | ( | void | ) |
Returns the size, in bytes, of QLSM_istream handle.