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