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

xml_schema_particle.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_PARTICLE_H
00018 #define XML_SCHEMA_PARTICLE_H
00019 
00026 #include <xml_schema_defines.h>
00027 #include <xml_schema_annotated.h>
00028 #include <axis2_hash.h>
00029 
00035 typedef struct xml_schema_particle 
00036                     xml_schema_particle_t;
00037 typedef struct xml_schema_particle_ops 
00038                     xml_schema_particle_ops_t;
00039 
00040 #ifdef __cplusplus
00041 extern "C"
00042 {
00043 #endif
00044 
00045 struct xml_schema_particle_ops
00046 {
00051     axis2_status_t (AXIS2_CALL *
00052     free) (
00053             void *particle,
00054             const axis2_env_t *env);
00055 
00056     axis2_hash_t *(AXIS2_CALL *
00057     super_objs) (
00058             void *particle,
00059             const axis2_env_t *env);
00060 
00061     xml_schema_types_t (AXIS2_CALL *
00062     get_type) (
00063             void *particle,
00064             const axis2_env_t *env);
00065 
00066     xml_schema_annotated_t *(AXIS2_CALL *
00067     get_base_impl) (void *particle,
00068                     const axis2_env_t *env);
00069 
00070     long (AXIS2_CALL *
00071     get_max_occurs)(void *particle,
00072                 const axis2_env_t *env);
00073     
00074     axis2_status_t (AXIS2_CALL *
00075     set_max_occurs)(void *particle,
00076                     const axis2_env_t *env,
00077                     long max_occurs);
00078     
00079     long (AXIS2_CALL *
00080     get_min_occurs)(void *particle,
00081                 const axis2_env_t *env);
00082     
00083     axis2_status_t (AXIS2_CALL *
00084     set_min_occurs)(void *particle,
00085                     const axis2_env_t *env,
00086                     long min_occurs);
00087 };
00088 
00089 struct xml_schema_particle
00090 {
00091     xml_schema_annotated_t base;
00092     xml_schema_particle_ops_t *ops;
00093 };
00094 
00103 AXIS2_EXTERN xml_schema_particle_t * AXIS2_CALL
00104 xml_schema_particle_create(const axis2_env_t *env);
00105 
00109 AXIS2_EXTERN axis2_status_t AXIS2_CALL
00110 xml_schema_particle_resolve_methods(
00111                                 xml_schema_particle_t *particle,
00112                                 const axis2_env_t *env,
00113                                 xml_schema_particle_t *particle_impl,
00114                                 axis2_hash_t *methods);
00115 
00116 #define XML_SCHEMA_PARTICLE_FREE(particle, env) \
00117       (((xml_schema_particle_t *) particle)->ops->\
00118             free(particle, env))
00119 
00120 #define XML_SCHEMA_PARTICLE_SUPER_OBJS(particle, env) \
00121       (((xml_schema_particle_t *) particle)->ops->\
00122             super_objs(particle, env))
00123 
00124 #define XML_SCHEMA_PARTICLE_GET_TYPE(particle, env) \
00125       (((xml_schema_particle_t *) particle)->ops->\
00126             get_type(particle, env))
00127 
00128 #define XML_SCHEMA_PARTICLE_GET_BASE_IMPL(particle, env) \
00129       (((xml_schema_particle_t *) particle)->ops->\
00130             get_base_impl(particle, env))
00131 
00132 #define XML_SCHEMA_PARTICLE_GET_MAX_OCCURS(particle, env) \
00133       (((xml_schema_particle_t *) particle)->ops->\
00134             get_max_occurs(particle, env))
00135 
00136 #define XML_SCHEMA_PARTICLE_SET_MAX_OCCURS(particle, env, max_occurs) \
00137       (((xml_schema_particle_t *) particle)->ops->\
00138             set_max_occurs(particle, env, max_occurs))
00139 
00140 #define XML_SCHEMA_PARTICLE_GET_MIN_OCCURS(particle, env) \
00141       (((xml_schema_particle_t *) particle)->ops->\
00142             get_min_occurs(particle, env))
00143 
00144 #define XML_SCHEMA_PARTICLE_SET_MIN_OCCURS(particle, env, min_occurs) \
00145       (((xml_schema_particle_t *) particle)->ops->\
00146             set_min_occurs(particle, env, min_occurs))
00147 
00149 #ifdef __cplusplus
00150 }
00151 #endif
00152 #endif /* XML_SCHEMA_PARTICLE_H */

Generated on Fri Jun 16 18:02:32 2006 for Axis2/C by  doxygen 1.4.2