GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> LATC / V9-1-3 > latc_host / rhel4-32


Interface   Data Structures   File List   Data Fields   Globals  

parser_tag.c File Reference

Function to modify the address structure. More...

#include <LATC/LATC_msgs.h>
#include <parser_state_p.h>
#include <parser_tag_p.h>
#include <AG_addr_s.h>
#include <XLX/XLX.h>
#include <MSG/MSG_pubdefs.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>

Functions

unsigned int isspt (const char *string)
 Test a string to see if it is a valid layer address.
unsigned int stoi (const char *string)
 Convert a layer address string into an unsigned integer.
unsigned int isbcast (const char *string)
 Test a string to see if it is the BCAST keyword.
void setAddr (XLX_state *xState, const char **attribute)
 Set one component of the address structure according to the ID of this tage.


Detailed Description

Function to modify the address structure.

Author:
James Swain -- jswain@slac.stanford.edu

Function Documentation

unsigned int isbcast ( const char *  string  ) 

Test a string to see if it is the BCAST keyword.

Parameters:
string Layer address string to convert
Return values:
1 if the string is the BCAST keyword
0 if the string is not the BCAST keyword

Referenced by setAddr().

unsigned int isspt ( const char *  string  ) 

Test a string to see if it is a valid layer address.

Parameters:
string Layer address string to convert
Return values:
1 if the string is a valid layer address string
0 if the string is not a valid layer address string Checks that the string starts with zero or more whitespace characters followed by '+' or '-', followed by 'x' or 'y' followed by one of '0' to '8'. Ignores any trailing stuff.

Referenced by setAddr().

void setAddr ( XLX_state *  xState,
const char **  attribute 
)

Set one component of the address structure according to the ID of this tage.

Parameters:
xState XLX state of the parser
attribute list of attribute/value pairs

References LATC_state::addr, LATC_addr::cpt, isbcast(), isspt(), stoi(), LATC_tag::type, and LATC_state::xState.

unsigned int stoi ( const char *  string  ) 

Convert a layer address string into an unsigned integer.

Parameters:
string Layer address string to convert
Returns:
integer value of the string

Referenced by setAddr().


Generated on Sat Apr 9 19:53:21 2011 by  doxygen 1.5.8