libRASCH: load_xml_bak.c File Reference
load_xml_bak.c File Reference
Include dependency graph for load_xml_bak.c:
Go to the source code of this file.
Defines
#define _LIBRASCH_BUILD
#define _DEFINE_INFO_STRUCTS_PROP
Functions
LIBRAAPI int ra_eval_loadxml (meas_handle mh, const char *file)
load evalution in XML format
int get_eval_file_xml (meas_handle mh, char *f)
returns evaluation filename
int read_evals_xml (meas_handle mh, xmlNodePtr parent)
reads the evaluations
xmlNodePtr get_node (xmlNodePtr parent, char *name)
returns the XML node named with 'name'
int read_sets_xml (struct eval *e, xmlNodePtr parent)
read event-sets
int read_events_start_end_xml (struct event_set *set, xmlNodePtr parent)
read start- and end-time for event-sets
int read_props_xml (struct event_set *set, xmlNodePtr parent, int use_ascii)
read event-properties
int read_events_xml (struct event_property *prop, xmlNodePtr parent, int use_ascii)
read event values
int handle_value_events_ascii (struct event_property *prop, xmlNodePtr parent)
read event values stored as ASCII-text
int read_short (xmlNodePtr node, struct event_property *prop, long idx)
read short event value
int read_long (xmlNodePtr node, struct event_property *prop, long idx)
read long event value
int read_double (xmlNodePtr node, struct event_property *prop, long idx)
read double event value
int read_char (xmlNodePtr node, struct event_property *prop, long idx)
read string event value
int read_short_array (xmlNodePtr node, struct event_property *prop, long idx)
read short array event value
int read_long_array (xmlNodePtr node, struct event_property *prop, long idx)
read long array event value
int read_double_array (xmlNodePtr node, struct event_property *prop, long idx)
read double array event value
int handle_char_events (struct event_property *prop, xmlChar *c)
read string event values stored in one XML tag
char * find_next_string (char *s)
find next occurence of string seperator
int handle_value_events (struct event_property *prop, xmlChar *c)
read event values MIME64 encoded
int read_templates_xml (struct event_set *set, xmlNodePtr parent)
read templates
prop_handle find_prop (struct eval *e, const char *name)
return a specific event-property
int read_single_template_xml (struct template_struct *templ, xmlNodePtr parent)
read a single template
Define Documentation
#define _DEFINE_INFO_STRUCTS_PROP
Function Documentation
char* find_next_string
(
char *
s
)
Parameters:
<s> string which will be searched
The function returns the position of the next string seperator (0x10 + '.' + 0x10).
Definition at line 1035 of file load_xml_bak.c .
Referenced by handle_char_events() .
Parameters:
<e> pointer to an evaluation structure
<name> name of the event-property looked for
The function returns the event-property named 'name'.
Definition at line 1267 of file load_xml_bak.c .
Referenced by read_templates_xml() .
Parameters:
<mh> measurement handle
<f> will receive the filename of the evaluation
If no evaluation file was given in ra_eval_loadxml, this function returns the default filename used for evaluations (based on the measurement name).
Definition at line 103 of file load_xml_bak.c .
References ra_info_get() , RA_INFO_REC_GEN_DIR_L , RA_INFO_REC_GEN_PATH_C , ra_rec_get_first() , ra_value_free() , ra_value_get_long() , ra_value_get_string() , and ra_value_malloc() .
Referenced by eval_loadxml_v0() , ra_eval_loadxml() , and ra_eval_savexml() .
xmlNodePtr get_node
(
xmlNodePtr
parent ,
char *
name
)
int handle_char_events
(
struct event_property *
prop ,
xmlChar *
c
)
Parameters:
<prop> pointer to an event-property structure
<c> string containing the value
The function "reads" the string event values for the event-property 'prop' stored in 'c'. The single strings are seperated with 0x10 + '.' + 0x10 .
Definition at line 985 of file load_xml_bak.c .
References find_next_string() .
Referenced by read_events_xml() .
int handle_value_events
(
struct event_property *
prop ,
xmlChar *
c
)
int handle_value_events_ascii
(
struct event_property *
prop ,
xmlNodePtr
parent
)
Parameters:
<prop> pointer to an event-property structure
<parent> pointer of the parent XML node
The function reads the event values for the event-property 'prop' below the XML node 'parent'. The function expects that the values are stored as ASCII text in there own XML tag.
Definition at line 568 of file load_xml_bak.c .
References EVPROP_TYPE_CHAR , EVPROP_TYPE_DOUBLE , EVPROP_TYPE_DOUBLE_ARRAY , EVPROP_TYPE_LONG , EVPROP_TYPE_LONG_ARRAY , EVPROP_TYPE_SHORT , EVPROP_TYPE_SHORT_ARRAY , read_char() , read_double() , read_double_array() , read_long() , read_long_array() , read_short() , and read_short_array() .
Referenced by read_events_xml() .
LIBRAAPI int ra_eval_loadxml
(
meas_handle
mh ,
const char *
file
)
int read_char
(
xmlNodePtr
node ,
struct event_property *
prop ,
long
idx
)
Parameters:
<node> node containing the value as ASCII text
<prop> event-property
<idx> event number for which the value will be set
The function reads a string event value and set the value in the array for the property 'prop' at position 'idx'.
Definition at line 788 of file load_xml_bak.c .
Referenced by handle_value_events_ascii() .
int read_double
(
xmlNodePtr
node ,
struct event_property *
prop ,
long
idx
)
Parameters:
<node> node containing the value as ASCII text
<prop> event-property
<idx> event number for which the value will be set
The function reads a double event value and set the value in the array for the property 'prop' at position 'idx'.
Definition at line 760 of file load_xml_bak.c .
Referenced by handle_value_events_ascii() .
int read_double_array
(
xmlNodePtr
node ,
struct event_property *
prop ,
long
idx
)
Parameters:
<node> node containing the value as ASCII text
<prop> event-property
<idx> event number for which the value will be set
The function reads a double array event value and set the value in the array for the property 'prop' at position 'idx'.
Definition at line 930 of file load_xml_bak.c .
Referenced by handle_value_events_ascii() .
int read_evals_xml
(
meas_handle
mh ,
xmlNodePtr
parent
)
Parameters:
<mh> measurement handle
<parent> pointer of the parent XML node
The function reads all evaluations below the XML node 'parent'.
Definition at line 143 of file load_xml_bak.c .
References eval::def , EVAL_MAX_DESC , EVAL_MAX_HOST , EVAL_MAX_NAME , EVAL_MAX_PRG , EVAL_MAX_TS , EVAL_MAX_USER , get_node() , eval::handle_id , eval::original , RA_HANDLE_EVAL , ra_list_add() , and read_sets_xml() .
Referenced by eval_loadxml_v0() , and ra_eval_loadxml() .
int read_events_start_end_xml
(
struct event_set *
set ,
xmlNodePtr
parent
)
int read_events_xml
(
struct event_property *
prop ,
xmlNodePtr
parent ,
int
use_ascii
)
int read_long
(
xmlNodePtr
node ,
struct event_property *
prop ,
long
idx
)
Parameters:
<node> node containing the value as ASCII text
<prop> event-property
<idx> event number for which the value will be set
The function reads a long event value and set the value in the array for the property 'prop' at position 'idx'.
Definition at line 732 of file load_xml_bak.c .
Referenced by handle_value_events_ascii() .
int read_long_array
(
xmlNodePtr
node ,
struct event_property *
prop ,
long
idx
)
Parameters:
<node> node containing the value as ASCII text
<prop> event-property
<idx> event number for which the value will be set
The function reads a long array event value and set the value in the array for the property 'prop' at position 'idx'.
Definition at line 874 of file load_xml_bak.c .
Referenced by handle_value_events_ascii() .
int read_props_xml
(
struct event_set *
set ,
xmlNodePtr
parent ,
int
use_ascii
)
Parameters:
<set> pointer to an event-set structure
<parent> pointer of the parent XML node
<use_ascii> flag if event-values are stored as ASCII-text (=1) or as binary MIME64 encoded data (=0)
The function reads all event-properties below the XML node 'parent'.
Definition at line 417 of file load_xml_bak.c .
References _ra_set_error , EVAL_MAX_DESC , EVAL_MAX_NAME , EVAL_MAX_UNIT , EVPROP_TYPE_CHAR , EVPROP_TYPE_DOUBLE , EVPROP_TYPE_DOUBLE_ARRAY , EVPROP_TYPE_LONG , EVPROP_TYPE_LONG_ARRAY , EVPROP_TYPE_SHORT , EVPROP_TYPE_SHORT_ARRAY , get_node() , RA_ERR_EVAL_FILE_CORRUPT , ra_list_add() , and read_events_xml() .
Referenced by read_sets_xml() .
int read_sets_xml
(
struct eval *
e ,
xmlNodePtr
parent
)
int read_short
(
xmlNodePtr
node ,
struct event_property *
prop ,
long
idx
)
Parameters:
<node> node containing the value as ASCII text
<prop> event-property
<idx> event number for which the value will be set
The function reads a short event value and set the value in the array for the property 'prop' at position 'idx'.
Definition at line 704 of file load_xml_bak.c .
Referenced by handle_value_events_ascii() .
int read_short_array
(
xmlNodePtr
node ,
struct event_property *
prop ,
long
idx
)
Parameters:
<node> node containing the value as ASCII text
<prop> event-property
<idx> event number for which the value will be set
The function reads a short array event value and set the value in the array for the property 'prop' at position 'idx'.
Definition at line 817 of file load_xml_bak.c .
Referenced by handle_value_events_ascii() .
int read_single_template_xml
(
struct template_struct *
templ ,
xmlNodePtr
parent
)
Parameters:
<templ> pointer to an template structure
<parent> pointer of the parent XML node
The function reads a single template information below the XML node 'parent'.
Definition at line 1291 of file load_xml_bak.c .
References decode_base64() .
Referenced by read_templates_xml() .
int read_templates_xml
(
struct event_set *
set ,
xmlNodePtr
parent
)
Generated on Fri May 27 11:32:58 2005 for libRASCH by
1.4.2