axiom_soap_builder.h

Go to the documentation of this file.
00001 /*
00002  * Licensed to the Apache Software Foundation (ASF) under one or more
00003  * contributor license agreements.  See the NOTICE file distributed with
00004  * this work for additional information regarding copyright ownership.
00005  * The ASF licenses this file to You under the Apache License, Version 2.0
00006  * (the "License"); you may not use this file except in compliance with
00007  * the License.  You may obtain a copy of the License at
00008  *
00009  *      http://www.apache.org/licenses/LICENSE-2.0
00010  *
00011  * Unless required by applicable law or agreed to in writing, software
00012  * distributed under the License is distributed on an "AS IS" BASIS,
00013  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00014  * See the License for the specific language governing permissions and
00015  * limitations under the License.
00016  */
00017  
00018  #ifndef AXIOM_SOAP_BUILDER_H
00019  #define AXIOM_SOAP_BUILDER_H
00020  
00021  #include <axiom_stax_builder.h>
00022  #include <axiom_soap_envelope.h>
00023  
00029 #ifdef __cplusplus
00030 extern "C"
00031 {
00032 #endif
00033 
00034 
00035 typedef struct axiom_soap_builder axiom_soap_builder_t;
00036 typedef struct axiom_soap_builder_ops  axiom_soap_builder_ops_t;
00037     
00049    struct axiom_soap_builder_ops
00050 {
00051         axis2_status_t (AXIS2_CALL *free)(axiom_soap_builder_t *builder,
00052                                           const axis2_env_t *env);
00053 
00054         axiom_soap_envelope_t* (AXIS2_CALL *get_soap_envelope)
00055                                          (axiom_soap_builder_t *builder,
00056                                           const axis2_env_t *env);
00057                                           
00058         axiom_document_t* (AXIS2_CALL *get_document)
00059                                          (axiom_soap_builder_t *builder,
00060                                           const axis2_env_t *env);
00061                                           
00062         axis2_status_t (AXIS2_CALL *next)(axiom_soap_builder_t *builder,
00063                                 const axis2_env_t *env);
00064                                 
00065                                                      
00066         axiom_node_t* (AXIS2_CALL *get_document_element)
00067                                             (axiom_soap_builder_t *builder,
00068                                              const axis2_env_t *env); 
00069                                              
00070         axis2_status_t (AXIS2_CALL *set_bool_processing_mandatory_fault_elements)
00071                                             (axiom_soap_builder_t *builder,
00072                                              const axis2_env_t *env,
00073                                              axis2_bool_t value);
00074         
00075         axis2_status_t (AXIS2_CALL *set_processing_detail_elements)
00076                                     (axiom_soap_builder_t *builder,
00077                                      const axis2_env_t *env,
00078                                      axis2_bool_t value);
00079                                      
00080         axis2_bool_t (AXIS2_CALL *is_processing_detail_elements)
00081                                     (axiom_soap_builder_t *builder, 
00082                                      const axis2_env_t *env);
00083                                      
00084                                      
00085         int (AXIS2_CALL *get_soap_version)(axiom_soap_builder_t *builder,
00086                                            const axis2_env_t *env);
00087                                            
00088         axis2_status_t (AXIS2_CALL *process_namespace_data)
00089                                           (axiom_soap_builder_t *builder,
00090                                            const axis2_env_t *env,
00091                                            axiom_node_t *om_node,
00092                                            axis2_bool_t is_soap_element);
00093         axis2_status_t (AXIS2_CALL *
00094         set_mime_body_parts)
00095                                     (axiom_soap_builder_t *builder, 
00096                                      const axis2_env_t *env,
00097                                      axis2_hash_t *map); 
00098 };
00099                                                       
00100 
00106 struct axiom_soap_builder
00107 {
00109     axiom_soap_builder_ops_t *ops;
00110 };
00111 
00117 AXIS2_EXTERN axiom_soap_builder_t * AXIS2_CALL
00118 axiom_soap_builder_create(const axis2_env_t *env,
00119                                 axiom_stax_builder_t *builder,
00120                                 const axis2_char_t *soap_version);
00121 
00122 /******************** Macros **************************************************/
00123     
00124 #define AXIOM_SOAP_BUILDER_FREE(builder, env) \
00125         ((builder)->ops->free(builder, env))
00126 
00127 #define AXIOM_SOAP_BUILDER_GET_SOAP_ENVELOPE(builder, env) \
00128         ((builder)->ops->get_soap_envelope(builder, env))
00129         
00130 #define AXIOM_SOAP_BUILDER_GET_DOCUMENT_ELEMENT(builder, env) \
00131         ((builder)->ops->get_document_element(builder, env))
00132         
00133 #define AXIOM_SOAP_BUILDER_NEXT(builder, env) \
00134         ((builder)->ops->next(builder, env))
00135         
00136 #define AXIOM_SOAP_BUILDER_GET_DOCUMENT(builder, env) \
00137         ((builder)->ops->get_document(builder, env))
00138         
00139 #define AXIOM_SOAP_BUILDER_NEXT(builder, env) \
00140         ((builder)->ops->next(builder, env)) 
00141         
00142 #define AXIOM_SOAP_BUILDER_SET_BOOL_PROCESSING_MANDATORY_FAULT_ELEMENTS(builder, env, value) \
00143         ((builder)->ops->set_bool_processing_mandatory_fault_elements(builder, env, value))
00144  
00145 #define AXIOM_SOAP_BUILDER_SET_PROCESSING_DETAIL_ELEMENTS(builder, env, value) \
00146         ((builder)->ops->set_processing_detail_elements(builder, env, value))
00147         
00148 #define AXIOM_SOAP_BUILDER_IS_PROCESSING_DETAIL_ELEMENTS(builder, env) \
00149         ((builder)->ops->is_processing_detail_elements(builder, env))                         
00150 
00151 
00152 #define AXIOM_SOAP_BUILDER_GET_SOAP_VERSION(builder, env) \
00153         ((builder)->ops->get_soap_version(builder, env))
00154         
00155 #define AXIOM_SOAP_BUILDER_PROCESS_NAMESPACE_DATA(builder, env, om_node, is_soap_element) \
00156         ((builder)->ops->process_namespace_data(builder, env, om_node, is_soap_element))
00157         
00158 #define AXIOM_SOAP_BUILDER_SET_MIME_BODY_PARTS(builder, env, map) \
00159         ((builder)->ops->set_mime_body_parts(builder, env, map))
00160         
00162 #ifdef __cplusplus
00163 }
00164 #endif 
00165 #endif /* AXIOM_SOAP_BUILDER_H */

Generated on Wed Dec 20 20:34:49 2006 for Axis2/C by  doxygen 1.5.1