Coin Logo http://www.sim.no/
http://www.coin3d.org/

element.h
1 #ifndef COIN_XML_ELEMENT_H
2 #define COIN_XML_ELEMENT_H
3 
4 /**************************************************************************\
5  *
6  * This file is part of the Coin 3D visualization library.
7  * Copyright (C) by Kongsberg Oil & Gas Technologies.
8  *
9  * This library is free software; you can redistribute it and/or
10  * modify it under the terms of the GNU General Public License
11  * ("GPL") version 2 as published by the Free Software Foundation.
12  * See the file LICENSE.GPL at the root directory of this source
13  * distribution for additional information about the GNU GPL.
14  *
15  * For using Coin with software that can not be combined with the GNU
16  * GPL, and for taking advantage of the additional benefits of our
17  * support services, please contact Kongsberg Oil & Gas Technologies
18  * about acquiring a Coin Professional Edition License.
19  *
20  * See http://www.coin3d.org/ for more information.
21  *
22  * Kongsberg Oil & Gas Technologies, Bygdoy Alle 5, 0257 Oslo, NORWAY.
23  * http://www.sim.no/ sales@sim.no coin-support@coin3d.org
24  *
25 \**************************************************************************/
26 
27 #include <stdio.h>
28 
29 #include <Inventor/C/XML/types.h>
30 
31 #ifdef __cplusplus
32 extern "C" {
33 #endif /* __clusplus */
34 
35 /* ********************************************************************** */
36 
37 COIN_DLL_API cc_xml_elt * cc_xml_elt_new(void);
38 COIN_DLL_API cc_xml_elt * cc_xml_elt_new_from_data(const char * type, cc_xml_attr ** attrs);
39 COIN_DLL_API cc_xml_elt * cc_xml_elt_clone(const cc_xml_elt * elt);
40 COIN_DLL_API void cc_xml_elt_delete_x(cc_xml_elt * elt);
41 
42 COIN_DLL_API void cc_xml_elt_set_type_x(cc_xml_elt * elt, const char * type);
43 COIN_DLL_API const char * cc_xml_elt_get_type(const cc_xml_elt * elt);
44 
45 COIN_DLL_API void cc_xml_elt_set_cdata_x(cc_xml_elt * elt, const char * data);
46 COIN_DLL_API const char * cc_xml_elt_get_cdata(const cc_xml_elt * elt);
47 COIN_DLL_API const char * cc_xml_elt_get_data(const cc_xml_elt * elt);
48 
49 COIN_DLL_API void cc_xml_elt_remove_all_attributes_x(cc_xml_elt * elt);
50 COIN_DLL_API void cc_xml_elt_set_attribute_x(cc_xml_elt * elt, cc_xml_attr * attr);
51 COIN_DLL_API void cc_xml_elt_set_attributes_x(cc_xml_elt * elt, cc_xml_attr ** attrs);
52 
53 COIN_DLL_API cc_xml_attr * cc_xml_elt_get_attribute(const cc_xml_elt * elt, const char * attrname);
54 COIN_DLL_API int cc_xml_elt_get_num_attributes(const cc_xml_elt * elt);
55 COIN_DLL_API const cc_xml_attr ** cc_xml_elt_get_attributes(const cc_xml_elt * elt);
56 
57 COIN_DLL_API int cc_xml_elt_get_num_children(const cc_xml_elt * elt);
58 COIN_DLL_API int cc_xml_elt_get_num_children_of_type(const cc_xml_elt * elt, const char * type);
59 COIN_DLL_API cc_xml_elt * cc_xml_elt_get_child(const cc_xml_elt * elt, int child);
60 COIN_DLL_API int cc_xml_elt_get_child_index(const cc_xml_elt * elt, const cc_xml_elt * child);
61 COIN_DLL_API int cc_xml_elt_get_child_type_index(const cc_xml_elt * elt, const cc_xml_elt * child);
62 COIN_DLL_API cc_xml_elt * cc_xml_elt_get_parent(const cc_xml_elt * elt);
63 COIN_DLL_API cc_xml_path * cc_xml_elt_get_path(const cc_xml_elt * elt);
64 
65 COIN_DLL_API cc_xml_elt * cc_xml_elt_get_child_of_type(const cc_xml_elt * elt, const char * type, int idx);
66 COIN_DLL_API cc_xml_elt * cc_xml_elt_get_child_of_type_x(cc_xml_elt * elt, const char * type, int idx);
67 
68 COIN_DLL_API void cc_xml_elt_set_parent_x(cc_xml_elt * elt, cc_xml_elt * parent);
69 COIN_DLL_API void cc_xml_elt_add_child_x(cc_xml_elt * elt, cc_xml_elt * child);
70 COIN_DLL_API void cc_xml_elt_remove_child_x(cc_xml_elt * elt, cc_xml_elt * child);
71 COIN_DLL_API void cc_xml_elt_insert_child_x(cc_xml_elt * elt, cc_xml_elt * child, int idx);
72 COIN_DLL_API int cc_xml_elt_replace_child_x(cc_xml_elt * elt, cc_xml_elt * oldchild, cc_xml_elt * newchild);
73 
74 COIN_DLL_API int cc_xml_elt_get_boolean(const cc_xml_elt * elt, int * value);
75 COIN_DLL_API int cc_xml_elt_get_integer(const cc_xml_elt * elt, int * value);
76 COIN_DLL_API int cc_xml_elt_get_uint64(const cc_xml_elt * elt, uint64_t * value);
77 COIN_DLL_API int cc_xml_elt_get_int64(const cc_xml_elt * elt, int64_t * value);
78 COIN_DLL_API int cc_xml_elt_get_uint32(const cc_xml_elt * elt, uint32_t * value);
79 COIN_DLL_API int cc_xml_elt_get_int32(const cc_xml_elt * elt, int32_t * value);
80 COIN_DLL_API int cc_xml_elt_get_float(const cc_xml_elt * elt, float * value);
81 COIN_DLL_API int cc_xml_elt_get_double(const cc_xml_elt * elt, double * value);
82 
83 COIN_DLL_API void cc_xml_elt_set_boolean_x(cc_xml_elt * elt, int value);
84 COIN_DLL_API void cc_xml_elt_set_integer_x(cc_xml_elt * elt, int value);
85 COIN_DLL_API void cc_xml_elt_set_uint64_x(cc_xml_elt * elt, uint64_t value);
86 COIN_DLL_API void cc_xml_elt_set_int64_x(cc_xml_elt * elt, int64_t value);
87 COIN_DLL_API void cc_xml_elt_set_uint32_x(cc_xml_elt * elt, uint32_t value);
88 COIN_DLL_API void cc_xml_elt_set_int32_x(cc_xml_elt * elt, int32_t value);
89 COIN_DLL_API void cc_xml_elt_set_float_x(cc_xml_elt * elt, float value);
90 COIN_DLL_API void cc_xml_elt_set_double_x(cc_xml_elt * elt, double value);
91 
92 COIN_DLL_API void cc_xml_elt_strip_whitespace_x(cc_xml_elt * elt);
93 
94 COIN_DLL_API cc_xml_elt * cc_xml_elt_get_traversal_next(const cc_xml_elt * root, cc_xml_elt * here);
95 
96 COIN_DLL_API const cc_xml_elt * cc_xml_elt_find(const cc_xml_elt * root, const cc_xml_path * path);
97 COIN_DLL_API const cc_xml_elt * cc_xml_elt_find_next(const cc_xml_elt * root, cc_xml_elt * from, cc_xml_path * path);
98 COIN_DLL_API cc_xml_elt * cc_xml_elt_create_x(cc_xml_elt * from, cc_xml_path * path);
99 
100 /* ********************************************************************** */
101 
102 #ifdef __cplusplus
103 } /* extern "C" */
104 #endif /* __clusplus */
105 
106 #endif /* !COIN_XML_ELEMENT_H */

Copyright © 1998-2010 by Kongsberg Oil & Gas Technologies. All rights reserved.

Generated on Fri Sep 9 2016 for Coin by Doxygen 1.8.5.