GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> LATC / dev > latc_host / rhel4-32
#include <LATC/LATC_msgs.h>
#include <LATC/XML.h>
#include <consume.h>
#include <create.h>
#include <imm.h>
#include <data.h>
#include <parser_state_p.h>
#include <msg_init_p.h>
#include <AG_addr_s.h>
#include <AG_xml_tags_s.h>
#include <AG_map_tags_s.h>
#include <MSG/MSG_pubdefs.h>
#include <XLX/XLX.h>
#include <LEM/msg_macros.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
Defines | |
#define | INITIAL_STACK_LIMIT 8 |
Size of the stack within the state structure on initialisation. | |
Functions | |
unsigned | LATC_parse (const char **filelist, unsigned filecount, const char *stub, unsigned filter, unsigned verb) |
Parse a set of XML files and spit out the binary configuration files. | |
unsigned | LATC_parseMap (const char **filelist, unsigned filecount, const char *outname, unsigned verb) |
Variables | |
static XLX_parent_tag | lat |
Tag structure for the LAT element. | |
static XLX_basic_tag * | docChild [] |
Array of pointers to named structures that are children on the DOC (pseudo) element. | |
static XLX_parent_tag | doc |
Tag structure for the (pseudo) element DOC. | |
static XLX_parent_tag | mapTag |
Tag structure for the mapTag element. | |
static XLX_basic_tag * | mapDocChild [] |
Array of pointers to named structures that are children on the mapDoc (pseudo) element. | |
static XLX_parent_tag | mapDoc |
Tag structure for the (pseudo) element mapDoc. |
unsigned LATC_parse | ( | const char ** | filelist, | |
unsigned | filecount, | |||
const char * | stub, | |||
unsigned | filter, | |||
unsigned | verb | |||
) |
Parse a set of XML files and spit out the binary configuration files.
filelist | List of strings containing the names of XML files to parse | |
filecount | Number of XML files to parse | |
stub | Filename stub to use a basis for output filenames | |
filter | Bit mask of the components to create output files for | |
verb | 1 for verbose, 0 for quiet |
LATC_SUCCESS | If all goes well | |
LATC_BADALLOC | If there is an error allocating memory for the IMM structure | |
LATC_BADFOPEN | if the configuration master file or any of the configuration binary files cannot be opened. | |
LATC_BADWRITE | If one of the file write operations failed | |
LATC_BADCLOSE | If one of the files failed to close | |
XLX_FOPEN | If one of the XML files cannot be opened | |
XLX_MEMERR | If there is an error creating a parser control structure | |
XLX_FREAD | If there is an error reading an XML file | |
XLX_PARSE | If there is an error parsing the XML |
References LATC_state::addr, doc, LATC_state::excptn, INITIAL_STACK_LIMIT, LATC_state::latc, LATC_createCfg(), readField(), and LATC_state::xState.
unsigned LATC_parseMap | ( | const char ** | filelist, | |
unsigned | filecount, | |||
const char * | outname, | |||
unsigned | verb | |||
) |
filelist | List of strings containing the names of XML files to parse | |
filecount | Number of XML files to parse | |
outname | Output filename | |
verb | 1 for verbose, 0 for quiet |
LATC_SUCCESS | If all goes well | |
LATC_BADALLOC | If there is an error allocating memory for the map structure | |
LATC_BADFOPEN | if the output file cannot be opened | |
LATC_BADWRITE | If the file write operation failed | |
LATC_BADCLOSE | If the output file failed to close | |
XLX_FOPEN | If one of the XML files cannot be opened | |
XLX_MEMERR | If there is an error creating a parser control structure | |
XLX_FREAD | If there is an error reading an XML file | |
XLX_PARSE | If there is an error parsing the XML |
References LATC_state::addr, LATC_state::excptn, INITIAL_STACK_LIMIT, LATC_state::latc, LATC_createMap(), mapChar(), mapDoc, and LATC_state::xState.
XLX_parent_tag doc [static] |
Initial value:
{ {"", XLX_PARENT, XLX_character_noop}, XLX_NON_RECURSIVE, docChild, NULL, NULL }
Referenced by LATC_parse().
XLX_basic_tag* docChild[] [static] |
Initial value:
{ (XLX_basic_tag*)(&lat), NULL }
XLX_parent_tag lat [static] |
Initial value:
{
{"LATC_XML", XLX_PARENT, XLX_character_noop},
XLX_NON_RECURSIVE,
latChild,
NULL,
NULL
}
XLX_parent_tag mapDoc [static] |
Initial value:
{ {"", XLX_PARENT, XLX_character_noop}, XLX_NON_RECURSIVE, mapDocChild, NULL, NULL }
Referenced by LATC_parseMap().
XLX_basic_tag* mapDocChild[] [static] |
Initial value:
{ (XLX_basic_tag*)(&mapTag), NULL }
XLX_parent_tag mapTag [static] |
Initial value:
{
{"LATC_MAP_XML", XLX_PARENT, XLX_character_noop},
XLX_NON_RECURSIVE,
mapChild,
NULL,
NULL
}