00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef WODEN_CONFIGURABLE_H
00018 #define WODEN_CONFIGURABLE_H
00019
00029 #include <woden.h>
00030 #include <woden_configurable_element.h>
00031 #include <woden_configurable_component.h>
00032 #include <woden_documentable.h>
00033
00039 typedef union woden_configurable_base woden_configurable_base_t;
00040 typedef struct woden_configurable woden_configurable_t;
00041 typedef struct woden_configurable_ops woden_configurable_ops_t;
00042 struct woden_documentable;
00043
00044 #ifdef __cplusplus
00045 extern "C"
00046 {
00047 #endif
00048
00049 struct woden_configurable_ops
00050 {
00055 axis2_status_t (AXIS2_CALL *
00056 free) (
00057 void *configurable,
00058 const axis2_env_t *env);
00059
00060 axis2_status_t (AXIS2_CALL *
00061 to_configurable_free) (
00062 void *configurable,
00063 const axis2_env_t *env);
00064
00065 axis2_hash_t *(AXIS2_CALL *
00066 super_objs) (
00067 void *configurable,
00068 const axis2_env_t *env);
00069
00073 struct woden_documentable *(AXIS2_CALL *
00074 get_base_impl) (
00075 void *configurable,
00076 const axis2_env_t *env);
00077
00078
00079 };
00080
00081 union woden_configurable_base
00082 {
00083 woden_documentable_t documentable;
00084 woden_configurable_element_t configurable_element;
00085 woden_configurable_component_t configurable_component;
00086 };
00087
00088 struct woden_configurable
00089 {
00090 woden_configurable_base_t base;
00091 woden_configurable_ops_t *ops;
00092 };
00093
00094 AXIS2_EXTERN woden_configurable_t * AXIS2_CALL
00095 woden_configurable_create(
00096 const axis2_env_t *env);
00097
00098
00099 AXIS2_EXTERN woden_configurable_t * AXIS2_CALL
00100 woden_configurable_to_configurable_element(
00101 void *configurable,
00102 const axis2_env_t *env);
00103
00104 AXIS2_EXTERN axis2_status_t AXIS2_CALL
00105 woden_configurable_resolve_methods(
00106 woden_configurable_t *configurable,
00107 const axis2_env_t *env,
00108 woden_configurable_t *configurable_impl,
00109 axis2_hash_t *methods);
00110
00111
00112 #define WODEN_CONFIGURABLE_FREE(configurable, env) \
00113 (((woden_configurable_t *) configurable)->ops->\
00114 free(configurable, env))
00115
00116 #define WODEN_CONFIGURABLE_TO_CONFIGURABLE_FREE(configurable, env) \
00117 (((woden_configurable_t *) configurable)->ops->\
00118 to_configurable_free(configurable, env))
00119
00120 #define WODEN_CONFIGURABLE_SUPER_OBJS(configurable, env) \
00121 (((woden_configurable_t *) configurable)->ops->\
00122 super_objs(configurable, env))
00123
00124 #define WODEN_CONFIGURABLE_GET_BASE_IMPL(configurable, env) \
00125 (((woden_configurable_t *) configurable)->ops->\
00126 get_base_impl(configurable, env))
00127
00129 #ifdef __cplusplus
00130 }
00131 #endif
00132 #endif