00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #ifndef WODEN_PROPERTY_ELEMENT_H
00019 #define WODEN_PROPERTY_ELEMENT_H
00020
00037 #include <axis2_allocator.h>
00038 #include <axis2_env.h>
00039 #include <axis2_error.h>
00040 #include <axis2_string.h>
00041 #include <axis2_utils.h>
00042 #include <axis2_hash.h>
00043 #include <axis2_qname.h>
00044 #include <axis2_generic_obj.h>
00045 #include <axis2_uri.h>
00046 #include <woden.h>
00047 #include <woden_documentable_element.h>
00048 #include <woden_nested_element.h>
00049 #include <woden.h>
00050
00051 #ifdef __cplusplus
00052 extern "C"
00053 {
00054 #endif
00055
00056 typedef struct woden_property_element woden_property_element_t;
00057 typedef struct woden_property_element_ops woden_property_element_ops_t;
00058 typedef union woden_property_element_base woden_property_element_base_t;
00059 struct xml_schema_type;
00060
00066 struct woden_property_element_ops
00067 {
00072 axis2_status_t (AXIS2_CALL *
00073 free) (
00074 void *doc_el,
00075 const axis2_env_t *env);
00076
00077 woden_obj_types_t (AXIS2_CALL *
00078 type) (
00079 void *doc_el,
00080 const axis2_env_t *env);
00081
00082 axis2_status_t (AXIS2_CALL *
00083 set_ref) (void *doc_el,
00084 const axis2_env_t *env,
00085 axis2_uri_t *uri);
00086
00087 axis2_uri_t *(AXIS2_CALL *
00088 get_ref) (void *doc_el,
00089 const axis2_env_t *env);
00090
00091 axis2_status_t (AXIS2_CALL *
00092 set_value) (void *doc_el,
00093 const axis2_env_t *env,
00094 axis2_generic_obj_t *value);
00095
00096 axis2_generic_obj_t *(AXIS2_CALL *
00097 get_value) (void *doc_el,
00098 const axis2_env_t *env);
00099
00108 axis2_status_t (AXIS2_CALL *
00109 set_constraint_qname) (
00110 void *property_el,
00111 const axis2_env_t *env,
00112 axis2_qname_t *qname);
00113
00114 axis2_qname_t *(AXIS2_CALL *
00115 get_constraint_qname) (
00116 void *property_el,
00117 const axis2_env_t *env);
00118
00129 struct xml_schema_type *(AXIS2_CALL *
00130 get_constraint) (
00131 void *property_el,
00132 const axis2_env_t *env);
00133
00141 axis2_status_t (AXIS2_CALL *
00142 set_has_value_token) (
00143 void *property_el,
00144 const axis2_env_t *env,
00145 axis2_bool_t b);
00146
00153 axis2_bool_t (AXIS2_CALL *
00154 has_value_token) (
00155 void *property_el,
00156 const axis2_env_t *env);
00157
00158 };
00159
00160 union woden_property_element_base
00161 {
00162 woden_documentable_element_t documentable_element;
00163 woden_nested_element_t nested_element;
00164 };
00165
00166 struct woden_property_element
00167 {
00168 woden_property_element_base_t base;
00169 woden_property_element_ops_t *ops;
00170 };
00171
00172
00173 axis2_status_t AXIS2_CALL
00174 woden_property_element_resolve_methods(
00175 woden_property_element_t *property_element,
00176 const axis2_env_t *env,
00177 axis2_hash_t *methods);
00178
00179
00180 #define WODEN_PROPERTY_ELEMENT_FREE(doc_el, env) \
00181 (((woden_property_element_t *) doc_el)->ops->\
00182 free (doc_el, env))
00183
00184 #define WODEN_PROPERTY_ELEMENT_TYPE(doc_el, env) \
00185 (((woden_property_element_t *) doc_el)->ops->\
00186 type (doc_el, env))
00187
00188 #define WODEN_PROPERTY_ELEMENT_SET_REF(doc_el, env, uri) \
00189 (((woden_property_element_t *) doc_el)->ops->\
00190 set_ref(doc_el, env, uri))
00191
00192 #define WODEN_PROPERTY_ELEMENT_GET_REF(doc_el, env) \
00193 (((woden_property_element_t *) doc_el)->ops->\
00194 get_value(doc_el, env))
00195
00196 #define WODEN_PROPERTY_ELEMENT_SET_VALUE(doc_el, env, value) \
00197 (((woden_property_element_t *) doc_el)->ops->\
00198 set_value(doc_el, env, value))
00199
00200 #define WODEN_PROPERTY_ELEMENT_GET_VALUE(doc_el, env) \
00201 (((woden_property_element_t *) doc_el)->ops->\
00202 get_value(doc_el, env))
00203
00204
00205 #define WODEN_PROPERTY_ELEMENT_SET_CONSTRAINT_QNAME(doc_el, env, qname) \
00206 (((woden_property_element_t *) doc_el)->ops->\
00207 set_constraint_qname(doc_el, env, qname))
00208
00209 #define WODEN_PROPERTY_ELEMENT_GET_CONSTRAINT_QNAME(doc_el, env) \
00210 (((woden_property_element_t *) doc_el)->ops->\
00211 get_constraint_qname(doc_el, env))
00212
00213 #define WODEN_PROPERTY_ELEMENT_GET_CONSTRAINT(doc_el, env) \
00214 (((woden_property_element_t *) doc_el)->ops->\
00215 get_constraint(doc_el, env))
00216
00217 #define WODEN_PROPERTY_ELEMENT_SET_HAS_VALUE_TOKEN(doc_el, env, b) \
00218 (((woden_property_element_t *) doc_el)->ops->\
00219 set_has_value_token(doc_el, env, b))
00220
00221 #define WODEN_PROPERTY_ELEMENT_HAS_VALUE_TOKEN(doc_el, env) \
00222 (((woden_property_element_t *) doc_el)->ops->\
00223 has_value_token(doc_el, env))
00224
00225
00227 #ifdef __cplusplus
00228 }
00229 #endif
00230 #endif