xml_schema_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 XML_SCHEMA_BUILDER_H
00018 #define XML_SCHEMA_BUILDER_H
00019 
00028 #include <xml_schema_defines.h>
00029 #include <xml_schema_annotated.h>
00030 #include <xml_schema.h>
00031 #include <axiom.h>
00032 #include <axis2_hash.h>
00033 #include <xml_schema_collection.h>
00034 #include <axiom_util.h>
00041 #ifdef __cplusplus
00042 extern "C"
00043 {
00044 #endif
00045 
00046 
00047 
00048 typedef struct xml_schema_builder 
00049                     xml_schema_builder_t;
00050 typedef struct xml_schema_builder_ops 
00051                     xml_schema_builder_ops_t;
00052 
00053 #define XML_SCHEMA_NS "http://www.w3.org/2001/XMLSchema"
00054 
00055 
00056 struct xml_schema_builder_ops
00057 {
00058     xml_schema_t* (AXIS2_CALL *
00059     build)(
00060             xml_schema_builder_t *builder,
00061             const axis2_env_t *env,
00062             axiom_document_t *om_doc,
00063             axis2_char_t *uri);
00064            
00065     xml_schema_t* (AXIS2_CALL *
00066     build_with_root_node)(
00067             xml_schema_builder_t *builder,
00068             const axis2_env_t *env,
00069             axiom_node_t *om_node,
00070             axis2_char_t *uri);
00071             
00072     axis2_status_t (AXIS2_CALL *
00073     free)(xml_schema_builder_t *builder,
00074           const axis2_env_t *env);            
00075 };
00076 
00077 struct xml_schema_builder
00078 {
00079     xml_schema_builder_ops_t *ops;
00080 };
00081 
00082 
00083 AXIS2_EXTERN xml_schema_builder_t * AXIS2_CALL
00084 xml_schema_builder_create(
00085         const axis2_env_t *env,
00086         xml_schema_collection_t *sch_collection);
00087 
00088 /***************** Macros *****************************************************/
00089 
00090 #define XML_SCHEMA_BUILDER_FREE(builder, env) \
00091         ((builder)->ops->free(builder, env))
00092 
00093 #define XML_SCHEMA_BUILDER_BUILD(builder, env, om_doc, uri) \
00094         ((builder)->ops->build(builder, env, om_doc, uri))
00095         
00096 #define XML_SCHEMA_BUILDER_BUILD_WITH_ROOT_NODE(builder, env, om_node, uri) \
00097         ((builder)->ops->build_with_root_node(builder, env, om_node, uri))
00098         
00099 /**************** end macros **************************************************/
00100 
00102 #ifdef __cplusplus
00103 }
00104 #endif
00105 #endif /* XML_SCHEMA_BUILDER_H */

Generated on Thu Aug 31 17:32:37 2006 for Axis2/C by  doxygen 1.4.6