00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef AXIS2_FLOW_H
00018 #define AXIS2_FLOW_H
00019
00032 #include <axis2_const.h>
00033 #include <axis2_error.h>
00034 #include <axis2_defines.h>
00035 #include <axis2_env.h>
00036 #include <axis2_allocator.h>
00037 #include <axis2_string.h>
00038 #include <axis2_array_list.h>
00039 #include <axis2_handler_desc.h>
00040
00041
00042 #ifdef __cplusplus
00043 extern "C"
00044 {
00045 #endif
00046
00048 typedef struct axis2_flow_ops axis2_flow_ops_t;
00050 typedef struct axis2_flow axis2_flow_t;
00051
00052
00057 struct axis2_flow_ops
00058 {
00065 axis2_status_t (AXIS2_CALL *
00066 free)(
00067 axis2_flow_t *flow,
00068 const axis2_env_t *env);
00069
00077 axis2_status_t (AXIS2_CALL *
00078 add_handler)(
00079 axis2_flow_t *flow,
00080 const axis2_env_t *env,
00081 axis2_handler_desc_t *handler);
00082
00090 axis2_handler_desc_t *(AXIS2_CALL *
00091 get_handler)(
00092 const axis2_flow_t *flow,
00093 const axis2_env_t *env,
00094 const int index);
00095
00102 int (AXIS2_CALL *
00103 get_handler_count)(
00104 const axis2_flow_t *flow,
00105 const axis2_env_t *env);
00106 };
00107
00111 struct axis2_flow
00112 {
00114 axis2_flow_ops_t *ops;
00115 };
00116
00122 AXIS2_EXTERN axis2_flow_t *AXIS2_CALL
00123 axis2_flow_create (
00124 const axis2_env_t *env);
00125
00133 AXIS2_EXTERN axis2_status_t AXIS2_CALL
00134 axis2_flow_free_void_arg (
00135 void *flow,
00136 const axis2_env_t *env);
00137
00138
00141 #define AXIS2_FLOW_FREE(flow, env) ((flow)->ops->free (flow, env))
00142
00145 #define AXIS2_FLOW_ADD_HANDLER(flow, env, handler) \
00146 ((flow)->ops->add_handler (flow, env, handler))
00147
00150 #define AXIS2_FLOW_GET_HANDLER(flow, env, index) \
00151 ((flow)->ops->get_handler (flow, env, index))
00152
00155 #define AXIS2_FLOW_GET_HANDLER_COUNT(flow, env) \
00156 ((flow)->ops->get_handler_count (flow, env))
00157
00160 #ifdef __cplusplus
00161 }
00162 #endif
00163 #endif