Main Page | Modules | Class List | Directories | File List | Class Members | File Members

axis2_om_stax_builder.h

Go to the documentation of this file.
00001 /*
00002  * Copyright 2004,2005 The Apache Software Foundation.
00003  *
00004  * Licensed under the Apache License, Version 2.0 (the "License");
00005  * you may not use this file except in compliance with the License.
00006  * You may obtain a copy of the License at
00007  *
00008  *      http://www.apache.org/licenses/LICENSE-2.0
00009  *
00010  * Unless required by applicable law or agreed to in writing, software
00011  * distributed under the License is distributed on an "AS IS" BASIS,
00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013  * See the License for the specific language governing permissions and
00014  * limitations under the License.
00015  */
00016 
00017 #ifndef AXIS2_OM_STAX_BUILDER_H
00018 #define AXIS2_OM_STAX_BUILDER_H
00019 
00025 #include <axis2_om_node.h>
00026 #include <axis2_pull_parser.h>
00027 #include <axis2_om_document.h>
00028 #include <axis2_env.h>
00029 
00030 #ifdef __cplusplus
00031 extern "C"
00032 {
00033 #endif
00034 
00035 
00036     struct axis2_om_stax_builder;
00037     struct axis2_om_stax_builder_ops;
00038 
00049  AXIS2_DECLARE_DATA    typedef struct axis2_om_stax_builder_ops
00050     {
00058         axis2_om_node_t*(AXIS2_CALL *next) (struct axis2_om_stax_builder *builder,
00059                                             axis2_env_t **env);
00060 
00067         axis2_status_t (AXIS2_CALL *discard_current_element)
00068                                     (struct axis2_om_stax_builder *builder,
00069                                      axis2_env_t **env);
00078                 axis2_status_t (AXIS2_CALL *free)(struct axis2_om_stax_builder *builder,
00079                                                   axis2_env_t **env);
00080         
00088         axis2_om_document_t* (AXIS2_CALL *get_document)
00089                                          (struct axis2_om_stax_builder *builder,
00090                                           axis2_env_t **env);
00101         axis2_status_t  (AXIS2_CALL *set_document)(struct axis2_om_stax_builder *builder,
00102                                                    axis2_env_t **env,
00103                                                    axis2_om_document_t *document);                                                    
00104                                                            
00105     } axis2_om_stax_builder_ops_t;
00106 
00111     typedef struct axis2_om_stax_builder
00112     {
00114         axis2_om_stax_builder_ops_t *ops;
00115        
00116     }axis2_om_stax_builder_t;
00117 
00123     AXIS2_DECLARE(axis2_om_stax_builder_t *)
00124     axis2_om_stax_builder_create(axis2_env_t **env,
00125                                            axis2_pull_parser_t *parser);
00126 
00127 
00129 #define AXIS2_OM_STAX_BUILDER_NEXT(builder,env) \
00130         ((builder)->ops->next(builder, env))
00132 #define AXIS2_OM_STAX_BUILDER_DISCARD(builder,env) \
00133         ((builder)->ops->discard_current_element(builder, env))
00135 #define AXIS2_OM_STAX_BUILDER_FREE(builder,env) \
00136         ((builder)->ops->free(builder,env))
00138 #define AXIS2_OM_STAX_BUILDER_SET_DOCUMENT(builder,env,document) \
00139         ((builder)->ops->set_document(builder,env,document))
00141 #define AXIS2_OM_STAX_BUILDER_GET_DOCUMENT(builder,env) \
00142         ((builder)->ops->get_document(builder,env))
00143         
00147 #ifdef __cplusplus
00148 }
00149 #endif
00150 
00151 
00152 #endif                          /* AXIS2_OM_STAX_BUILDER_H */

Generated on Thu Nov 24 13:58:30 2005 for Axis2/C by  doxygen 1.4.2