woden_element_decl.h

Go to the documentation of this file.
00001 /*
00002  * Licensed to the Apache Software Foundation (ASF) under one or more
00003  * contributor license agreements.  See the NOTICE file distributed with
00004  * this work for additional information regarding copyright ownership.
00005  * The ASF licenses this file to You under the Apache License, Version 2.0
00006  * (the "License"); you may not use this file except in compliance with
00007  * the License.  You may obtain a copy of the License at
00008  *
00009  *      http://www.apache.org/licenses/LICENSE-2.0
00010  *
00011  * Unless required by applicable law or agreed to in writing, software
00012  * distributed under the License is distributed on an "AS IS" BASIS,
00013  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00014  * See the License for the specific language governing permissions and
00015  * limitations under the License.
00016  */
00017 
00018 #ifndef WODEN_ELEMENT_DECL_H
00019 #define WODEN_ELEMENT_DECL_H
00020 
00037 #include <axis2_allocator.h>
00038 #include <axis2_env.h>
00039 #include <axis2_error.h>
00040 #include <axis2_string.h>
00041 #include <axis2_utils.h>
00042 #include <axis2_hash.h>
00043 #include <axis2_qname.h>
00044 #include <axis2_uri.h>
00045 #include <axis2_array_list.h>
00046 #include <axis2_generic_obj.h>
00047 #include <woden.h>
00048 
00049 #ifdef __cplusplus
00050 extern "C"
00051 {
00052 #endif
00053 
00054 typedef struct woden_element_decl woden_element_decl_t;
00055 typedef struct woden_element_decl_ops woden_element_decl_ops_t;
00056 struct woden_ext_element;
00057 
00063 struct woden_element_decl_ops
00064 {
00069     axis2_status_t (AXIS2_CALL *
00070     free) (
00071             void *
00072             element_decl,
00073             const axis2_env_t *env);
00074     
00075     axis2_status_t (AXIS2_CALL *
00076     to_element_decl_free) (
00077             void *
00078             element_decl,
00079             const axis2_env_t *env);
00080     
00081     axis2_hash_t *(AXIS2_CALL *
00082     super_objs) (
00083             void *
00084             element_decl,
00085             const axis2_env_t *env);
00086     
00087     woden_obj_types_t (AXIS2_CALL *
00088     type) (
00089             void *element_decl,
00090             const axis2_env_t *env);
00091      
00092     /* ************************************************************
00093      *  Element Declaration interface methods (the WSDL Component model)
00094      * ************************************************************/
00100     axis2_qname_t *(AXIS2_CALL *
00101     get_qname) (
00102             void *decl,
00103             const axis2_env_t *env); 
00104 
00112     axis2_uri_t *(AXIS2_CALL *
00113     get_system) (
00114             void *decl,
00115             const axis2_env_t *env); 
00116 
00133     axis2_char_t *(AXIS2_CALL *
00134     get_content_model) (
00135             void *decl,
00136             const axis2_env_t *env); 
00137 
00146     axis2_generic_obj_t *(AXIS2_CALL *
00147     get_content) (
00148             void *decl,
00149             const axis2_env_t *env); 
00150 
00151     /* ************************************************************
00152      *  Non-API implementation methods
00153      * ************************************************************/
00154 
00155     axis2_status_t (AXIS2_CALL *
00156     set_qname) (
00157             void *decl,
00158             const axis2_env_t *env,
00159             axis2_qname_t *qname); 
00160 
00161     axis2_status_t (AXIS2_CALL *
00162     set_system) (
00163             void *decl,
00164             const axis2_env_t *env,
00165             axis2_uri_t *type_system_uri); 
00166 
00167     axis2_status_t (AXIS2_CALL *
00168     set_content_model) (
00169             void *decl,
00170             const axis2_env_t *env,
00171             axis2_char_t *content_model); 
00172 
00173     axis2_status_t (AXIS2_CALL *
00174     set_content) (
00175             void *decl,
00176             const axis2_env_t *env,
00177             axis2_generic_obj_t *element_content);
00178 
00179 
00180 };
00181 
00182 struct woden_element_decl
00183 {
00184     woden_element_decl_ops_t *ops;
00185 };
00186 
00187 AXIS2_EXTERN woden_element_decl_t * AXIS2_CALL
00188 woden_element_decl_create(const axis2_env_t *env);
00189 
00194 AXIS2_EXTERN axis2_status_t AXIS2_CALL
00195 woden_element_decl_resolve_methods(
00196         woden_element_decl_t *decl,
00197         const axis2_env_t *env,
00198         woden_element_decl_t *decl_impl,
00199         axis2_hash_t *methods);
00200 
00201 #define WODEN_ELEMENT_DECL_FREE(decl, env) \
00202       (((woden_element_decl_t *) decl)->ops->\
00203          free (decl, env))
00204 
00205 #define WODEN_ELEMENT_DECL_TO_ELEMENT_DECL_FREE(decl, \
00206         env) \
00207       (((woden_element_decl_t *) decl)->ops->\
00208          to_element_decl_free (decl, env))
00209 
00210 #define WODEN_ELEMENT_DECL_SUPER_OBJS(decl, env) \
00211       (((woden_element_decl_t *) decl)->ops->\
00212          super_objs (decl, env))
00213 
00214 #define WODEN_ELEMENT_DECL_TYPE(decl, env) \
00215       (((woden_element_decl_t *) decl)->ops->\
00216          type (decl, env))
00217 
00218 #define WODEN_ELEMENT_DECL_GET_QNAME(decl, env) \
00219       (((woden_element_decl_t *) decl)->ops->\
00220          get_qname(decl, env))
00221 
00222 #define WODEN_ELEMENT_DECL_GET_SYSTEM(decl, env) \
00223       (((woden_element_decl_t *) decl)->ops->\
00224          get_system(decl, env))
00225 
00226 #define WODEN_ELEMENT_DECL_GET_CONTENT_MODEL(decl, env) \
00227       (((woden_element_decl_t *) decl)->ops->\
00228          get_content_model(decl, env))
00229 
00230 #define WODEN_ELEMENT_DECL_GET_CONTENT(decl, env) \
00231       (((woden_element_decl_t *) decl)->ops->\
00232          get_content(decl, env))
00233 
00234 #define WODEN_ELEMENT_DECL_SET_QNAME(decl, env, qname) \
00235       (((woden_element_decl_t *) decl)->ops->\
00236          set_qname(decl, env, qname))
00237 
00238 #define WODEN_ELEMENT_DECL_SET_SYSTEM(decl, env, type_system_uri) \
00239       (((woden_element_decl_t *) decl)->ops->\
00240          set_system(decl, env, type_system_uri))
00241 
00242 #define WODEN_ELEMENT_DECL_SET_CONTENT_MODEL(decl, env, content_model) \
00243       (((woden_element_decl_t *) decl)->ops->\
00244          set_content_model(decl, env, content_model))
00245 
00246 #define WODEN_ELEMENT_DECL_SET_CONTENT(decl, env, element_content) \
00247       (((woden_element_decl_t *) decl)->ops->\
00248          set_content(decl, env, element_content))
00249 
00250 
00252 #ifdef __cplusplus
00253 }
00254 #endif
00255 #endif /* WODEN_ELEMENT_DECL_H */

Generated on Wed Dec 20 20:14:10 2006 for Axis2/C by  doxygen 1.5.1