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

axis2_svr_callback.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_SVR_CALLBACK_H
00018 #define AXIS2_SVR_CALLBACK_H
00019 
00025 #ifdef __cplusplus
00026 extern "C"
00027 {
00028 #endif
00029     
00035 #include <axis2_defines.h>
00036 #include <axis2_const.h>
00037 #include <axis2_msg_ctx.h>
00038 
00039 typedef struct axis2_svr_callback axis2_svr_callback_t;
00040 typedef struct axis2_svr_callback_ops axis2_svr_callback_ops_t;
00041 
00046 struct axis2_svr_callback_ops
00047 {
00052     axis2_status_t (AXIS2_CALL *
00053     free) (axis2_svr_callback_t *svr_callback,
00054             const axis2_env_t *env);
00055 
00061     axis2_status_t (AXIS2_CALL *
00062     handle_result) (axis2_svr_callback_t *svr_callback,
00063                         const axis2_env_t *env,
00064                         axis2_msg_ctx_t *msg_ctx);
00065     
00071     axis2_status_t (AXIS2_CALL *
00072     handle_fault) (axis2_svr_callback_t *svr_callback,
00073                     const axis2_env_t *env,
00074                     axis2_msg_ctx_t *msg_ctx);               
00075 };
00076 
00081 struct axis2_svr_callback
00082 {
00083     axis2_svr_callback_ops_t *ops;    
00084 };
00085 
00090 AXIS2_EXTERN axis2_svr_callback_t * AXIS2_CALL
00091 axis2_svr_callback_create (const axis2_env_t *env);
00092 
00093 /************************** Start of function macros **************************/
00094 
00095 #define AXIS2_SVR_CALLBACK_FREE(svr_callback, env) \
00096         ((svr_callback)->ops->free (svr_callback, env))
00097 
00098 #define AXIS2_SVR_CALLBACK_HANDLER_RESULT(svr_callback, env, msg_ctx) \
00099       ((svr_callback)->ops->handle_result (svr_callback, env, msg_ctx))
00100 
00101 #define AXIS2_SVR_CALLBACK_HANDLER_FAULT(svr_callback, env, msg_ctx) \
00102       ((svr_callback)->ops->handle_fault (svr_callback, env, msg_ctx))
00103 
00104 /************************** End of function macros ****************************/
00105     
00107 #ifdef __cplusplus
00108 }
00109 #endif
00110 
00111 #endif                          /* AXIS2_SVR_CALLBACK_H */

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