You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by da...@apache.org on 2006/07/06 08:02:31 UTC

svn commit: r419452 [32/46] - in /webservices/axis2/trunk/c/woden: ./ include/ samples/ samples/wsdl10/ src/ src/builder/ src/builder/wsdl10/ src/schema/ src/types/ src/util/ src/wsdl/ src/wsdl/enumeration/ src/wsdl10/ src/wsdl10/enumeration/ src/wsdl1...

Added: webservices/axis2/trunk/c/woden/src/wsdl10/msg_ref.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/woden/src/wsdl10/msg_ref.c?rev=419452&view=auto
==============================================================================
--- webservices/axis2/trunk/c/woden/src/wsdl10/msg_ref.c (added)
+++ webservices/axis2/trunk/c/woden/src/wsdl10/msg_ref.c Wed Jul  5 23:02:19 2006
@@ -0,0 +1,826 @@
+/*
+ * Copyright 2004,2005 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <woden_wsdl_obj.h>
+#include <woden_wsdl10_msg_ref.h>
+#include <woden_wsdl10_part.h>
+#include <woden_wsdl10_part_element.h>
+#include <woden_nested_configurable.h>
+#include <woden_ext_element.h>
+#include <woden_component_exts.h>
+#include <woden_xml_attr.h>
+#include <woden_documentation_element.h>
+#include <xml_schema_element.h>
+
+typedef struct woden_wsdl10_msg_ref_impl woden_wsdl10_msg_ref_impl_t;
+
+/** 
+ * @brief Interface Operation Struct Impl
+ *   Axis2 Interface Operation  
+ */ 
+struct woden_wsdl10_msg_ref_impl
+{
+    woden_wsdl10_msg_ref_t msg_ref;
+    woden_nested_configurable_t *nested_configurable;
+    woden_obj_types_t obj_type;
+    axis2_hash_t *super;
+    axis2_hash_t *methods;
+
+    axis2_qname_t *f_qname;
+    void *f_part;
+};
+
+#define INTF_TO_IMPL(msg_ref) ((woden_wsdl10_msg_ref_impl_t *) msg_ref)
+
+axis2_status_t AXIS2_CALL 
+woden_wsdl10_msg_ref_free(
+        void *msg_ref,
+        const axis2_env_t *env);
+
+axis2_hash_t *AXIS2_CALL 
+woden_wsdl10_msg_ref_super_objs(
+        void *msg_ref,
+        const axis2_env_t *env);
+
+woden_obj_types_t AXIS2_CALL 
+woden_wsdl10_msg_ref_type(
+        void *msg_ref,
+        const axis2_env_t *env);
+
+woden_nested_configurable_t *AXIS2_CALL
+woden_wsdl10_msg_ref_get_base_impl(
+        void *msg_ref,
+        const axis2_env_t *env);
+
+/* ************************************************************
+ *  Interface Operation  methods (the WSDL Component model)
+ * ************************************************************/
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_msg_ref_get_qname(
+        void *msg_ref,
+        const axis2_env_t *env);
+
+void *AXIS2_CALL
+woden_wsdl10_msg_ref_to_element(
+        void *msg_ref,
+        const axis2_env_t *env);
+
+/* ************************************************************
+ *  Interface Operation Element methods (the XML Element model)
+ * ************************************************************/
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_msg_ref_set_qname(
+        void *msg_ref,
+        const axis2_env_t *env,
+        axis2_qname_t *qname);
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_msg_ref_set_part(
+        void *msg_ref,
+        const axis2_env_t *env,
+        void *part);
+
+void *AXIS2_CALL
+woden_wsdl10_msg_ref_get_part(
+        void *msg_ref,
+        const axis2_env_t *env);
+
+static woden_wsdl10_msg_ref_t *
+create(const axis2_env_t *env);
+
+static axis2_status_t
+woden_wsdl10_msg_ref_free_ops(
+        void *msg_ref,
+        const axis2_env_t *env);
+
+/************************Woden C Internal Methods******************************/
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_msg_ref_element(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.msg_ref_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_wsdl10_msg_ref_element_ops_t));
+    woden_wsdl10_msg_ref_element_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            msg_ref_element), env, msg_ref_impl->methods);
+    return msg_ref;
+}
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_nested_configurable(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.nested_configurable.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_nested_configurable_ops_t));
+    woden_nested_configurable_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            nested_configurable), env, msg_ref_impl->nested_configurable, 
+            msg_ref_impl->methods);
+    return msg_ref;
+}
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_nested_component(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.nested_configurable.base.nested_component.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_nested_component_ops_t));
+    woden_nested_component_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            nested_configurable.base.nested_component), env, msg_ref_impl->methods);
+    return msg_ref;
+}
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_configurable(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+    void *configurable = NULL;
+    
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.nested_configurable.base.configurable.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_configurable_ops_t));
+    configurable = WODEN_NESTED_CONFIGURABLE_GET_BASE_IMPL(
+            msg_ref_impl->nested_configurable, env);
+    woden_configurable_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            nested_configurable.base.configurable), env, configurable, msg_ref_impl->methods);
+    return msg_ref;
+}
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_nested_element(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.nested_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_nested_element_ops_t));
+    woden_nested_element_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            msg_ref_element.base.nested_element), env, msg_ref_impl->methods);
+    return msg_ref;
+}
+
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_configurable_element(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.configurable_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_configurable_element_ops_t));
+    woden_configurable_element_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            msg_ref_element.base.configurable_element), env, msg_ref_impl->methods);
+    return msg_ref;
+}
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_documentable_element(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.documentable_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_documentable_element_ops_t));
+    woden_documentable_element_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            msg_ref_element.base.documentable_element), env, 
+            msg_ref_impl->methods);
+    return msg_ref;
+}
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_documentable(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.nested_configurable.base.
+        configurable.base.documentable.ops = AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_documentable_ops_t));
+    woden_documentable_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            nested_configurable.base.configurable.base.documentable), env, NULL,
+            msg_ref_impl->methods);
+    return msg_ref;
+}
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_attr_extensible(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.documentable_element.
+        wsdl_element.base.attr_extensible.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_attr_extensible_ops_t));
+    woden_attr_extensible_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            msg_ref_element.base.documentable_element.wsdl_element.base.
+            attr_extensible), env, NULL, msg_ref_impl->methods);
+    return msg_ref;
+}
+
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_to_element_extensible(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!msg_ref)
+    {
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+    }
+    else
+        msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) msg_ref;
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.documentable_element.
+        wsdl_element.base.element_extensible.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_element_extensible_ops_t));
+    woden_element_extensible_resolve_methods(&(msg_ref_impl->msg_ref.base.
+            msg_ref_element.base.documentable_element.wsdl_element.base.
+            element_extensible), env, NULL, msg_ref_impl->methods);
+    return msg_ref;
+}
+
+
+/************************End of Woden C Internal Methods***********************/
+static woden_wsdl10_msg_ref_t *
+create(const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    msg_ref_impl = AXIS2_MALLOC(env->allocator, 
+                    sizeof(woden_wsdl10_msg_ref_impl_t));
+
+    msg_ref_impl->obj_type= WODEN_WSDL10_MSG_REF;
+    msg_ref_impl->super = NULL;
+    msg_ref_impl->methods = NULL;
+    msg_ref_impl->f_qname = NULL;
+    msg_ref_impl->f_part = NULL;
+    
+    msg_ref_impl->msg_ref.base.msg_ref_element.ops = NULL;
+    msg_ref_impl->msg_ref.base.nested_configurable.ops = NULL;
+    msg_ref_impl->msg_ref.base.nested_configurable.base.
+        nested_component.ops = NULL;
+    msg_ref_impl->msg_ref.base.nested_configurable.base.configurable.ops = 
+            NULL;
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.
+        nested_element.ops = NULL;
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.
+        configurable_element.ops = NULL;
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.
+        documentable_element.ops = NULL;
+    msg_ref_impl->msg_ref.base.nested_configurable.base.configurable.base.
+        documentable.ops = NULL;
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.
+        documentable_element.wsdl_element.base.attr_extensible.ops = NULL;
+    msg_ref_impl->msg_ref.base.msg_ref_element.base.
+        documentable_element.wsdl_element.base.element_extensible.ops = NULL;
+ 
+    msg_ref_impl->msg_ref.ops = AXIS2_MALLOC(env->allocator, 
+            sizeof(woden_wsdl10_msg_ref_ops_t));
+
+    msg_ref_impl->msg_ref.ops->free = woden_wsdl10_msg_ref_free;
+    msg_ref_impl->msg_ref.ops->super_objs = woden_wsdl10_msg_ref_super_objs;
+    msg_ref_impl->msg_ref.ops->type = woden_wsdl10_msg_ref_type;
+    msg_ref_impl->msg_ref.ops->get_base_impl = woden_wsdl10_msg_ref_get_base_impl;
+    
+    msg_ref_impl->msg_ref.ops->get_qname = 
+        woden_wsdl10_msg_ref_get_qname;
+    msg_ref_impl->msg_ref.ops->to_element = 
+        woden_wsdl10_msg_ref_to_element;
+ 
+    msg_ref_impl->methods = axis2_hash_make(env);
+    if(!msg_ref_impl->methods) 
+    {
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        return NULL;
+    }
+    axis2_hash_set(msg_ref_impl->methods, "free", AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_msg_ref_free);
+    axis2_hash_set(msg_ref_impl->methods, "super_objs", 
+            AXIS2_HASH_KEY_STRING, woden_wsdl10_msg_ref_super_objs);
+    axis2_hash_set(msg_ref_impl->methods, "type", 
+            AXIS2_HASH_KEY_STRING, woden_wsdl10_msg_ref_type);
+
+    axis2_hash_set(msg_ref_impl->methods, "get_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_msg_ref_get_qname);
+    axis2_hash_set(msg_ref_impl->methods, "to_element", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_msg_ref_to_element);
+    axis2_hash_set(msg_ref_impl->methods, "set_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_msg_ref_set_qname);
+    axis2_hash_set(msg_ref_impl->methods, "set_part", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_msg_ref_set_part);
+    axis2_hash_set(msg_ref_impl->methods, "get_part", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_msg_ref_get_part);
+
+    return &(msg_ref_impl->msg_ref);
+}
+
+AXIS2_EXTERN woden_wsdl10_msg_ref_t * AXIS2_CALL
+woden_wsdl10_msg_ref_create(const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+    void *configurable = NULL;
+    
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    msg_ref_impl = (woden_wsdl10_msg_ref_impl_t *) create(env);
+
+    msg_ref_impl->nested_configurable = woden_nested_configurable_create(env);
+
+    msg_ref_impl->super = axis2_hash_make(env);
+    if(!msg_ref_impl->super) 
+    {
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        return NULL;
+    }
+    axis2_hash_set(msg_ref_impl->super, "WODEN_WSDL10_MSG_REF", 
+            AXIS2_HASH_KEY_STRING, 
+            &(msg_ref_impl->msg_ref));
+    axis2_hash_set(msg_ref_impl->super, "WODEN_NESTED_CONFIGURABLE", 
+            AXIS2_HASH_KEY_STRING, 
+            msg_ref_impl->nested_configurable);
+    configurable = WODEN_NESTED_CONFIGURABLE_GET_BASE_IMPL(
+            msg_ref_impl->nested_configurable, env);
+    axis2_hash_set(msg_ref_impl->super, "WODEN_CONFIGURABLE", 
+            AXIS2_HASH_KEY_STRING, configurable);
+ 
+    return &(msg_ref_impl->msg_ref);
+}
+
+static axis2_status_t
+woden_wsdl10_msg_ref_free_ops(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    msg_ref_impl = INTF_TO_IMPL(msg_ref);
+
+    if(msg_ref_impl->msg_ref.base.msg_ref_element.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                msg_ref_element.ops);
+        msg_ref_impl->msg_ref.base.msg_ref_element.ops = NULL;
+    }
+
+    if(msg_ref_impl->msg_ref.base.nested_configurable.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                nested_configurable.ops);
+        msg_ref_impl->msg_ref.base.nested_configurable.ops = 
+            NULL;
+    }
+ 
+    if(msg_ref_impl->msg_ref.base.nested_configurable.base.
+            nested_component.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                nested_configurable.base.nested_component.ops);
+        msg_ref_impl->msg_ref.base.nested_configurable.base.
+            nested_component.ops = NULL;
+    }
+    
+    if(msg_ref_impl->msg_ref.base.nested_configurable.base.
+            configurable.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                nested_configurable.base.configurable.ops);
+        msg_ref_impl->msg_ref.base.nested_configurable.base.
+            configurable.ops = NULL;
+    }
+    
+    if(msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            nested_element.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                msg_ref_element.base.nested_element.ops);
+        msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            nested_element.ops = NULL;
+    }
+ 
+    if(msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            configurable_element.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                msg_ref_element.base.configurable_element.ops);
+        msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            configurable_element.ops = NULL;
+    }
+    
+    if(msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            documentable_element.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                msg_ref_element.base.documentable_element.ops);
+        msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            documentable_element.ops = NULL;
+    }
+     
+    if(msg_ref_impl->msg_ref.base.nested_configurable.base.
+            configurable.base.documentable.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                nested_configurable.base.configurable.base.documentable.ops);
+        msg_ref_impl->msg_ref.base.nested_configurable.base.
+            configurable.base.documentable.ops = NULL;
+    }
+      
+    if(msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            documentable_element.wsdl_element.base.attr_extensible.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                msg_ref_element.base.documentable_element.wsdl_element.base.
+                attr_extensible.ops);
+        msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            documentable_element.wsdl_element.base.attr_extensible.ops = NULL;
+    }
+      
+    if(msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            documentable_element.wsdl_element.base.element_extensible.ops)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl->msg_ref.base.
+                msg_ref_element.base.documentable_element.wsdl_element.base.
+                element_extensible.ops);
+        msg_ref_impl->msg_ref.base.msg_ref_element.base.
+            documentable_element.wsdl_element.base.element_extensible.ops = NULL;
+    }
+  
+
+    return AXIS2_SUCCESS;
+}
+
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_msg_ref_free(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    msg_ref_impl = INTF_TO_IMPL(msg_ref);
+
+    if(msg_ref_impl->f_qname)
+    {
+        AXIS2_QNAME_FREE(msg_ref_impl->f_qname, env);
+        msg_ref_impl->f_qname = NULL;
+    }
+
+    if(msg_ref_impl->f_part)
+    {
+        WODEN_WSDL10_PART_FREE(msg_ref_impl->f_part, env);
+        msg_ref_impl->f_part = NULL;
+    }
+
+    if(msg_ref_impl->super)
+    {
+        axis2_hash_free(msg_ref_impl->super, env);
+        msg_ref_impl->super = NULL;
+    }
+    
+    if(msg_ref_impl->methods)
+    {
+        axis2_hash_free(msg_ref_impl->methods, env);
+        msg_ref_impl->methods = NULL;
+    }
+
+    if(msg_ref_impl->nested_configurable)
+    {
+        WODEN_NESTED_CONFIGURABLE_FREE(msg_ref_impl->
+                nested_configurable, env);
+        msg_ref_impl->nested_configurable = NULL;
+    }
+
+    woden_wsdl10_msg_ref_free_ops(msg_ref, env);
+
+    if((&(msg_ref_impl->msg_ref))->ops)
+    {
+        AXIS2_FREE(env->allocator, (&(msg_ref_impl->msg_ref))->ops);
+        (&(msg_ref_impl->msg_ref))->ops = NULL;
+    }
+    
+    if(msg_ref_impl)
+    {
+        AXIS2_FREE(env->allocator, msg_ref_impl);
+        msg_ref_impl = NULL;
+    }
+    return AXIS2_SUCCESS;
+}
+
+axis2_hash_t *AXIS2_CALL
+woden_wsdl10_msg_ref_super_objs(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    msg_ref_impl = INTF_TO_IMPL(msg_ref);
+
+    return msg_ref_impl->super;
+}
+
+woden_obj_types_t AXIS2_CALL
+woden_wsdl10_msg_ref_type(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    msg_ref_impl = INTF_TO_IMPL(msg_ref);
+
+    return msg_ref_impl->obj_type;
+}
+
+woden_nested_configurable_t *AXIS2_CALL
+woden_wsdl10_msg_ref_get_base_impl(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    msg_ref_impl = INTF_TO_IMPL(msg_ref);
+
+    return msg_ref_impl->nested_configurable;
+}
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_msg_ref_resolve_methods(
+        woden_wsdl10_msg_ref_t *msg_ref,
+        const axis2_env_t *env,
+        woden_wsdl10_msg_ref_t *msg_ref_impl,
+        axis2_hash_t *methods)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl_l = NULL;
+    
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    AXIS2_PARAM_CHECK(env->error, methods, AXIS2_FAILURE);
+    msg_ref_impl_l = INTF_TO_IMPL(msg_ref_impl);
+    
+    msg_ref->ops->free = axis2_hash_get(methods, "free", 
+            AXIS2_HASH_KEY_STRING);
+    msg_ref->ops->super_objs = axis2_hash_get(methods, "super_objs", 
+            AXIS2_HASH_KEY_STRING);
+    msg_ref->ops->type = axis2_hash_get(methods, "type", 
+            AXIS2_HASH_KEY_STRING);
+    
+    msg_ref->ops->get_qname = axis2_hash_get(methods, 
+            "get_qname", AXIS2_HASH_KEY_STRING);
+    if(!msg_ref->ops->get_qname && msg_ref_impl_l)
+            msg_ref->ops->get_qname = 
+            msg_ref_impl_l->msg_ref.ops->get_qname;
+    
+    msg_ref->ops->to_element = axis2_hash_get(methods, 
+            "to_element", AXIS2_HASH_KEY_STRING);
+    if(!msg_ref->ops->to_element && msg_ref_impl_l)
+            msg_ref->ops->to_element = 
+            msg_ref_impl_l->msg_ref.ops->to_element;
+   
+    return AXIS2_SUCCESS;
+}
+
+/* ************************************************************
+ *  Interface Operation  methods (the WSDL Component model)
+ * ************************************************************/
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_msg_ref_get_qname(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_MSG_REF_SUPER_OBJS(msg_ref, env);
+    msg_ref_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_MSG_REF", AXIS2_HASH_KEY_STRING));
+
+    return msg_ref_impl->f_qname;
+}
+
+void *AXIS2_CALL
+woden_wsdl10_msg_ref_to_element(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_MSG_REF_SUPER_OBJS(msg_ref, env);
+    msg_ref_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_MSG_REF", AXIS2_HASH_KEY_STRING));
+    
+    return &(msg_ref_impl->msg_ref);
+}
+
+/* ************************************************************
+ *  Interface Operation Element methods (the XML Element model)
+ * ************************************************************/
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_msg_ref_set_qname(
+        void *msg_ref,
+        const axis2_env_t *env,
+        axis2_qname_t *qname)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    AXIS2_PARAM_CHECK(env->error, qname, AXIS2_FAILURE);
+    super = WODEN_WSDL10_MSG_REF_SUPER_OBJS(msg_ref, env);
+    msg_ref_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_MSG_REF", AXIS2_HASH_KEY_STRING));
+
+    if(msg_ref_impl->f_qname)
+    {
+        AXIS2_QNAME_FREE(msg_ref_impl->f_qname, env);
+        msg_ref_impl->f_qname = NULL;
+    }
+    msg_ref_impl->f_qname = AXIS2_QNAME_CLONE(qname, env);
+
+    return AXIS2_SUCCESS;
+}
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_msg_ref_set_part(
+        void *msg_ref,
+        const axis2_env_t *env,
+        void *part)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    AXIS2_PARAM_CHECK(env->error, part, AXIS2_FAILURE);
+    super = WODEN_WSDL10_MSG_REF_SUPER_OBJS(msg_ref, env);
+    msg_ref_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_MSG_REF", AXIS2_HASH_KEY_STRING));
+
+    if(!msg_ref_impl->f_part)
+    {
+        /* TODO */
+    }
+    msg_ref_impl->f_part = part;
+
+
+    return AXIS2_SUCCESS;
+}
+
+void *AXIS2_CALL
+woden_wsdl10_msg_ref_get_part(
+        void *msg_ref,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_msg_ref_impl_t *msg_ref_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_MSG_REF_SUPER_OBJS(msg_ref, env);
+    msg_ref_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_MSG_REF", AXIS2_HASH_KEY_STRING));
+
+    return msg_ref_impl->f_part;
+}
+

