GLAST/LAT > DAQ and FSW > FSW > Doxygen Index > RIM / V2-0-1

Constituent: rim     Tag: rad750


Interface   Data Structures   File List   Data Fields   Globals  

RIM_export.c File Reference

Functions that export data from RIM structures. More...

#include "RIM_p.h"
#include "RIM_descriptions.ic"
#include "RIM_number.ic"
#include "RIM_AG_init_p.h"
#include "RIM/RIM_msgs.h"
#include "MSG/MSG_pubdefs.h"
#include "PBS/BSWP.h"

Include dependency graph for RIM_export.c:


Functions

static unsigned exportData (RIM_expDataCB dataRtn, void *parm, void *data, int leng)
 Export a block of data.
unsigned RIM_export (RIM *rim, unsigned typMask, RIM_expRecdCB recdRtn, RIM_expDataCB dataRtn, void *parm)
 Export RIM data as a series of records.
unsigned RIM_exportMap (RIM_map *map, RIM_expRecdCB recdRtn, RIM_expDataCB dataRtn, void *parm)
 Export RIM map data as a series of records.
void RIM_dataMasks (RIM *rim, unsigned *dfTypes, unsigned *exTypes)
 Get summary of data types present in a RIM.

Detailed Description

Functions that export data from RIM structures.

Author:
Owen Saxton
Id
RIM_export.c,v 1.1 2007/11/09 23:10:48 saxton Exp

Function Documentation

unsigned exportData RIM_expDataCB  dataRtn,
void *  parm,
void *  data,
int  leng
[static]
 

Export a block of data.

This routine swaps the bytes of the data being exported, if necessary, to put the data into big-endian order, calls the exporting routine, then swaps the bytes back. A four-byte swap is all that is needed in all cases since the representation in memory on little-endian machines assumes this.

Parameters:
dataRtn Routine to do the actual exporting.
parm Parameter for the exporting routine.
data Address of the data to be exported.
leng Number of bytes to export.
Returns:
The return value from the exporting routine

void RIM_dataMasks RIM rim,
unsigned *  dfTypes,
unsigned *  exTypes
 

Get summary of data types present in a RIM.

This routine returns two bitmasks indicating what kinds of data are present in the specified RIM structure. The first indicates the types with default data present, while the second indicates which types have exception data. The principle use of this routine is to avoid creating empty sets of exported data.

Parameters:
rim Pointer to the in-memory model data
dfTypes The address of an integer to receive the bitmask of types with default data present.
exTypes The address of an integer to receive the bitmask of types with exception data present.

unsigned RIM_export RIM rim,
unsigned  typMask,
RIM_expRecdCB  recdRtn,
RIM_expDataCB  dataRtn,
void *  parm
 

Export RIM data as a series of records.

This routine provides a general way to export the data from a RIM structure. The data are presented as a series of records to the supplied callback routines. One routine is called at the start of each record to receive the record type and length of the data in the record. The second routine is called to receive data for the record, and is called as many times as necessary to receive all the data.

Parameters:
rim RIM structure to use as a source
typMask Mask of component types to write out. If the default (DFT) bit is set, the default data for all types is exported in addition to the data indicated by the other type bits.
recdRtn Routine to be called at the start of each record to be exported.
dataRtn Routine to be called for each block of data to be exported.
parm Parameter to pass to the callback routines.
Return values:
RIM_SUCCESS if all goes well

unsigned RIM_exportMap RIM_map map,
RIM_expRecdCB  recdRtn,
RIM_expDataCB  dataRtn,
void *  parm
 

Export RIM map data as a series of records.

This routine provides a general way to export the data from a RIM map structure. The data are presented as a series of records to the supplied callback routines. One routine is called at the start of each record to receive the record type and length of the data in the record. The second routine is called to receive data for the record, and is called as many times as necessary to receive all the data.

Parameters:
map RIM map structure to use as a source
recdRtn Routine to be called at the start of each record to be exported.
dataRtn Routine to be called for each block of data to be exported.
parm Parameter to pass to the callback routines.
Return values:
RIM_SUCCESS if all goes well


Generated on Wed Nov 21 01:38:12 2007 by  doxygen 1.4.4