My Project
programmer's documentation
|
#include "cs_defs.h"
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <string.h>
#include <stdarg.h>
#include <fcntl.h>
#include <unistd.h>
#include <assert.h>
#include "bft_mem.h"
#include "bft_error.h"
#include "bft_printf.h"
#include "cs_base.h"
#include "cs_parameters.h"
#include "cs_tree.h"
#include "cs_tree_xml.h"
#include "cs_gui_util.h"
Functions | |
int | cs_gui_file_is_loaded (void) |
Indicate if an XML file has been loaded. More... | |
int | cs_gui_load_file (const char *filename) |
Load the XML file in memory. More... | |
void | cs_gui_check_version (void) |
Check the XML file version. More... | |
int | cs_gui_characters_number (int num) |
int | cs_gui_strcmp (const char *s1, const char *s2) |
int | cs_gui_is_equal_real (cs_real_t v1, cs_real_t v2) |
void | cs_gui_node_get_int (cs_tree_node_t *node, int *value) |
Update an integer value based on a tree node. More... | |
void | cs_gui_node_get_real (cs_tree_node_t *node, cs_real_t *value) |
Update an real value based on a tree node. More... | |
void | cs_gui_node_get_status_int (cs_tree_node_t *tn, int *status) |
Update an integer-valued status value based on a node's status tag. More... | |
void | cs_gui_node_get_status_bool (cs_tree_node_t *node, bool *status) |
Update an bool-valued status value based on a node's status tag. More... | |
const char * | cs_gui_node_get_tag (cs_tree_node_t *node, const char *tag_name) |
Return a string value associated with a "tag" child node and whose presence should be guaranteed. More... | |
void | cs_gui_node_get_child_int (cs_tree_node_t *node, const char *child_name, int *value) |
Update an integer value based on a tree's child node. More... | |
void | cs_gui_node_get_child_real (cs_tree_node_t *node, const char *child_name, cs_real_t *value) |
Update an integer value based on a tree's child node. More... | |
void | cs_gui_node_get_child_status_int (cs_tree_node_t *tn, const char *child_name, int *status) |
Update an integer-valued status value based on a node child's status tag. More... | |
void | cs_gui_node_get_child_status_bool (cs_tree_node_t *node, const char *child_name, bool *status) |
Update a bool-valued status value based on a node child's status tag. More... | |
void | cs_gui_add_mei_time (double t) |
double | cs_gui_get_mei_times (void) |
void cs_gui_add_mei_time | ( | double | t | ) |
int cs_gui_characters_number | ( | int | num | ) |
void cs_gui_check_version | ( | void | ) |
Check the XML file version.
int cs_gui_file_is_loaded | ( | void | ) |
Indicate if an XML file has been loaded.
double cs_gui_get_mei_times | ( | void | ) |
int cs_gui_load_file | ( | const char * | filename | ) |
Load the XML file in memory.
[in] | filename | XML file containing the parameters |
void cs_gui_node_get_child_int | ( | cs_tree_node_t * | node, |
const char * | child_name, | ||
int * | value | ||
) |
Update an integer value based on a tree's child node.
If no node is present, the initial value is unchanged. If the node is present but the value missing, an error is returne.
[in] | node | node whose value is queried |
[in] | child_name | name of child node |
[in,out] | value | queried value |
void cs_gui_node_get_child_real | ( | cs_tree_node_t * | node, |
const char * | child_name, | ||
cs_real_t * | value | ||
) |
Update an integer value based on a tree's child node.
If no node is present, the initial value is unchanged. If the node is present but the value missing, an error is returne.
[in] | node | node whose value is queried |
[in] | child_name | name of child node |
[in,out] | value | queried value |
void cs_gui_node_get_child_status_bool | ( | cs_tree_node_t * | node, |
const char * | child_name, | ||
bool * | status | ||
) |
Update a bool-valued status value based on a node child's status tag.
The status is defined in a string-valued child (tag) node. If no such child and tag is present, the initial status is unchanged.
[in] | node | node whose value is queried |
[in] | child_name | name of child node |
[in,out] | value | queried value |
void cs_gui_node_get_child_status_int | ( | cs_tree_node_t * | tn, |
const char * | child_name, | ||
int * | status | ||
) |
Update an integer-valued status value based on a node child's status tag.
The status is defined in a string-valued child (tag) node. If no such child and tag is present, the initial status is unchanged.
[in] | node | node whose value is queried |
[in] | child_name | name of child node |
[in,out] | value | queried value |
void cs_gui_node_get_int | ( | cs_tree_node_t * | node, |
int * | value | ||
) |
Update an integer value based on a tree node.
If no node is present, the initial value is unchanged. If the node is present but the value missing, an error is returne.
[in] | node | node whose value is queried |
[in,out] | value | queried value |
void cs_gui_node_get_real | ( | cs_tree_node_t * | node, |
cs_real_t * | value | ||
) |
Update an real value based on a tree node.
If no node is present, the initial value is unchanged. If the node is present but the value missing, an error is returne.
[in] | node | node whose value is queried |
[in,out] | value | queried value |
void cs_gui_node_get_status_bool | ( | cs_tree_node_t * | node, |
bool * | status | ||
) |
Update an bool-valued status value based on a node's status tag.
The status is defined in a string-valued child (tag) node. If no such tag is present, the initial status is unchanged.
[in] | node | node whose status is queried |
[in,out] | status | status value (0 or 1) |
void cs_gui_node_get_status_int | ( | cs_tree_node_t * | tn, |
int * | status | ||
) |
Update an integer-valued status value based on a node's status tag.
The status is defined in a string-valued child (tag) node. If no such tag is present, the initial status is unchanged.
[in] | tn | node whose status is queried |
[in,out] | status | status value (0 or 1) |
const char* cs_gui_node_get_tag | ( | cs_tree_node_t * | node, |
const char * | tag_name | ||
) |
Return a string value associated with a "tag" child node and whose presence should be guaranteed.
If the matching child node is not present, an error is produced
[in] | node | tree node which should have a "tag" child |
[in] | tag_name | name of tag child node |
int cs_gui_strcmp | ( | const char * | s1, |
const char * | s2 | ||
) |