Added: webservices/axis2/trunk/c/woden/src/wsdl10/part.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/woden/src/wsdl10/part.c?rev=419452&view=auto
==============================================================================
--- webservices/axis2/trunk/c/woden/src/wsdl10/part.c (added)
+++ webservices/axis2/trunk/c/woden/src/wsdl10/part.c Wed Jul  5 23:02:19 2006
@@ -0,0 +1,958 @@
+/*
+ * Copyright 2004,2005 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <woden_wsdl_obj.h>
+#include <woden_wsdl10_part.h>
+#include <woden_types.h>
+#include <woden_nested_configurable.h>
+#include <woden_ext_element.h>
+#include <woden_component_exts.h>
+#include <woden_msg_label.h>
+#include <woden_xml_attr.h>
+#include <woden_documentation_element.h>
+#include <xml_schema_element.h>
+#include <woden_element_decl.h>
+
+typedef struct woden_wsdl10_part_impl woden_wsdl10_part_impl_t;
+
+/** 
+ * @brief Interface Message Reference Struct Impl
+ *   Axis2 Interface Message Reference  
+ */ 
+struct woden_wsdl10_part_impl
+{
+    woden_wsdl10_part_t part;
+    woden_nested_configurable_t *nested_configurable;
+    woden_obj_types_t obj_type;
+    axis2_hash_t *super;
+    axis2_hash_t *methods;
+
+    axis2_qname_t *f_qname;
+    void *f_element_decl;
+    axis2_qname_t *f_element_qname;
+    void *f_types;
+};
+
+#define INTF_TO_IMPL(part) ((woden_wsdl10_part_impl_t *) part)
+
+axis2_status_t AXIS2_CALL 
+woden_wsdl10_part_free(
+        void *part,
+        const axis2_env_t *env);
+
+axis2_hash_t *AXIS2_CALL 
+woden_wsdl10_part_super_objs(
+        void *part,
+        const axis2_env_t *env);
+
+woden_obj_types_t AXIS2_CALL 
+woden_wsdl10_part_type(
+        void *part,
+        const axis2_env_t *env);
+
+woden_nested_configurable_t *AXIS2_CALL
+woden_wsdl10_part_get_base_impl(
+        void *part,
+        const axis2_env_t *env);
+
+/* ************************************************************
+ *  Interface Message Reference  methods (the WSDL Component model)
+ * ************************************************************/
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_part_get_qname(
+        void *part,
+        const axis2_env_t *env);
+
+void *AXIS2_CALL
+woden_wsdl10_part_get_element_declaration(
+        void *part,
+        const axis2_env_t *env);
+
+void *AXIS2_CALL
+woden_wsdl10_part_to_element(
+        void *part,
+        const axis2_env_t *env);
+
+/* ************************************************************
+ *  Interface Message Reference Element methods (the XML Element model)
+ * ************************************************************/
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_set_qname(
+        void *part,
+        const axis2_env_t *env,
+        axis2_qname_t *qname);
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_set_element_qname(
+        void *part,
+        const axis2_env_t *env,
+        axis2_qname_t *element);
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_part_get_element_qname(
+        void *part,
+        const axis2_env_t *env);
+
+void *AXIS2_CALL
+woden_wsdl10_part_get_element(
+        void *part,
+        const axis2_env_t *env);
+
+/* ************************************************************
+ *  Non-API implementation methods
+ * ************************************************************/
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_set_element_declaration(
+        void *part,
+        const axis2_env_t *env,
+        void *element);
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_set_types(
+        void *part,
+        const axis2_env_t *env,
+        void *types);
+
+
+static woden_wsdl10_part_t *
+create(const axis2_env_t *env);
+
+static axis2_status_t
+woden_wsdl10_part_free_ops(
+        void *part,
+        const axis2_env_t *env);
+
+/************************Woden C Internal Methods******************************/
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_to_part_element(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!part)
+    {
+        part_impl = (woden_wsdl10_part_impl_t *) create(env);
+    }
+    else
+        part_impl = (woden_wsdl10_part_impl_t *) part;
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    part_impl->part.base.part_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_wsdl10_part_element_ops_t));
+    woden_wsdl10_part_element_resolve_methods(&(part_impl->part.base.
+            part_element), env, part_impl->methods);
+    return part;
+}
+
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_to_nested_configurable(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!part)
+    {
+        part_impl = (woden_wsdl10_part_impl_t *) create(env);
+    }
+    else
+        part_impl = (woden_wsdl10_part_impl_t *) part;
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    part_impl->part.base.nested_configurable.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_nested_configurable_ops_t));
+    woden_nested_configurable_resolve_methods(&(part_impl->part.base.
+            nested_configurable), env, part_impl->nested_configurable, 
+            part_impl->methods);
+    return part;
+}
+
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_to_configurable(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    void *configurable = NULL;
+    
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!part)
+    {
+        part_impl = (woden_wsdl10_part_impl_t *) create(env);
+    }
+    else
+        part_impl = (woden_wsdl10_part_impl_t *) part;
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    part_impl->part.base.nested_configurable.base.configurable.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_configurable_ops_t));
+    configurable = WODEN_NESTED_CONFIGURABLE_GET_BASE_IMPL(
+            part_impl->nested_configurable, env);
+    woden_configurable_resolve_methods(&(part_impl->part.base.
+            nested_configurable.base.configurable), env, configurable, part_impl->methods);
+    return part;
+}
+
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_to_nested_element(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!part)
+    {
+        part_impl = (woden_wsdl10_part_impl_t *) create(env);
+    }
+    else
+        part_impl = (woden_wsdl10_part_impl_t *) part;
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    part_impl->part.base.part_element.base.nested_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_nested_element_ops_t));
+    woden_nested_element_resolve_methods(&(part_impl->part.base.
+            part_element.base.nested_element), env, part_impl->methods);
+    return part;
+}
+
+
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_to_configurable_element(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!part)
+    {
+        part_impl = (woden_wsdl10_part_impl_t *) create(env);
+    }
+    else
+        part_impl = (woden_wsdl10_part_impl_t *) part;
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    part_impl->part.base.part_element.base.configurable_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_configurable_element_ops_t));
+    woden_configurable_element_resolve_methods(&(part_impl->part.base.
+            part_element.base.configurable_element), env, part_impl->methods);
+    return part;
+}
+
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_to_documentable_element(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!part)
+    {
+        part_impl = (woden_wsdl10_part_impl_t *) create(env);
+    }
+    else
+        part_impl = (woden_wsdl10_part_impl_t *) part;
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    part_impl->part.base.part_element.base.documentable_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_documentable_element_ops_t));
+    woden_documentable_element_resolve_methods(&(part_impl->part.base.
+            part_element.base.documentable_element), env, 
+            part_impl->methods);
+    return part;
+}
+
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_to_documentable(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!part)
+    {
+        part_impl = (woden_wsdl10_part_impl_t *) create(env);
+    }
+    else
+        part_impl = (woden_wsdl10_part_impl_t *) part;
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    part_impl->part.base.nested_configurable.base.
+        configurable.base.documentable.ops = AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_documentable_ops_t));
+    woden_documentable_resolve_methods(&(part_impl->part.base.
+            nested_configurable.base.configurable.base.documentable), env, NULL,
+            part_impl->methods);
+    return part;
+}
+
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_to_attr_extensible(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!part)
+    {
+        part_impl = (woden_wsdl10_part_impl_t *) create(env);
+    }
+    else
+        part_impl = (woden_wsdl10_part_impl_t *) part;
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    part_impl->part.base.part_element.base.documentable_element.
+        wsdl_element.base.attr_extensible.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_attr_extensible_ops_t));
+    woden_attr_extensible_resolve_methods(&(part_impl->part.base.
+            part_element.base.documentable_element.wsdl_element.base.
+            attr_extensible), env, NULL, part_impl->methods);
+    return part;
+}
+
+
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_to_element_extensible(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    if(!part)
+    {
+        part_impl = (woden_wsdl10_part_impl_t *) create(env);
+    }
+    else
+        part_impl = (woden_wsdl10_part_impl_t *) part;
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    part_impl->part.base.part_element.base.documentable_element.
+        wsdl_element.base.element_extensible.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_element_extensible_ops_t));
+    woden_element_extensible_resolve_methods(&(part_impl->part.base.
+            part_element.base.documentable_element.wsdl_element.base.
+            element_extensible), env, NULL, part_impl->methods);
+    return part;
+}
+
+
+/************************End of Woden C Internal Methods***********************/
+static woden_wsdl10_part_t *
+create(const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    part_impl = AXIS2_MALLOC(env->allocator, 
+                    sizeof(woden_wsdl10_part_impl_t));
+
+    part_impl->obj_type= WODEN_WSDL10_PART;
+    part_impl->super = NULL;
+    part_impl->methods = NULL;
+    part_impl->f_qname = NULL;
+    part_impl->f_element_decl = NULL;
+    part_impl->f_types = NULL;
+    part_impl->f_element_qname = NULL;
+    
+    part_impl->part.base.part_element.ops = NULL;
+    part_impl->part.base.nested_configurable.ops = NULL;
+    part_impl->part.base.nested_configurable.base.configurable.ops = 
+            NULL;
+    part_impl->part.base.part_element.base.
+        nested_element.ops = NULL;
+    part_impl->part.base.part_element.base.
+        configurable_element.ops = NULL;
+    part_impl->part.base.part_element.base.
+        documentable_element.ops = NULL;
+    part_impl->part.base.nested_configurable.base.configurable.base.
+        documentable.ops = NULL;
+    part_impl->part.base.part_element.base.
+        documentable_element.wsdl_element.base.attr_extensible.ops = NULL;
+    part_impl->part.base.part_element.base.
+        documentable_element.wsdl_element.base.element_extensible.ops = NULL;
+
+
+    part_impl->part.ops = AXIS2_MALLOC(env->allocator, 
+            sizeof(woden_wsdl10_part_ops_t));
+
+    part_impl->part.ops->free = woden_wsdl10_part_free;
+    part_impl->part.ops->super_objs = woden_wsdl10_part_super_objs;
+    part_impl->part.ops->type = woden_wsdl10_part_type;
+    part_impl->part.ops->get_base_impl = woden_wsdl10_part_get_base_impl;
+    
+    part_impl->part.ops->get_qname = 
+        woden_wsdl10_part_get_qname;
+    part_impl->part.ops->get_element_declaration = 
+        woden_wsdl10_part_get_element_declaration;
+    part_impl->part.ops->to_element = 
+        woden_wsdl10_part_to_element;
+    part_impl->part.ops->set_element_declaration = 
+        woden_wsdl10_part_set_element_declaration;
+    part_impl->part.ops->set_types = 
+        woden_wsdl10_part_set_types;
+ 
+    part_impl->methods = axis2_hash_make(env);
+    if(!part_impl->methods) 
+    {
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        return NULL;
+    }
+    axis2_hash_set(part_impl->methods, "free", AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_free);
+    axis2_hash_set(part_impl->methods, "super_objs", 
+            AXIS2_HASH_KEY_STRING, woden_wsdl10_part_super_objs);
+    axis2_hash_set(part_impl->methods, "type", 
+            AXIS2_HASH_KEY_STRING, woden_wsdl10_part_type);
+
+    axis2_hash_set(part_impl->methods, "get_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_get_qname);
+    axis2_hash_set(part_impl->methods, "get_element_declaration", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_get_element_declaration);
+    axis2_hash_set(part_impl->methods, "to_element", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_to_element);
+    axis2_hash_set(part_impl->methods, "set_element_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_set_element_qname);
+    axis2_hash_set(part_impl->methods, "get_element_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_get_element_qname);
+    axis2_hash_set(part_impl->methods, "get_element", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_get_element);
+    axis2_hash_set(part_impl->methods, "set_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_set_qname);
+    axis2_hash_set(part_impl->methods, "set_element_declaration", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_set_element_declaration);
+    axis2_hash_set(part_impl->methods, "set_types", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_part_set_types);
+
+    return &(part_impl->part);
+}
+
+AXIS2_EXTERN woden_wsdl10_part_t * AXIS2_CALL
+woden_wsdl10_part_create(const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    void *configurable = NULL;
+    
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    part_impl = (woden_wsdl10_part_impl_t *) create(env);
+
+    part_impl->nested_configurable = woden_nested_configurable_create(env);
+
+    part_impl->super = axis2_hash_make(env);
+    if(!part_impl->super) 
+    {
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        return NULL;
+    }
+    axis2_hash_set(part_impl->super, "WODEN_WSDL10_PART", 
+            AXIS2_HASH_KEY_STRING, 
+            &(part_impl->part));
+    axis2_hash_set(part_impl->super, "WODEN_NESTED_CONFIGURABLE", 
+            AXIS2_HASH_KEY_STRING, 
+            part_impl->nested_configurable);
+    configurable = WODEN_NESTED_CONFIGURABLE_GET_BASE_IMPL(
+            part_impl->nested_configurable, env);
+    axis2_hash_set(part_impl->super, "WODEN_CONFIGURABLE", 
+            AXIS2_HASH_KEY_STRING, configurable);
+ 
+    return &(part_impl->part);
+}
+
+static axis2_status_t
+woden_wsdl10_part_free_ops(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    part_impl = INTF_TO_IMPL(part);
+
+    if(part_impl->part.base.part_element.ops)
+    {
+        AXIS2_FREE(env->allocator, part_impl->part.base.
+                part_element.ops);
+        part_impl->part.base.part_element.ops = NULL;
+    }
+
+    if(part_impl->part.base.nested_configurable.ops)
+    {
+        AXIS2_FREE(env->allocator, part_impl->part.base.
+                nested_configurable.ops);
+        part_impl->part.base.nested_configurable.ops = 
+            NULL;
+    }
+    
+    if(part_impl->part.base.nested_configurable.base.configurable.ops)
+    {
+        AXIS2_FREE(env->allocator, part_impl->part.base.
+                nested_configurable.base.configurable.ops);
+        part_impl->part.base.nested_configurable.base.configurable.ops = 
+            NULL;
+    }
+   
+    if(part_impl->part.base.part_element.base.
+            nested_element.ops)
+    {
+        AXIS2_FREE(env->allocator, part_impl->part.base.
+                part_element.base.nested_element.ops);
+        part_impl->part.base.part_element.base.
+            nested_element.ops = NULL;
+    }
+ 
+    if(part_impl->part.base.part_element.base.
+            configurable_element.ops)
+    {
+        AXIS2_FREE(env->allocator, part_impl->part.base.
+                part_element.base.configurable_element.ops);
+        part_impl->part.base.part_element.base.
+            configurable_element.ops = NULL;
+    }
+    
+    if(part_impl->part.base.part_element.base.
+            documentable_element.ops)
+    {
+        AXIS2_FREE(env->allocator, part_impl->part.base.
+                part_element.base.documentable_element.ops);
+        part_impl->part.base.part_element.base.
+            documentable_element.ops = NULL;
+    }
+     
+    if(part_impl->part.base.nested_configurable.base.
+            configurable.base.documentable.ops)
+    {
+        AXIS2_FREE(env->allocator, part_impl->part.base.
+                nested_configurable.base.configurable.base.documentable.ops);
+        part_impl->part.base.nested_configurable.base.
+            configurable.base.documentable.ops = NULL;
+    }
+      
+    if(part_impl->part.base.part_element.base.
+            documentable_element.wsdl_element.base.attr_extensible.ops)
+    {
+        AXIS2_FREE(env->allocator, part_impl->part.base.
+                part_element.base.documentable_element.wsdl_element.base.
+                attr_extensible.ops);
+        part_impl->part.base.part_element.base.
+            documentable_element.wsdl_element.base.attr_extensible.ops = NULL;
+    }
+      
+    if(part_impl->part.base.part_element.base.
+            documentable_element.wsdl_element.base.element_extensible.ops)
+    {
+        AXIS2_FREE(env->allocator, part_impl->part.base.
+                part_element.base.documentable_element.wsdl_element.base.
+                element_extensible.ops);
+        part_impl->part.base.part_element.base.
+            documentable_element.wsdl_element.base.element_extensible.ops = NULL;
+    }
+      
+    return AXIS2_SUCCESS;
+}
+
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_free(void *part,
+                        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    part_impl = INTF_TO_IMPL(part);
+
+    if(part_impl->f_qname)
+    {
+        AXIS2_QNAME_FREE(part_impl->f_qname, env);
+        part_impl->f_qname = NULL;
+    }
+
+    if(part_impl->f_element_decl)
+    {
+        WODEN_ELEMENT_DECL_FREE(part_impl->f_element_decl, env);
+        part_impl->f_element_decl = NULL;
+    }
+
+    if(part_impl->f_element_qname)
+    {
+        AXIS2_QNAME_FREE(part_impl->f_element_qname, env);
+        part_impl->f_element_qname = NULL;
+    }
+
+    if(part_impl->f_types)
+    {
+        WODEN_TYPES_FREE(part_impl->f_types, env);
+        part_impl->f_types = NULL;
+    }
+
+    if(part_impl->super)
+    {
+        axis2_hash_free(part_impl->super, env);
+        part_impl->super = NULL;
+    }
+    
+    if(part_impl->methods)
+    {
+        axis2_hash_free(part_impl->methods, env);
+        part_impl->methods = NULL;
+    }
+
+    if(part_impl->nested_configurable)
+    {
+        WODEN_NESTED_CONFIGURABLE_FREE(part_impl->
+                nested_configurable, env);
+        part_impl->nested_configurable = NULL;
+    }
+
+    woden_wsdl10_part_free_ops(part, env);
+
+    if((&(part_impl->part))->ops)
+    {
+        AXIS2_FREE(env->allocator, (&(part_impl->part))->ops);
+        (&(part_impl->part))->ops = NULL;
+    }
+    
+    if(part_impl)
+    {
+        AXIS2_FREE(env->allocator, part_impl);
+        part_impl = NULL;
+    }
+    return AXIS2_SUCCESS;
+}
+
+axis2_hash_t *AXIS2_CALL
+woden_wsdl10_part_super_objs(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    part_impl = INTF_TO_IMPL(part);
+
+    return part_impl->super;
+}
+
+woden_obj_types_t AXIS2_CALL
+woden_wsdl10_part_type(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    part_impl = INTF_TO_IMPL(part);
+
+    return part_impl->obj_type;
+}
+
+woden_nested_configurable_t *AXIS2_CALL
+woden_wsdl10_part_get_base_impl(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    part_impl = INTF_TO_IMPL(part);
+
+    return part_impl->nested_configurable;
+}
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_resolve_methods(
+        woden_wsdl10_part_t *part,
+        const axis2_env_t *env,
+        woden_wsdl10_part_t *part_impl,
+        axis2_hash_t *methods)
+{
+    woden_wsdl10_part_impl_t *part_impl_l = NULL;
+    
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    AXIS2_PARAM_CHECK(env->error, methods, AXIS2_FAILURE);
+    part_impl_l = INTF_TO_IMPL(part_impl);
+    
+    part->ops->free = axis2_hash_get(methods, "free", 
+            AXIS2_HASH_KEY_STRING);
+    part->ops->super_objs = axis2_hash_get(methods, "super_objs", 
+            AXIS2_HASH_KEY_STRING);
+    part->ops->type = axis2_hash_get(methods, "type", 
+            AXIS2_HASH_KEY_STRING);
+    
+    part->ops->get_qname = axis2_hash_get(methods, 
+            "get_qname", AXIS2_HASH_KEY_STRING);
+    if(!part->ops->get_qname && part_impl_l)
+            part->ops->get_qname = 
+            part_impl_l->part.ops->get_qname;
+    
+    part->ops->get_element_declaration = axis2_hash_get(methods, 
+            "get_element_declaration", AXIS2_HASH_KEY_STRING);
+    if(!part->ops->get_element_declaration && part_impl_l)
+            part->ops->get_element_declaration = 
+            part_impl_l->part.ops->get_element_declaration;
+    
+    part->ops->to_element = axis2_hash_get(methods, 
+            "to_element", AXIS2_HASH_KEY_STRING);
+    if(!part->ops->to_element && part_impl_l)
+            part->ops->to_element = 
+            part_impl_l->part.ops->to_element;
+    
+    part->ops->set_element_declaration = axis2_hash_get(methods, 
+            "set_element_declaration", AXIS2_HASH_KEY_STRING);
+    if(!part->ops->set_element_declaration && part_impl_l)
+            part->ops->set_element_declaration = 
+            part_impl_l->part.ops->set_element_declaration;
+    
+    part->ops->set_types = axis2_hash_get(methods, 
+            "set_types", AXIS2_HASH_KEY_STRING);
+    if(!part->ops->set_types && part_impl_l)
+            part->ops->set_types = 
+            part_impl_l->part.ops->set_types;
+   
+    return AXIS2_SUCCESS;
+}
+
+/* ************************************************************
+ *  Interface Message Reference  methods (the WSDL Component model)
+ * ************************************************************/
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_part_get_qname(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_PART_SUPER_OBJS(part, env);
+    part_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_PART", AXIS2_HASH_KEY_STRING));
+
+    return part_impl->f_qname;
+}
+
+void *AXIS2_CALL
+woden_wsdl10_part_get_element_declaration(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    super = WODEN_WSDL10_PART_SUPER_OBJS(part, env);
+    part_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_PART", AXIS2_HASH_KEY_STRING));
+    
+    return part_impl->f_element_decl;
+}
+
+void *AXIS2_CALL
+woden_wsdl10_part_to_element(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_PART_SUPER_OBJS(part, env);
+    part_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_PART", AXIS2_HASH_KEY_STRING));
+    
+    return &(part_impl->part);
+}
+
+/* ************************************************************
+ *  Interface Message Reference Element methods (the XML Element model)
+ * ************************************************************/
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_set_qname(
+        void *part,
+        const axis2_env_t *env,
+        axis2_qname_t *qname)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    AXIS2_PARAM_CHECK(env->error, qname, AXIS2_FAILURE);
+    super = WODEN_WSDL10_PART_SUPER_OBJS(part, env);
+    part_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_PART", AXIS2_HASH_KEY_STRING));
+
+    if(part_impl->f_qname)
+    {
+        AXIS2_QNAME_FREE(part_impl->f_qname, env);
+        part_impl->f_qname = NULL;
+    }
+    part_impl->f_qname = AXIS2_QNAME_CLONE(qname, env);
+
+
+    return AXIS2_SUCCESS;
+}
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_set_element_qname(
+        void *part,
+        const axis2_env_t *env,
+        axis2_qname_t *element)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    AXIS2_PARAM_CHECK(env->error, element, AXIS2_FAILURE);
+    super = WODEN_WSDL10_PART_SUPER_OBJS(part, env);
+    part_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_PART", AXIS2_HASH_KEY_STRING));
+
+    if(part_impl->f_element_qname)
+    {
+        AXIS2_QNAME_FREE(part_impl->f_element_qname, env);
+    }
+    part_impl->f_element_qname = AXIS2_QNAME_CLONE(element, env);
+    return AXIS2_SUCCESS;
+}
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_part_get_element_qname(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_PART_SUPER_OBJS(part, env);
+    part_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_PART", AXIS2_HASH_KEY_STRING));
+
+    return part_impl->f_element_qname;
+}
+
+void *AXIS2_CALL
+woden_wsdl10_part_get_element(
+        void *part,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    axis2_hash_t *super = NULL;
+    xml_schema_element_t *xse = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_PART_SUPER_OBJS(part, env);
+    part_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_PART", AXIS2_HASH_KEY_STRING));
+
+    if(part_impl->f_types)
+    {
+        xse = (xml_schema_element_t *) 
+            WODEN_TYPES_GET_ELEMENT_DECLARATION(
+            part_impl->f_types, env, part_impl->
+            f_element_qname);
+    }
+
+    return xse;
+}
+
+/* ************************************************************
+ *  Non-API implementation methods
+ * ************************************************************/
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_set_element_declaration(
+        void *part,
+        const axis2_env_t *env,
+        void *element)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    AXIS2_PARAM_CHECK(env->error, element, AXIS2_FAILURE);
+    super = WODEN_WSDL10_PART_SUPER_OBJS(part, env);
+    part_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_PART", AXIS2_HASH_KEY_STRING));
+
+    if(!part_impl->f_element_decl)
+    {
+        /* TODO */
+    }
+    part_impl->f_element_decl = element;
+    
+    return AXIS2_SUCCESS;
+}
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_part_set_types(
+        void *part,
+        const axis2_env_t *env,
+        void *types)
+{
+    woden_wsdl10_part_impl_t *part_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    AXIS2_PARAM_CHECK(env->error, types, AXIS2_FAILURE);
+    super = WODEN_WSDL10_PART_SUPER_OBJS(part, env);
+    part_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_PART", AXIS2_HASH_KEY_STRING));
+
+    if(!part_impl->f_types)
+    {
+        /* TODO */
+    }
+    part_impl->f_types = types;
+    
+    return AXIS2_SUCCESS;
+}
+

Added: webservices/axis2/trunk/c/woden/src/wsdl10/svc.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/woden/src/wsdl10/svc.c?rev=419452&view=auto
==============================================================================
--- webservices/axis2/trunk/c/woden/src/wsdl10/svc.c (added)
+++ webservices/axis2/trunk/c/woden/src/wsdl10/svc.c Wed Jul  5 23:02:19 2006
@@ -0,0 +1,939 @@
+/*
+ * Copyright 2004,2005 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <woden_wsdl10_svc.h>
+#include <woden_nested_configurable.h>
+#include <woden_ext_element.h>
+#include <woden_component_exts.h>
+#include <woden_xml_attr.h>
+#include <woden_documentation_element.h>
+#include <woden_interface.h>
+
+typedef struct woden_wsdl10_svc_impl woden_wsdl10_svc_impl_t;
+
+/** 
+ * @brief Service Struct Impl
+ *   Axis2 Service  
+ */ 
+struct woden_wsdl10_svc_impl
+{
+    woden_wsdl10_svc_t svc;
+    woden_obj_types_t obj_type;
+    woden_configurable_t *configurable;
+    axis2_hash_t *super;
+    axis2_hash_t *methods;
+    axis2_qname_t *f_qname;
+    axis2_qname_t *f_interface_qname;
+    void *f_interface;
+    axis2_array_list_t *f_endpoints;
+};
+
+#define INTF_TO_IMPL(svc) ((woden_wsdl10_svc_impl_t *) svc)
+
+axis2_status_t AXIS2_CALL 
+woden_wsdl10_svc_free(
+        void *svc,
+        const axis2_env_t *env);
+
+axis2_hash_t *AXIS2_CALL 
+woden_wsdl10_svc_super_objs(
+        void *svc,
+        const axis2_env_t *env);
+
+woden_obj_types_t AXIS2_CALL 
+woden_wsdl10_svc_type(
+        void *svc,
+        const axis2_env_t *env);
+
+woden_configurable_t *AXIS2_CALL
+woden_wsdl10_svc_get_base_impl(
+        void *svc,
+        const axis2_env_t *env);
+/* ************************************************************
+ *  Service interface methods (the WSDL Component model)
+ * ************************************************************/
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_svc_get_qname(
+        void *svc,
+        const axis2_env_t *env);
+
+void *AXIS2_CALL
+woden_wsdl10_svc_get_interface(
+        void *svc,
+        const axis2_env_t *env);
+
+axis2_array_list_t *AXIS2_CALL
+woden_wsdl10_svc_get_endpoints(
+        void *svc,
+        const axis2_env_t *env);
+/* ************************************************************
+ *  Service Element interface methods (the XML Element model)
+ * ************************************************************/
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_set_qname(
+        void *svc,
+        const axis2_env_t *env,
+        axis2_qname_t *qname);
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_set_interface_qname(
+        void *svc,
+        const axis2_env_t *env,
+        axis2_qname_t *interface_qname);
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_svc_get_interface_qname(
+        void *svc,
+        const axis2_env_t *env);
+
+void *AXIS2_CALL
+woden_wsdl10_svc_get_interface_element(
+        void *svc,
+        const axis2_env_t *env);
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_add_endpoint_element(
+        void *svc,
+        const axis2_env_t *env,
+        void *endpoint);
+
+axis2_array_list_t *AXIS2_CALL
+woden_wsdl10_svc_get_endpoint_elements(
+        void *svc,
+        const axis2_env_t *env);
+
+/******************************************************************************
+ *  Non-API implementation methods
+ *****************************************************************************/  
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_set_interface_element(
+        void *svc,
+        const axis2_env_t *env,
+        void *interface);
+
+
+static woden_wsdl10_svc_t *
+create(const axis2_env_t *env);
+
+static axis2_status_t
+woden_wsdl10_svc_free_ops(
+        void *svc,
+        const axis2_env_t *env);
+
+/************************Woden C Internal Methods******************************/
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_to_svc_element(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, NULL);
+    if(!svc)
+    {
+        svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+    }
+    else
+        svc_impl = (woden_wsdl10_svc_impl_t *) svc;
+
+    woden_wsdl10_svc_free_ops(svc, env);
+
+    svc_impl->svc.base.svc_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_wsdl10_svc_element_ops_t));
+    woden_wsdl10_svc_element_resolve_methods(&(svc_impl->svc.base.
+            svc_element), env, svc_impl->methods);
+    return svc;
+}
+
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_to_documentable_element(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, NULL);
+    if(!svc)
+    {
+        svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+    }
+    else
+        svc_impl = (woden_wsdl10_svc_impl_t *) svc;
+
+    woden_wsdl10_svc_free_ops(svc, env);
+
+    svc_impl->svc.base.svc_element.base.documentable_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_documentable_element_ops_t));
+    woden_documentable_element_resolve_methods(&(svc_impl->svc.base.
+            svc_element.base.documentable_element), env, 
+            svc_impl->methods);
+    return svc;
+}
+
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_to_configurable(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, NULL);
+    if(!svc)
+    {
+        svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+    }
+    else
+        svc_impl = (woden_wsdl10_svc_impl_t *) svc;
+
+    woden_wsdl10_svc_free_ops(svc, env);
+
+    svc_impl->svc.base.configurable.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_configurable_ops_t));
+    woden_configurable_resolve_methods(&(svc_impl->svc.base.
+            configurable), env, svc_impl->configurable, 
+            svc_impl->methods);
+    return svc;
+}
+
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_to_configurable_component(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    
+    AXIS2_ENV_CHECK(env, NULL);
+    if(!svc)
+    {
+        svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+    }
+    else
+        svc_impl = (woden_wsdl10_svc_impl_t *) svc;
+
+    woden_wsdl10_svc_free_ops(svc, env);
+  
+    svc_impl->svc.base.configurable_component.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_configurable_component_ops_t));
+    woden_configurable_component_resolve_methods(&(svc_impl->svc.base.
+            configurable_component), env, svc_impl->methods);
+    return svc;
+}
+
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_to_wsdl_component(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+
+    if(!svc)
+    {
+        svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+    }
+    else
+        svc_impl = (woden_wsdl10_svc_impl_t *) svc;
+
+    woden_wsdl10_svc_free_ops(svc, env);
+
+    svc_impl->svc.base.configurable_component.wsdl_component.ops = 
+        AXIS2_MALLOC(env->allocator, 
+        sizeof(woden_wsdl_component_ops_t));
+    woden_wsdl_component_resolve_methods(&(svc_impl->svc.base.
+            configurable_component.wsdl_component), env, svc_impl->methods);
+    return svc;
+}
+
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_to_configurable_element(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, NULL);
+    if(!svc)
+    {
+        svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+    }
+    else
+        svc_impl = (woden_wsdl10_svc_impl_t *) svc;
+
+    woden_wsdl10_svc_free_ops(svc, env);
+
+    svc_impl->svc.base.svc_element.base.configurable_element.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_configurable_element_ops_t));
+    woden_configurable_element_resolve_methods(&(svc_impl->svc.base.
+            svc_element.base.configurable_element), env, svc_impl->methods);
+    return svc;
+}
+
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_to_documentable(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, NULL);
+    if(!svc)
+    {
+        svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+    }
+    else
+        svc_impl = (woden_wsdl10_svc_impl_t *) svc;
+
+    woden_wsdl10_svc_free_ops(svc, env);
+
+    svc_impl->svc.base.
+        configurable.base.documentable.ops = AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_documentable_ops_t));
+    woden_documentable_resolve_methods(&(svc_impl->svc.base.
+            configurable.base.documentable), env, NULL,
+            svc_impl->methods);
+    return svc;
+}
+
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_to_attr_extensible(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, NULL);
+    if(!svc)
+    {
+        svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+    }
+    else
+        svc_impl = (woden_wsdl10_svc_impl_t *) svc;
+
+    woden_wsdl10_svc_free_ops(svc, env);
+
+    svc_impl->svc.base.svc_element.base.documentable_element.
+        wsdl_element.base.attr_extensible.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_attr_extensible_ops_t));
+    woden_attr_extensible_resolve_methods(&(svc_impl->svc.base.
+            svc_element.base.documentable_element.wsdl_element.base.
+            attr_extensible), env, NULL, svc_impl->methods);
+    return svc;
+}
+
+
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_to_element_extensible(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, NULL);
+    if(!svc)
+    {
+        svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+    }
+    else
+        svc_impl = (woden_wsdl10_svc_impl_t *) svc;
+
+    woden_wsdl10_svc_free_ops(svc, env);
+
+    svc_impl->svc.base.svc_element.base.documentable_element.
+        wsdl_element.base.element_extensible.ops = 
+        AXIS2_MALLOC(env->allocator, 
+                sizeof(woden_element_extensible_ops_t));
+    woden_element_extensible_resolve_methods(&(svc_impl->svc.base.
+            svc_element.base.documentable_element.wsdl_element.base.
+            element_extensible), env, NULL, svc_impl->methods);
+    return svc;
+}
+
+
+/************************End of Woden C Internal Methods***********************/
+static woden_wsdl10_svc_t *
+create(const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, NULL);
+    svc_impl = AXIS2_MALLOC(env->allocator, 
+                    sizeof(woden_wsdl10_svc_impl_t));
+
+    svc_impl->obj_type= WODEN_WSDL10_SVC;
+    svc_impl->super = NULL;
+    svc_impl->methods = NULL;
+    svc_impl->f_qname = NULL;
+    svc_impl->f_interface_qname = NULL;
+    svc_impl->f_interface = NULL;
+    svc_impl->f_endpoints = NULL;
+    
+    svc_impl->svc.base.svc_element.ops = NULL;
+    svc_impl->svc.base.svc_element.base.documentable_element.ops = 
+            NULL;
+    svc_impl->svc.base.configurable.ops = NULL;
+    svc_impl->svc.base.configurable_component.ops = NULL;
+    svc_impl->svc.base.configurable_component.wsdl_component.ops = NULL;
+    svc_impl->svc.base.svc_element.base.
+        configurable_element.ops = NULL;
+    svc_impl->svc.base.configurable.base.
+        documentable.ops = NULL;
+    svc_impl->svc.base.svc_element.base.
+        documentable_element.wsdl_element.base.attr_extensible.ops = NULL;
+    svc_impl->svc.base.svc_element.base.
+        documentable_element.wsdl_element.base.element_extensible.ops = NULL;
+ 
+    svc_impl->svc.ops = AXIS2_MALLOC(env->allocator, 
+            sizeof(woden_wsdl10_svc_ops_t));
+
+    svc_impl->svc.ops->free = woden_wsdl10_svc_free;
+    svc_impl->svc.ops->super_objs = woden_wsdl10_svc_super_objs;
+    svc_impl->svc.ops->type = woden_wsdl10_svc_type;
+    svc_impl->svc.ops->get_base_impl = woden_wsdl10_svc_get_base_impl;
+
+    svc_impl->svc.ops->get_qname = woden_wsdl10_svc_get_qname;
+    svc_impl->svc.ops->get_interface = woden_wsdl10_svc_get_interface;
+    svc_impl->svc.ops->get_endpoints = 
+        woden_wsdl10_svc_get_endpoints;
+    svc_impl->svc.ops->set_interface_element = 
+        woden_wsdl10_svc_set_interface_element;
+ 
+    svc_impl->methods = axis2_hash_make(env);
+    if(!svc_impl->methods) 
+    {
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        return NULL;
+    }
+    axis2_hash_set(svc_impl->methods, "free", AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_free);
+    axis2_hash_set(svc_impl->methods, "super_objs", 
+            AXIS2_HASH_KEY_STRING, woden_wsdl10_svc_super_objs);
+    axis2_hash_set(svc_impl->methods, "type", 
+            AXIS2_HASH_KEY_STRING, woden_wsdl10_svc_type);
+
+    axis2_hash_set(svc_impl->methods, "get_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_get_qname);
+    axis2_hash_set(svc_impl->methods, "get_interface", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_get_interface);
+    axis2_hash_set(svc_impl->methods, "get_endpoints", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_get_endpoints);
+    axis2_hash_set(svc_impl->methods, "set_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_set_qname);
+    axis2_hash_set(svc_impl->methods, "set_interface_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_set_interface_qname);
+    axis2_hash_set(svc_impl->methods, "get_interface_qname", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_get_interface_qname);
+    axis2_hash_set(svc_impl->methods, "get_interface_element", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_get_interface_element);
+    axis2_hash_set(svc_impl->methods, "add_endpoint_element", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_add_endpoint_element);
+    axis2_hash_set(svc_impl->methods, "get_endpoint_elements", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_get_endpoint_elements);
+    axis2_hash_set(svc_impl->methods, "set_interface_element", 
+            AXIS2_HASH_KEY_STRING, 
+            woden_wsdl10_svc_set_interface_element);
+
+    return &(svc_impl->svc);
+}
+
+AXIS2_EXTERN woden_wsdl10_svc_t * AXIS2_CALL
+woden_wsdl10_svc_create(const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+   
+    AXIS2_ENV_CHECK(env, NULL);
+    svc_impl = (woden_wsdl10_svc_impl_t *) create(env);
+
+    svc_impl->configurable = woden_configurable_create(env);
+
+    svc_impl->super = axis2_hash_make(env);
+    if(!svc_impl->super) 
+    {
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        return NULL;
+    }
+    axis2_hash_set(svc_impl->super, "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING, 
+            &(svc_impl->svc));
+    axis2_hash_set(svc_impl->super, "WODEN_NESTED_CONFIGURABLE", AXIS2_HASH_KEY_STRING, 
+            svc_impl->configurable);
+ 
+    return &(svc_impl->svc);
+}
+
+static axis2_status_t
+woden_wsdl10_svc_free_ops(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    svc_impl = INTF_TO_IMPL(svc);
+
+    if(svc_impl->svc.base.svc_element.ops)
+    {
+        AXIS2_FREE(env->allocator, svc_impl->svc.base.
+                svc_element.ops);
+        svc_impl->svc.base.svc_element.ops = NULL;
+    }
+
+    if(svc_impl->svc.base.svc_element.base.documentable_element.ops)
+    {
+        AXIS2_FREE(env->allocator, svc_impl->svc.base.
+                svc_element.base.documentable_element.ops);
+        svc_impl->svc.base.svc_element.base.documentable_element.ops = 
+            NULL;
+    }
+    
+    if(svc_impl->svc.base.configurable.ops)
+    {
+        AXIS2_FREE(env->allocator, svc_impl->svc.base.
+                configurable.ops);
+        svc_impl->svc.base.configurable.ops = 
+            NULL;
+    }
+    
+    if(svc_impl->svc.base.configurable_component.ops)
+    {
+        AXIS2_FREE(env->allocator, svc_impl->svc.base.
+                configurable_component.ops);
+        svc_impl->svc.base.configurable_component.ops = NULL;
+    }
+
+    if(svc_impl->svc.base.configurable_component.wsdl_component.ops)
+    {
+        AXIS2_FREE(env->allocator, svc_impl->svc.base.
+                configurable_component.wsdl_component.ops);
+        svc_impl->svc.base.configurable_component.wsdl_component.ops = NULL;
+    }
+ 
+    if(svc_impl->svc.base.svc_element.base.
+            configurable_element.ops)
+    {
+        AXIS2_FREE(env->allocator, svc_impl->svc.base.
+                svc_element.base.configurable_element.ops);
+        svc_impl->svc.base.svc_element.base.
+            configurable_element.ops = NULL;
+    }
+    
+    if(svc_impl->svc.base.
+            configurable.base.documentable.ops)
+    {
+        AXIS2_FREE(env->allocator, svc_impl->svc.base.
+                configurable.base.documentable.ops);
+        svc_impl->svc.base.
+            configurable.base.documentable.ops = NULL;
+    }
+      
+    if(svc_impl->svc.base.svc_element.base.
+            documentable_element.wsdl_element.base.attr_extensible.ops)
+    {
+        AXIS2_FREE(env->allocator, svc_impl->svc.base.
+                svc_element.base.documentable_element.wsdl_element.base.
+                attr_extensible.ops);
+        svc_impl->svc.base.svc_element.base.
+            documentable_element.wsdl_element.base.attr_extensible.ops = NULL;
+    }
+      
+    if(svc_impl->svc.base.svc_element.base.
+            documentable_element.wsdl_element.base.element_extensible.ops)
+    {
+        AXIS2_FREE(env->allocator, svc_impl->svc.base.
+                svc_element.base.documentable_element.wsdl_element.base.
+                element_extensible.ops);
+        svc_impl->svc.base.svc_element.base.
+            documentable_element.wsdl_element.base.element_extensible.ops = NULL;
+    }
+  
+
+    return AXIS2_SUCCESS;
+}
+
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_free(void *svc,
+                        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    svc_impl = INTF_TO_IMPL(svc);
+
+    if(svc_impl->f_qname)
+    {
+        AXIS2_QNAME_FREE(svc_impl->f_qname, env);
+        svc_impl->f_qname = NULL;
+    }
+
+    if(svc_impl->f_interface_qname)
+    {
+        AXIS2_QNAME_FREE(svc_impl->f_interface_qname, env);
+        svc_impl->f_interface_qname = NULL;
+    }
+
+    if(svc_impl->f_interface)
+    {
+        WODEN_INTERFACE_FREE(svc_impl->f_interface, env);
+        svc_impl->f_interface = NULL;
+    }
+
+    if(svc_impl->f_endpoints)
+    {
+        AXIS2_ARRAY_LIST_FREE(svc_impl->f_endpoints, env);
+        svc_impl->f_endpoints = NULL;
+    }
+   
+    /* TODO free f_parent */
+    
+    if(svc_impl->super)
+    {
+        axis2_hash_free(svc_impl->super, env);
+        svc_impl->super = NULL;
+    }
+    
+    if(svc_impl->methods)
+    {
+        axis2_hash_free(svc_impl->methods, env);
+        svc_impl->methods = NULL;
+    }
+
+    if(svc_impl->configurable)
+    {
+        WODEN_NESTED_CONFIGURABLE_FREE(svc_impl->configurable, env);
+        svc_impl->configurable = NULL;
+    }
+
+    woden_wsdl10_svc_free_ops(svc, env);
+
+    if((&(svc_impl->svc))->ops)
+    {
+        AXIS2_FREE(env->allocator, (&(svc_impl->svc))->ops);
+        (&(svc_impl->svc))->ops = NULL;
+    }
+    
+    if(svc_impl)
+    {
+        AXIS2_FREE(env->allocator, svc_impl);
+        svc_impl = NULL;
+    }
+    return AXIS2_SUCCESS;
+}
+
+axis2_hash_t *AXIS2_CALL
+woden_wsdl10_svc_super_objs(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    svc_impl = INTF_TO_IMPL(svc);
+
+    return svc_impl->super;
+}
+
+woden_obj_types_t AXIS2_CALL
+woden_wsdl10_svc_type(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    svc_impl = INTF_TO_IMPL(svc);
+
+    return svc_impl->obj_type;
+}
+
+woden_configurable_t *AXIS2_CALL
+woden_wsdl10_svc_get_base_impl(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    svc_impl = INTF_TO_IMPL(svc);
+
+    return svc_impl->configurable;
+}
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_resolve_methods(
+        woden_wsdl10_svc_t *svc,
+        const axis2_env_t *env,
+        woden_wsdl10_svc_t *svc_impl,
+        axis2_hash_t *methods)
+{
+    woden_wsdl10_svc_impl_t *svc_impl_l = NULL;
+    
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    AXIS2_PARAM_CHECK(env->error, methods, AXIS2_FAILURE);
+    svc_impl_l = INTF_TO_IMPL(svc_impl);
+    
+    svc->ops->free = axis2_hash_get(methods, "free", 
+            AXIS2_HASH_KEY_STRING);
+    svc->ops->super_objs = axis2_hash_get(methods, "super_objs", 
+            AXIS2_HASH_KEY_STRING);
+    svc->ops->type = axis2_hash_get(methods, "type", 
+            AXIS2_HASH_KEY_STRING);
+    
+    svc->ops->get_qname = axis2_hash_get(methods, 
+            "get_qname", AXIS2_HASH_KEY_STRING);
+    if(!svc->ops->get_qname && svc_impl_l)
+            svc->ops->get_qname = 
+            svc_impl_l->svc.ops->get_qname;
+    
+    svc->ops->get_interface = axis2_hash_get(methods, 
+            "get_interface", AXIS2_HASH_KEY_STRING);
+    if(!svc->ops->get_interface && svc_impl_l)
+            svc->ops->get_interface = 
+            svc_impl_l->svc.ops->get_interface;
+    
+    svc->ops->get_endpoints = axis2_hash_get(methods, 
+            "get_endpoints", AXIS2_HASH_KEY_STRING);
+    if(!svc->ops->get_endpoints && svc_impl_l)
+            svc->ops->get_endpoints = 
+            svc_impl_l->svc.ops->get_endpoints;
+    
+    svc->ops->set_interface_element = axis2_hash_get(methods, 
+            "set_interface_element", AXIS2_HASH_KEY_STRING);
+    if(!svc->ops->set_interface_element && svc_impl_l)
+            svc->ops->set_interface_element = 
+            svc_impl_l->svc.ops->set_interface_element;
+
+    return AXIS2_SUCCESS;
+}
+/* ************************************************************
+ *  Service interface methods (the WSDL Component model)
+ * ************************************************************/
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_svc_get_qname(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+    
+    return svc_impl->f_qname;
+}
+
+void *AXIS2_CALL
+woden_wsdl10_svc_get_interface(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+    
+    return svc_impl->f_interface;
+}
+
+axis2_array_list_t *AXIS2_CALL
+woden_wsdl10_svc_get_endpoints(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+    
+    return svc_impl->f_endpoints;
+}
+/* ************************************************************
+ *  Service Element interface methods (the XML Element model)
+ * ************************************************************/
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_set_qname(
+        void *svc,
+        const axis2_env_t *env,
+        axis2_qname_t *qname)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+
+    if(svc_impl->f_qname)
+    {
+        AXIS2_QNAME_FREE(svc_impl->f_qname, env);
+    }
+    svc_impl->f_qname = AXIS2_QNAME_CLONE(qname, env);
+    return AXIS2_SUCCESS;
+}
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_set_interface_qname(
+        void *svc,
+        const axis2_env_t *env,
+        axis2_qname_t *interface_qname)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+
+    if(svc_impl->f_interface_qname)
+    {
+        AXIS2_QNAME_FREE(svc_impl->f_interface_qname, env);
+    }
+
+    svc_impl->f_interface_qname = AXIS2_QNAME_CLONE(interface_qname, env);
+    return AXIS2_SUCCESS;
+}
+
+axis2_qname_t *AXIS2_CALL
+woden_wsdl10_svc_get_interface_qname(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+
+    return svc_impl->f_interface_qname;
+}
+
+void *AXIS2_CALL
+woden_wsdl10_svc_get_interface_element(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+
+    return svc_impl->f_interface;
+}
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_add_endpoint_element(
+        void *svc,
+        const axis2_env_t *env,
+        void *endpoint)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+
+    if(!svc_impl->f_endpoints)
+    {
+        svc_impl->f_endpoints = axis2_array_list_create(env, 0);
+        if(!svc_impl->f_endpoints)
+        {
+            AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+            return AXIS2_FAILURE;
+        }
+    }
+
+    return AXIS2_ARRAY_LIST_ADD(svc_impl->f_endpoints, env, endpoint);
+}
+
+axis2_array_list_t *AXIS2_CALL
+woden_wsdl10_svc_get_endpoint_elements(
+        void *svc,
+        const axis2_env_t *env)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, NULL);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+    
+    return svc_impl->f_endpoints;
+}
+/******************************************************************************
+ *  Non-API implementation methods
+ *****************************************************************************/  
+
+axis2_status_t AXIS2_CALL
+woden_wsdl10_svc_set_interface_element(
+        void *svc,
+        const axis2_env_t *env,
+        void *interface)
+{
+    woden_wsdl10_svc_impl_t *svc_impl = NULL;
+    axis2_hash_t *super = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    super = WODEN_WSDL10_SVC_SUPER_OBJS(svc, env);
+    svc_impl = INTF_TO_IMPL(axis2_hash_get(super, 
+                "WODEN_WSDL10_SVC", AXIS2_HASH_KEY_STRING));
+
+    if(svc_impl->f_interface)
+    {
+        /* TODO */
+    }
+
+    svc_impl->f_interface = interface;
+    return AXIS2_SUCCESS;
+}
+
+



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org