Main Page | Modules | Class List | Directories | File List | Class Members | File Members | Examples

axis2_svc.h

Go to the documentation of this file.
00001 /*
00002  * Copyright 2004,2005 The Apache Software Foundation.
00003  *
00004  * Licensed under the Apache License, Version 2.0 (the "License");
00005  * you may not use this file except in compliance with the License.
00006  * You may obtain a copy of the License at
00007  *
00008  *      http://www.apache.org/licenses/LICENSE-2.0
00009  *
00010  * Unless required by applicable law or agreed to in writing, software
00011  * distributed under the License is distributed on an "AS IS" BASIS,
00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013  * See the License for the specific language governing permissions and
00014  * limitations under the License.
00015  */
00016 
00017 #ifndef AXIS2_SVC_H
00018 #define AXIS2_SVC_H
00019 
00025 #include <axis2_param_container.h>
00026 #include <axis2_flow_container.h>
00027 #include <axis2_wsdl_svc.h>
00028 #include <axis2_op.h>
00029 #include <axis2_svc_grp.h>
00030 #include <axis2_qname.h>
00031 #include <axis2_error.h>
00032 #include <axis2_array_list.h>
00033 #include <axis2_const.h>
00034 #include <axis2_phase_resolver.h>
00035 #include <axis2_module_desc.h>
00036 #include <axis2_conf.h>
00037 #include <axis2_wsdl_soap_op.h>
00038 #include <axis2_string.h>
00039 #include <axis2_wsdl_endpoint.h>
00040 
00041 #ifdef __cplusplus
00042 extern "C"
00043 {
00044 #endif
00045 
00051 struct axis2_wsdl_endpoint;
00052 struct axis2_svc_grp;
00053 struct axis2_op;
00054 struct axis2_flow_container;
00055 struct axis2_param_container;
00056 struct axis2_wsdl_svc;
00057 struct axis2_wsdl_interface; 
00058 struct axis2_module_desc; 
00059 struct axis2_conf;
00060 struct axis2_wsdl_soap_op;    
00061 typedef struct axis2_svc_ops axis2_svc_ops_t;   
00062 typedef struct axis2_svc axis2_svc_t;
00063     
00068 struct axis2_svc_ops
00069 {
00070    axis2_status_t (AXIS2_CALL *
00071     free) (axis2_svc_t *svc, 
00072             const axis2_env_t *env);
00073 
00074    axis2_status_t (AXIS2_CALL *
00075     add_op) (axis2_svc_t *svc, 
00076                     const axis2_env_t *env,
00077                     struct axis2_op *op);
00078 
00079    struct axis2_op *(AXIS2_CALL *
00080     get_op_with_qname) (axis2_svc_t *svc, 
00081                                   const axis2_env_t *env,
00082                                   const axis2_qname_t *op_qname);
00083 
00084    struct axis2_op *(AXIS2_CALL *
00085     get_op_with_name) (axis2_svc_t *svc, 
00086                                 const axis2_env_t *env,
00087                                 const axis2_char_t * op_name);
00088 
00089    axis2_hash_t *(AXIS2_CALL *
00090     get_ops) (axis2_svc_t *svc, 
00091                      const axis2_env_t *env);
00092 
00093    axis2_status_t (AXIS2_CALL *
00094     set_parent) (axis2_svc_t *svc, 
00095                     const axis2_env_t *env,
00096                     struct axis2_svc_grp *svc_grp);
00097 
00098    struct axis2_svc_grp *(AXIS2_CALL *
00099     get_parent) (axis2_svc_t *svc, 
00100                  const axis2_env_t *env);
00101    
00102     axis2_status_t (AXIS2_CALL *
00103     set_qname) (axis2_svc_t *svc, 
00104                 const axis2_env_t *env,
00105                 axis2_qname_t *qname);
00106     
00107    axis2_qname_t *(AXIS2_CALL *
00108     get_qname) (const axis2_svc_t *svc, 
00109                const axis2_env_t *env);
00110 
00111    axis2_status_t (AXIS2_CALL *
00112     add_param) (axis2_svc_t *svc, 
00113                 const axis2_env_t *env,
00114                 axis2_param_t *param);
00115 
00116    axis2_param_t *(AXIS2_CALL *
00117     get_param) (axis2_svc_t *svc, 
00118                 const axis2_env_t *env,
00119                 const axis2_char_t *name);
00120 
00121    axis2_array_list_t *(AXIS2_CALL *
00122     get_params) (axis2_svc_t *svc, 
00123                     const axis2_env_t *env);
00124    
00125    axis2_bool_t (AXIS2_CALL *
00126     is_param_locked) (axis2_svc_t *svc, 
00127                         const axis2_env_t *env,
00128                         axis2_char_t *param_name);
00129                                                 
00130     axis2_status_t (AXIS2_CALL *
00131     set_svc_interface) (axis2_svc_t *svc,
00132                             const axis2_env_t *env,
00133                             struct axis2_wsdl_interface *svc_interface);
00134                                 
00135     struct axis2_wsdl_interface * (AXIS2_CALL *
00136     get_svc_interface) (axis2_svc_t *svc,
00137                                 const axis2_env_t *env);                               
00138 
00139                                 
00146     axis2_status_t (AXIS2_CALL *
00147     engage_module) (axis2_svc_t *svc,
00148                     const axis2_env_t *env,
00149                     struct axis2_module_desc * moduleref,
00150                     struct axis2_conf * axis2_config);
00151     
00157     axis2_status_t (AXIS2_CALL *
00158     add_module_ops) (axis2_svc_t *svc,
00159                                 const axis2_env_t *env,
00160                                 struct axis2_module_desc * module_desc,
00161                                 struct axis2_conf * axis2_config); 
00162                                     
00163     axis2_status_t (AXIS2_CALL *
00164     add_to_engaged_module_list) (axis2_svc_t *svc,
00165                                     const axis2_env_t *env,
00166                                     struct axis2_module_desc *module_name);  
00167                                         
00173     axis2_array_list_t * (AXIS2_CALL *
00174     get_engaged_modules) (axis2_svc_t *svc,
00175                           const axis2_env_t *env);
00176     
00182     void * (AXIS2_CALL *
00183     get_wsdl_op) (axis2_svc_t *svc,
00184                                     const axis2_env_t *env,
00185                                     axis2_qname_t *op_name);
00186     
00192     axis2_status_t (AXIS2_CALL *
00193     set_context_path) (axis2_svc_t *svc,
00194                         const axis2_env_t *env,
00195                         axis2_char_t *context_path);
00196     
00202     axis2_char_t * (AXIS2_CALL *
00203     get_context_path) (axis2_svc_t *svc,
00204                        const axis2_env_t *env);
00205     
00211     axis2_status_t (AXIS2_CALL *
00212     set_style) (axis2_svc_t *svc,
00213                 const axis2_env_t *env,
00214                 axis2_char_t * style);
00215     
00221     axis2_char_t * (AXIS2_CALL *
00222     get_style) (axis2_svc_t *svc,
00223                 const axis2_env_t *env);
00224     
00230     struct axis2_flow * (AXIS2_CALL *
00231     get_inflow) (axis2_svc_t *svc,
00232                  const axis2_env_t *env);
00233     
00239     axis2_status_t (AXIS2_CALL *
00240     set_inflow) (axis2_svc_t *svc,
00241                     const axis2_env_t *env,
00242                     struct axis2_flow *inflow);
00243     
00249     struct axis2_flow * (AXIS2_CALL *
00250     get_outflow) (axis2_svc_t *svc,
00251                                 const axis2_env_t *env);
00252     
00258     axis2_status_t (AXIS2_CALL *
00259     set_outflow) (axis2_svc_t *svc,
00260                                 const axis2_env_t *env,
00261                                 struct axis2_flow *outflow);
00262     
00268     struct axis2_flow *(AXIS2_CALL *
00269     get_fault_inflow) (axis2_svc_t *svc,
00270                                 const axis2_env_t *env);
00271     
00277     axis2_status_t (AXIS2_CALL *
00278     set_fault_inflow) (axis2_svc_t *svc,
00279                                 const axis2_env_t *env,
00280                                 struct axis2_flow *fault_flow);
00281     
00282     struct axis2_flow * (AXIS2_CALL *
00283     get_fault_outflow) (axis2_svc_t *svc,
00284                                 const axis2_env_t *env);
00285     
00286     axis2_status_t (AXIS2_CALL *
00287     set_fault_outflow) (axis2_svc_t *svc,
00288                         const axis2_env_t *env,
00289                         struct axis2_flow *fault_flow);
00290     
00303     struct axis2_op * (AXIS2_CALL *
00304     get_op_by_soap_action) (axis2_svc_t *svc,
00305                                     const axis2_env_t *env,
00306                                     axis2_char_t *soap_action);
00307     
00320     struct axis2_op * (AXIS2_CALL *
00321     get_op_by_soap_action_and_endpoint) (axis2_svc_t *svc,
00322                                     const axis2_env_t *env,
00323                                     axis2_char_t *soap_action,
00324                                     axis2_qname_t * endpoint);       
00325     
00331     axis2_char_t * (AXIS2_CALL *
00332     get_name) (axis2_svc_t *svc,
00333                                 const axis2_env_t *env);
00334     
00340     axis2_status_t (AXIS2_CALL *
00341     set_name) (axis2_svc_t *svc,
00342                                 const axis2_env_t *env,
00343                                 axis2_char_t *axis2_svc_name);
00344     
00348     axis2_status_t (AXIS2_CALL *
00349     set_last_update) (axis2_svc_t *svc,
00350                                 const axis2_env_t *env);
00351     
00352     long (AXIS2_CALL *
00353     get_last_update) (axis2_svc_t *svc,
00354                                 const axis2_env_t *env);
00355     
00356     axis2_char_t * (AXIS2_CALL *
00357     get_filename) (axis2_svc_t *svc,
00358                                 const axis2_env_t *env);
00359     
00360     axis2_status_t (AXIS2_CALL *
00361     set_filename) (axis2_svc_t *svc,
00362                                 const axis2_env_t *env,
00363                                 axis2_char_t *filename);
00364     
00365     axis2_hash_t * (AXIS2_CALL *
00366     get_endpoints) (axis2_svc_t *svc,
00367                                 const axis2_env_t *env);
00368     
00369     axis2_status_t (AXIS2_CALL *
00370     set_endpoints) (axis2_svc_t *svc,
00371                     const axis2_env_t *env,
00372                     axis2_hash_t * endpoints);
00373     
00374     axis2_status_t (AXIS2_CALL *
00375     set_endpoint)(axis2_svc_t *svc,
00376                     const axis2_env_t *env,
00377                     struct axis2_wsdl_endpoint * endpoint);
00378     
00379     struct axis2_wsdl_endpoint * (AXIS2_CALL *
00380     get_endpoint) (axis2_svc_t *svc,
00381                     const axis2_env_t *env,
00382                     axis2_qname_t * qname);
00383     
00384     axis2_char_t * (AXIS2_CALL *
00385     get_namespace) (axis2_svc_t *svc,
00386                   const axis2_env_t *env);
00387     
00391     axis2_status_t (AXIS2_CALL *
00392     add_mapping) (axis2_svc_t *svc,
00393                 const axis2_env_t *env,
00394                 axis2_char_t * mapping_key , 
00395                 struct axis2_op * axis2_op);
00396  
00397     axis2_status_t (AXIS2_CALL *
00398     add_module_ref) (axis2_svc_t *svc,
00399                                 const axis2_env_t *env,
00400                                 axis2_qname_t *moduleref);
00401     
00402     axis2_array_list_t *(AXIS2_CALL *
00403     get_modules) (axis2_svc_t *svc,
00404                             const axis2_env_t *env);                
00405 };
00406 
00411 struct axis2_svc
00412 {
00413    axis2_svc_ops_t *ops; 
00414     struct axis2_param_container *param_container;
00415     struct axis2_flow_container *flow_container;
00416     struct axis2_wsdl_svc *wsdl_svc;    
00417 
00418 };
00419 
00424 AXIS2_EXTERN axis2_svc_t * AXIS2_CALL
00425 axis2_svc_create (const axis2_env_t *env);
00426 
00432 AXIS2_EXTERN axis2_svc_t * AXIS2_CALL
00433 axis2_svc_create_with_qname (const axis2_env_t *env, 
00434                                 axis2_qname_t *qname);
00435 
00441 AXIS2_EXTERN axis2_svc_t * AXIS2_CALL
00442 axis2_svc_create_with_wsdl_svc (const axis2_env_t *env, 
00443                                 struct axis2_wsdl_svc *wsdl_svc);
00444 
00445 /**************************** Start of function macros ************************/
00446 
00447 #define AXIS2_SVC_FREE(svc, env) ((svc)->ops->free (svc, env))
00448 
00449 #define AXIS2_SVC_ADD_OP(svc, env, op) \
00450       ((svc)->ops->add_op (svc, env, op))
00451 
00452 #define AXIS2_SVC_GET_OP_WITH_QNAME(svc, env, op_qname) \
00453       ((svc)->ops->get_op_with_qname (svc, env, op_qname))
00454 
00455 #define AXIS2_SVC_GET_OP_WITH_NAME(svc, env, op_name) \
00456       ((svc)->ops->get_op_with_name (svc, env, op_name))
00457 
00458 #define AXIS2_SVC_GET_OPS(svc, env) ((svc)->ops->get_ops (svc, env))
00459 
00460 #define AXIS2_SVC_SET_PARENT(svc, env , svc_grp) ((svc)->ops->set_parent \
00461         (svc, env, svc_grp))
00462 
00463 #define AXIS2_SVC_GET_PARENT(svc, env) ((svc)->ops->get_parent (svc, env))
00464 
00465 #define AXIS2_SVC_SET_QNAME(svc, env, qname) ((svc)->ops->set_qname(svc , env, qname))
00466 
00467 #define AXIS2_SVC_GET_QNAME(svc, env) ((svc)->ops->get_qname(svc , env))
00468       
00469 #define AXIS2_SVC_ADD_PARAM(svc, env, param) ((svc)->ops->add_param(svc , env, param))
00470       
00471 #define AXIS2_SVC_GET_PARAM(svc, env, name) ((svc)->ops->get_param(svc , env, name))
00472       
00473 #define AXIS2_SVC_GET_PARAMS(svc, env) ((svc)->ops->get_params(svc , env))
00474       
00475 #define AXIS2_SVC_IS_PARAM_LOCKED(svc, env, param_name) \
00476         ((svc)->ops->is_param_locked(svc, env, param_name))
00477 
00478 #define AXIS2_SVC_SET_SVC_INTERFACE(svc, env, svc_interface) \
00479         ((svc)->ops->set_svc_interface(svc, env, svc_interface))
00480 
00481 #define AXIS2_SVC_GET_SVC_INTERFACE(svc, env) \
00482         ((svc)->ops->get_svc_interface(svc, env))       
00483 
00484 #define AXIS2_SVC_ENGAGE_MODULE(svc, env, moduleref, axis2_config) \
00485         ((svc)->ops->engage_module(svc, env, moduleref, axis2_config))
00486 
00487 #define AXIS2_SVC_ADD_MODULE_OPS(svc, env, module_desc, axis2_config) \
00488         ((svc)->ops->add_module_ops(svc, env, module_desc, axis2_config))
00489 
00490 #define AXIS2_SVC_ADD_TO_ENGAGED_MODULE_LIST(svc, env, module_name) \
00491         ((svc)->ops->add_to_engaged_module_list(svc, env, module_name))
00492 
00493 #define AXIS2_SVC_GET_ENGAGED_MODULES(svc, env) \
00494         ((svc)->ops->get_engaged_modules(svc, env))
00495 
00496 #define AXIS2_SVC_GET_WSDL_OP(svc, env, op_name) \
00497         ((svc)->ops->get_wsdl_op(svc, env, op_name))
00498 
00499 #define AXIS2_SVC_SET_CONTEXT_PATH(svc, env, context_path) \
00500         ((svc)->ops->set_context_path(svc, env, context_path))
00501 
00502 #define AXIS2_SVC_GET_CONTEXT_PATH(svc, env) \
00503         ((svc)->ops->get_context_path(svc, env))
00504 
00505 #define AXIS2_SVC_SET_STYLE(svc, env, style) \
00506         ((svc)->ops->set_style(svc, env, style))
00507 
00508 #define AXIS2_SVC_GET_STYLE(svc, env) \
00509         ((svc)->ops->get_style(svc, env))
00510 
00511 #define AXIS2_SVC_GET_INFLOW(svc, env) \
00512         ((svc)->ops->get_inflow(svc, env))
00513 
00514 #define AXIS2_SVC_SET_INFLOW(svc, env, inflow) \
00515         ((svc)->ops->set_inflow(svc, env, inflow))
00516 
00517 #define AXIS2_SVC_GET_OUTFLOW(svc, env) \
00518         ((svc)->ops->get_outflow(svc, env))
00519 
00520 #define AXIS2_SVC_SET_OUTFLOW(svc, env, outflow) \
00521         ((svc)->ops->set_outflow(svc, env, outflow))
00522 
00523 #define AXIS2_SVC_GET_FAULT_INFLOW(svc, env) \
00524         ((svc)->ops->get_fault_inflow(svc, env))
00525 
00526 #define AXIS2_SVC_SET_FAULT_INFLOW(svc, env, fault_inflow) \
00527         ((svc)->ops->set_fault_inflow(svc, env, fault_inflow))
00528 
00529 #define AXIS2_SVC_GET_FAULT_OUTFLOW(svc, env) \
00530         ((svc)->ops->get_fault_outflow(svc, env))
00531 
00532 #define AXIS2_SVC_SET_FAULT_OUTFLOW(svc, env, fault_outflow) \
00533         ((svc)->ops->set_fault_outflow(svc, env, fault_outflow))
00534 
00535 #define AXIS2_SVC_GET_OP_BY_SOAP_ACTION(svc, env, soap_action) \
00536         ((svc)->ops->get_op_by_soap_action(svc, env, soap_action))
00537 
00538 #define AXIS2_SVC_GET_OP_BY_SOAP_ACTION_AND_ENDPOINT(svc, env, soap_action, endpoint) \
00539         ((svc)->ops->get_op_by_soap_action_and_endpoint(svc, env, soap_action, endpoint))
00540 
00541 #define AXIS2_SVC_GET_NAME(svc, env) \
00542         ((svc)->ops->get_name(svc, env))
00543 
00544 #define AXIS2_SVC_SET_NAME(svc, env, axis2_svc_name) \
00545         ((svc)->ops->set_name(svc, env, axis2_svc_name))
00546 
00547 #define AXIS2_SVC_SET_LAST_UPDATE(svc, env) \
00548         ((svc)->ops->set_last_update(svc, env))
00549 
00550 #define AXIS2_SVC_GET_LAST_UPDATE(svc, env) \
00551         ((svc)->ops->get_last_update(svc, env))
00552 
00553 #define AXIS2_SVC_GET_FILENAME(svc, env) \
00554         ((svc)->ops->get_filename(svc, env))
00555 
00556 #define AXIS2_SVC_SET_FILENAME(svc, env, filename) \
00557         ((svc)->ops->set_filename(svc, env, filename))
00558 
00559 #define AXIS2_SVC_GET_ENDPOINTS(svc, env) \
00560         ((svc)->ops->get_endpoints(svc, env))
00561 
00562 #define AXIS2_SVC_SET_ENDPOINTS(svc, env, endpoints) \
00563         ((svc)->ops->set_endpoints(svc, env, endpoints))
00564 
00565 #define AXIS2_SVC_SET_ENDPOINT(svc, env, endpoint) \
00566         ((svc)->ops->set_endpoint(svc, env, endpoint))
00567 
00568 #define AXIS2_SVC_GET_ENDPOINT(svc, env, qname) \
00569         ((svc)->ops->get_endpoint(svc, env, qname))
00570 
00571 #define AXIS2_SVC_GET_QNAMESPACE(svc, env) \
00572         ((svc)->ops->get_namespace(svc, env))
00573 
00574 #define AXIS2_SVC_ADD_MAPPING(svc, env, mapping_key, axis2_opt) \
00575         ((svc)->ops->add_mapping(svc, env, mapping_key, axis2_opt))
00576 
00577 #define AXIS2_SVC_ADD_MODULE_REF(svc, env, moduleref) \
00578         ((svc)->ops->add_module_ref(svc, env, moduleref))
00579         
00580 #define AXIS2_SVC_GET_MODULES(svc, env) \
00581         ((svc)->ops->get_modules(svc, env))
00582 
00583 /**************************** End of function macros **************************/
00584 
00586 #ifdef __cplusplus
00587 }
00588 #endif
00589 #endif                          /* AXIS2_SVC_H */

Generated on Fri Jun 16 18:02:31 2006 for Axis2/C by  doxygen 1.4.2