00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #ifndef AXIOM_SOAP_HEADER_BLOCK_H
00019 #define AXIOM_SOAP_HEADER_BLOCK_H
00020
00021
00026 #include <axis2_env.h>
00027 #include <axiom_node.h>
00028 #include <axiom_element.h>
00029 #include <axis2_array_list.h>
00030 #include <axiom_soap_header.h>
00031
00032 #ifdef __cplusplus
00033 extern "C"
00034 {
00035 #endif
00036
00037 typedef struct axiom_soap_header_block axiom_soap_header_block_t;
00038 typedef struct axiom_soap_header_block_ops axiom_soap_header_block_ops_t;
00039
00050 struct axiom_soap_header_block_ops
00051 {
00059 axis2_status_t (AXIS2_CALL *
00060 free_fn)(axiom_soap_header_block_t *header_block,
00061 const axis2_env_t *env);
00062
00063 axis2_status_t (AXIS2_CALL *
00064 set_role)(axiom_soap_header_block_t *header_block,
00065 const axis2_env_t *env,
00066 axis2_char_t *uri);
00067
00068 axis2_status_t (AXIS2_CALL *
00069 set_must_understand_with_bool)(axiom_soap_header_block_t *header_block,
00070 const axis2_env_t *env,
00071 axis2_bool_t must_understand);
00072
00073 axis2_status_t (AXIS2_CALL *
00074 set_must_understand_with_string)(axiom_soap_header_block_t *header_block,
00075 const axis2_env_t *env,
00076 axis2_char_t *must_understand);
00077
00078 axis2_bool_t (AXIS2_CALL *
00079 get_must_understand)(axiom_soap_header_block_t *header_block,
00080 const axis2_env_t *env);
00081
00082
00083 axis2_bool_t (AXIS2_CALL *
00084 is_processed)(axiom_soap_header_block_t *header_block,
00085 const axis2_env_t *env);
00086
00087 axis2_status_t (AXIS2_CALL *
00088 set_processed)(axiom_soap_header_block_t *header_block,
00089 const axis2_env_t *env);
00090
00091 axis2_char_t* (AXIS2_CALL *
00092 get_role)(axiom_soap_header_block_t *header_block,
00093 const axis2_env_t *env);
00094
00095 axis2_status_t (AXIS2_CALL *
00096 set_attribute)(axiom_soap_header_block_t *header_block,
00097 const axis2_env_t *env,
00098 const axis2_char_t *attr_name,
00099 const axis2_char_t *attr_value,
00100 const axis2_char_t *soap_envelope_namespace_uri);
00101
00102
00103 axis2_char_t* (AXIS2_CALL *
00104 get_attribute)(axiom_soap_header_block_t *header_block,
00105 const axis2_env_t *env,
00106 const axis2_char_t *attr_name,
00107 const axis2_char_t *soap_envelope_namespace_uri);
00108
00109
00110 axiom_node_t* (AXIS2_CALL *
00111 get_base_node)(axiom_soap_header_block_t *header_block,
00112 const axis2_env_t *env);
00113
00114 int (AXIS2_CALL *
00115 get_soap_version)(axiom_soap_header_block_t *header_block,
00116 const axis2_env_t *env);
00117
00118 };
00119
00124 struct axiom_soap_header_block
00125 {
00127 axiom_soap_header_block_ops_t *ops;
00128
00129 };
00130
00138 AXIS2_EXTERN axiom_soap_header_block_t * AXIS2_CALL
00139 axiom_soap_header_block_create_with_parent(const axis2_env_t *env,
00140 const axis2_char_t *localname,
00141 axiom_namespace_t *ns,
00142 struct axiom_soap_header *parent);
00143
00144
00145
00147 #define AXIOM_SOAP_HEADER_BLOCK_FREE(header_block , env) \
00148 ((header_block)->ops->free_fn(header_block, env))
00149
00150 #define AXIOM_SOAP_HEADER_BLOCK_GET_ROLE(header_block , env) \
00151 ((header_block)->ops->get_role(header_block, env))
00152
00153 #define AXIOM_SOAP_HEADER_BLOCK_IS_PROCESSED(header_block , env) \
00154 ((header_block)->ops->is_processed(header_block, env))
00155
00156 #define AXIOM_SOAP_HEADER_BLOCK_SET_PRECESSED(header_block , env) \
00157 ((header_block)->ops->set_processed(header_block, env))
00158
00159 #define AXIOM_SOAP_HEADER_BLOCK_GET_MUST_UNDERSTAND(header_block, env) \
00160 ((header_block)->ops->get_must_understand(header_block, env))
00161
00162 #define AXIOM_SOAP_HEADER_BLOCK_SET_MUST_UNDERSTAND_WITH_BOOL(header_block,\
00163 env, must_understand) \
00164 ((header_block)->ops->set_must_understand_with_bool(header_block, \
00165 env, must_understand))
00166
00167 #define AXIOM_SOAP_HEADER_BLOCK_SET_MUST_UNDERSTAND_WITH_STRING(header_block,\
00168 env, must_understand) \
00169 ((header_block)->ops->set_must_understand_with_string(header_block, \
00170 env, must_understand))
00171
00172 #define AXIOM_SOAP_HEADER_BLOCK_GET_BASE_NODE(header_block, env) \
00173 ((header_block)->ops->get_base_node(header_block, env))
00174
00175 #define AXIOM_SOAP_HEADER_BLOCK_GET_SOAP_VERSION(header_block, env) \
00176 ((header_block)->ops->get_soap_version(header_block, env))
00177
00178 #define AXIOM_SOAP_HEADER_BLOCK_GET_ATTRIBUTE(header_block, env,\
00179 attr_name, soap_envelope_namespace_uri) \
00180 ((header_block)->ops->get_attribute(header_block, env, \
00181 attr_name, soap_envelope_namespace_uri))
00182
00183 #define AXIOM_SOAP_HEADER_BLOCK_SET_ATTRIBUTE(header_block, env,\
00184 attr_name, attr_value, soap_envelope_namespace_uri) \
00185 ((header_block)->ops->set_attribute(header_block, env, \
00186 attr_name, attr_value, soap_envelope_namespace_uri))
00187
00190 #ifdef __cplusplus
00191 }
00192 #endif
00193 #endif