00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef W2C_WRITER_H
00018 #define W2C_WRITER_H
00019
00025 #include <axis2_utils.h>
00026 #include <axiom.h>
00027 #include <w2c_config_property_loader.h>
00028 #include <w2c_engine_configuration.h>
00029
00030 #ifdef __cplusplus
00031 extern "C"
00032 {
00033 #endif
00034
00035 #define W2C_WRITER_XSLT_PATH "/conf/templates/"
00036
00043 typedef struct w2c_writer w2c_writer_t;
00044 typedef struct w2c_writer_ops w2c_writer_ops_t;
00045
00046 AXIS2_DECLARE_DATA struct w2c_writer_ops
00047 {
00055 axis2_status_t (AXIS2_CALL *
00056 free)(w2c_writer_t *writer,
00057 const axis2_env_t *env);
00058
00067 axis2_char_t* (AXIS2_CALL *
00068 create_out_file)(w2c_writer_t *writer,
00069 const axis2_env_t *env,
00070 axis2_char_t *package_name,
00071 axis2_char_t *file_name);
00072
00081 axis2_status_t (AXIS2_CALL *
00082 parse)(w2c_writer_t *writer,
00083 const axis2_env_t *env,
00084 axiom_node_t *root);
00085
00095 axis2_status_t (AXIS2_CALL *
00096 initialize)(w2c_writer_t *writer,
00097 const axis2_env_t *env,
00098 w2c_config_property_loader_t *loader,
00099 w2c_engine_configuration_t *config);
00100
00101 };
00102
00103 AXIS2_DECLARE_DATA struct w2c_writer
00104 {
00105 struct w2c_writer_ops *ops;
00106 };
00107
00110
00111
00112 #define W2C_WRITER_FREE(writer, env) \
00113 ((writer)->ops->free (writer, env))
00114
00115 #define W2C_WRITER_CREATE_OUT_FILE(writer, env, package, file) \
00116 ((writer)->ops->create_out_file(writer, env, package, file ))
00117
00118 #define W2C_WRITER_PARSE(writer, env, root) \
00119 ((writer)->ops->parse(writer, env, root ))
00120
00121 #define W2C_WRITER_INITIALIZE(writer, env, loader, config) \
00122 ((writer)->ops->initialize(writer, env, loader, config))
00123
00126 #ifdef __cplusplus
00127 }
00128 #endif
00129
00130 #endif