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