You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by na...@apache.org on 2006/04/28 14:28:56 UTC
svn commit: r397881 [1/2] - in /webservices/axis2/trunk/c:
include/xml_schema/ modules/xml/om/ modules/xml/xml_schema/
Author: nandika
Date: Fri Apr 28 05:28:53 2006
New Revision: 397881
URL: http://svn.apache.org/viewcvs?rev=397881&view=rev
Log:
more files added to implement types
Added:
webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_any_attribute.h
webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type.h
webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_content.h
webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_list.h
webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_restriction.h
webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_union.h
webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_any_attribute.c
webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type.c
webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type_content.c
webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type_list.c
webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type_restriction.c
webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type_union.c
Modified:
webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema.h
webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_annotated.h
webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_type.h
webservices/axis2/trunk/c/modules/xml/om/om_output.c
webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema.c
webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_identity_constraint.c
webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_type.c
Modified: webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema.h?rev=397881&r1=397880&r2=397881&view=diff
==============================================================================
--- webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema.h (original)
+++ webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema.h Fri Apr 28 05:28:53 2006
@@ -103,9 +103,9 @@
axis2_env_t **env);
axis2_status_t (AXIS2_CALL *
- set_element_form_default) (
- struct axis2_xml_schema_form *element_form_default,
- axis2_env_t **env);
+ set_element_form_default) (void *schema,
+ axis2_env_t **env,
+ struct axis2_xml_schema_form *element_form_default);
struct axis2_xml_schema_obj_table *(AXIS2_CALL *
get_elements) (void *schema,
@@ -126,9 +126,9 @@
axis2_env_t **env);
axis2_status_t (AXIS2_CALL *
- set_final_default) (
- struct axis2_xml_schema_derivation_method *final_default,
- axis2_env_t **env);
+ set_final_default) (void *schema,
+ axis2_env_t **env,
+ struct axis2_xml_schema_derivation_method *final_default);
struct axis2_xml_schema_obj_table *(AXIS2_CALL *
get_groups) (void *schema,
@@ -173,12 +173,12 @@
axis2_validation_event_handler_t *veh);
axis2_status_t (AXIS2_CALL *
- write_a_out) (void *schema,
+ write_with_out) (void *schema,
axis2_env_t **env,
void *outstream);
axis2_status_t (AXIS2_CALL *
- write_a_writer) (void *schema,
+ write_with_writer) (void *schema,
void *writer);
axis2_hash_t *(AXIS2_CALL *
@@ -228,15 +228,126 @@
#define AXIS2_XML_SCHEMA_GET_BASE_IMPL(schema, env) \
(((axis2_xml_schema_t *) schema)->ops->\
get_base_impl(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_NAMESPACE(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_schema(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_ATTR_FORM_DEFAULT(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_attr_form_default(schema, env))
+
+#define AXIS2_XML_SCHEMA_SET_ATTR_FORM_DEFAULT(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ set_attr_form_default(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_ATTR_GROUPS(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_attr_groups(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_ATTRS(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_attrs(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_BLOCK_DEFAULT(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_block_default(schema, env))
+
-#define AXIS2_XML_SCHEMA_GET_XPATH(schema, env) \
+#define AXIS2_XML_SCHEMA_SET_BLOCK_DEFAULT(schema, env, block_default) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ set_block_default(schema, env, block_default))
+
+#define AXIS2_XML_SCHEMA_GET_ELEMENT_FORM_DEFAULT(schema, env) \
(((axis2_xml_schema_t *) schema)->ops->\
- get_schema(schema, env))
+ get_element_form_default(schema, env))
-#define AXIS2_XML_SCHEMA_SET_XPATH(schema, env, x_path) \
+#define AXIS2_XML_SCHEMA_SET_ELEMENT_FORM_DEFAULT(schema, env, ele_form_default) \
(((axis2_xml_schema_t *) schema)->ops->\
- set_schema(schema, env, x_path))
+ set_element_form_default(schema, env, ele_form_default))
+
+#define AXIS2_XML_SCHEMA_GET_ELEMENTS(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_elements(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_ELEMENT_BY_QNAME(schema, env, qname) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_element_by_qname(schema, env, qname))
+
+#define AXIS2_XML_SCHEMA_GET_TYPE_BY_QNAME(schema, env, qname) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_type_by_qname(schema, env, qname))
+#define AXIS2_XML_SCHEMA_SET_FINAL_DEFAULT(schema, env, final_default) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ set_final_default(schema, env, final_default))
+
+#define AXIS2_XML_SCHEMA_GET_FINAL_DEFAULT(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_final_default(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_GROUPS(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_groups(schema, env))
+
+
+#define AXIS2_XML_SCHEMA_GET_INCLUDES(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_includes(schema, env))
+
+#define AXIS2_XML_SCHEMA_IS_COMPILED(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ is_compiled(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_ITEMS(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_items(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_NOTATIONS(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_items(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_SCHEMA_TYPES(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_schema_types(schema, env))
+
+#define AXIS2_XML_SCHEMA_GET_TARGET_NAMESPACE(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_target_namespace(schema, env))
+
+#define AXIS2_XML_SCHEMA_SET_TARGET_NAMESPACE(schema, env, target_ns) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ set_target_namespace(schema, env, target_ns))
+
+#define AXIS2_XML_SCHEMA_GET_VERSION(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_version(schema, env))
+
+#define AXIS2_XML_SCHEMA_COMPILE(schema, env) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ compile(schema, env))
+
+#define AXIS2_XML_SCHEMA_WRITE_WITH_OUT(schema, env, out) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ write_with_out(schema, env, out))
+
+#define AXIS2_XML_SCHEMA_WRITE_WITH_WRITER(schema, env, writer) \
+ (((axis2_xml_schema_t *) schema)->ops->\
+ write_with_writer(schema, env, writer))
+
+#define AXIS2_XML_SCHEMA_GET_PREFIX_TO_NAMESPACE_MAP(schema, env)\
+ (((axis2_xml_schema_t *) schema)->ops->\
+ get_prefix_to_namespace_map(schema, env))
+
+#define AXIS2_XML_SCHEMA_SET_PREFIX_TO_NAMESPACE_MAP(schema, env, map)\
+ (((axis2_xml_schema_t *) schema)->ops->\
+ set_prefix_to_namespace_map(schema, env, map))
+
+#define AXIS2_XML_SCHEMA_ADD_TYPE(schema, env, type)\
+ (((axis2_xml_schema_t *) schema)->ops->\
+ add_type(schema, env, type))
+
+
/** @} */
#ifdef __cplusplus
}
Modified: webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_annotated.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_annotated.h?rev=397881&r1=397880&r2=397881&view=diff
==============================================================================
--- webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_annotated.h (original)
+++ webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_annotated.h Fri Apr 28 05:28:53 2006
@@ -46,7 +46,7 @@
* @return status code
*/
axis2_status_t (AXIS2_CALL *
- free) (void *annotated,
+ free)(void *annotated,
axis2_env_t **env);
axis2_xml_schema_obj_t *(AXIS2_CALL *
Added: webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_any_attribute.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_any_attribute.h?rev=397881&view=auto
==============================================================================
--- webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_any_attribute.h (added)
+++ webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_any_attribute.h Fri Apr 28 05:28:53 2006
@@ -0,0 +1,121 @@
+/*
+ * 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.
+ */
+
+#ifndef AXIS2_XML_SCHEMA_ANY_ATTRIBUTE_H
+#define AXIS2_XML_SCHEMA_ANY_ATTRIBUTE_H
+
+/**
+ * @file axis2_xml_schema_any.h
+ * @brief Axis2 Xml Schema Any Interface
+ * Enables any element from the specified namespace or namespaces
+ * to appear in the containing complexType element. Represents the
+ * World Wide Web Consortium (W3C) any element.
+ *
+ */
+
+#include <axis2_xml_schema_particle.h>
+#include <axis2_xml_schema_content_processing.h>
+
+/** @defgroup axis2_xml_schema_any Xml Schema Any
+ * @ingroup axis2_xml_schema
+ * @{
+ */
+
+typedef struct axis2_xml_schema_any_attribute
+ axis2_xml_schema_any_attribute_t;
+typedef struct axis2_xml_schema_any_attribute_ops
+ axis2_xml_schema_any_attribute_ops_t;
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+struct axis2_xml_schema_any_attribute_ops
+{
+ /**
+ * Deallocate memory
+ * @return status code
+ */
+ axis2_status_t (AXIS2_CALL *
+ free) (void *any_attr,
+ axis2_env_t **env);
+
+ axis2_xml_schema_annotated_t *(AXIS2_CALL *
+ get_base_impl) (void *any_attr,
+ axis2_env_t **env);
+
+ axis2_char_t *(AXIS2_CALL *
+ get_namespace)(void *any_attr,
+ axis2_env_t **env);
+
+ axis2_status_t (AXIS2_CALL *
+ set_namespace) (void *any_attr,
+ axis2_env_t **env,
+ axis2_char_t *ns);
+
+ struct axis2_xml_schema_content_processing *(AXIS2_CALL *
+ get_process_content) (void *any_attr,
+ axis2_env_t **env);
+
+ axis2_status_t (AXIS2_CALL *
+ set_process_content)(void *any_attr,
+ axis2_env_t **env,
+ struct axis2_xml_schema_content_processing *process_content);
+};
+
+struct axis2_xml_schema_any_attribute
+{
+ axis2_xml_schema_annotated_t base;
+ axis2_xml_schema_any_attribute_ops_t *ops;
+};
+
+AXIS2_DECLARE(axis2_xml_schema_any_attribute_t *)
+axis2_xml_schema_any_attribute_create(axis2_env_t **env);
+
+/**
+ * This method is internal to Axis2 C. It is called from Child Constructor
+ */
+AXIS2_DECLARE(axis2_status_t)
+axis2_xml_schema_any_attribute_resolve_methods(
+ axis2_xml_schema_any_attribute_t *any_attr,
+ axis2_env_t **env,
+ axis2_xml_schema_any_attribute_t *any_impl,
+ axis2_hash_t *methods);
+
+#define AXIS2_XML_SCHEMA_ANY_ATTRIBUTE_FREE(any_attr, env) \
+ (((axis2_xml_schema_any_attribute_t *) any_attr)->ops->free(any_attr, env))
+
+#define AXIS2_XML_SCHEMA_ANY_ATTRIBUTE_GET_BASE_IMPL(any_attr, env) \
+ (((axis2_xml_schema_any_attribute_t *) any_attr)->ops->get_base_impl(any_attr, env))
+
+#define AXIS2_XML_SCHEMA_ANY_ATTRIBUTE_GET_NAMESPACE(any_attr, env) \
+ (((axis2_xml_schema_any_attribute_t *) any_attr)->ops->get_namespace(any_attr, env))
+
+#define AXIS2_XML_SCHEMA_ANY_ATTRIBUTE_SET_NAMESPACE(any_attr, env, namespc) \
+ (((axis2_xml_schema_any_attribute_t *) any_attr)->ops->set_namespace(any_attr, env, namespc))
+
+#define AXIS2_XML_SCHEMA_ANY_ATTRIBUTE_GET_PROCESS_CONTENT(any_attr, env) \
+ (((axis2_xml_schema_any_attribute_t *) any_attr)->ops->get_process_content(any_attr, env))
+
+#define AXIS2_XML_SCHEMA_ANY_ATTRIBUTE_SET_PROCESS_CONTENT(any_attr, env, process_content) \
+ (((axis2_xml_schema_any_attribute_t *) any_attr)->ops->set_process_content(any_attr, env, process_content))
+
+/** @} */
+#ifdef __cplusplus
+}
+#endif
+#endif /* AXIS2_XML_SCHEMA_ANY_ATTRIBUTE_H */
Added: webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type.h?rev=397881&view=auto
==============================================================================
--- webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type.h (added)
+++ webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type.h Fri Apr 28 05:28:53 2006
@@ -0,0 +1,127 @@
+/*
+ * 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.
+ */
+
+#ifndef AXIS2_XML_SCHEMA_SIMPLE_TYPE_H
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_H
+
+/**
+ * @file axis2_xml_schema_type.h
+ * @brief Axis2 Xml Schema Type Interface
+ * The base class for all simple types and complex types.
+ */
+
+#include <axis2_xml_schema_annotated.h>
+#include <axis2_xml_schema_type.h>
+#include <axis2_hash.h>
+#include <axis2_qname.h>
+#include <axis2_xml_schema_simple_type_content.h>
+/** @defgroup axis2_xml_schema_simple_type Xml Schema Type
+ * @ingroup axis2_xml_schema
+ * @{
+ */
+
+typedef struct axis2_xml_schema_simple_type
+ axis2_xml_schema_simple_type_t;
+typedef struct axis2_xml_schema_simple_type_ops
+ axis2_xml_schema_simple_type_ops_t;
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+struct axis2_xml_schema_simple_type_ops
+{
+ /**
+ * Deallocate memory
+ * @return status code
+ */
+ axis2_status_t (AXIS2_CALL *
+ free) (void *simple_type,
+ axis2_env_t **env);
+
+ axis2_xml_schema_type_t *(AXIS2_CALL *
+ get_base_impl) (void *simple_type,
+ axis2_env_t **env);
+
+ axis2_xml_schema_simple_type_content_t* (AXIS2_CALL *
+ get_content)(void *simple_type,
+ axis2_env_t **env);
+
+ axis2_status_t (AXIS2_CALL*
+ set_content)(void *simple_type,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_content_t *simple_content);
+
+ axis2_char_t* (AXIS2_CALL *
+ to_string)(void *simple_type,
+ axis2_env_t **env,
+ axis2_char_t *prefix,
+ int tab);
+};
+
+struct axis2_xml_schema_simple_type
+{
+ axis2_xml_schema_type_t base;
+ axis2_xml_schema_simple_type_ops_t *ops;
+};
+
+/**
+ * Creates new Xml Schema Type
+ * Type types are usually interchangeable.
+ * A local element declaration or reference to a global element
+ * declaration (element), a compositor ( sequence, choice, or all),
+ * a reference to a named content model group (group), or an element wildcard
+ * (any).
+ */
+AXIS2_DECLARE(axis2_xml_schema_simple_type_t *)
+axis2_xml_schema_simple_type_create(axis2_env_t **env,
+ struct axis2_xml_schema *schema);
+
+/**
+ * This method is internal to Axis2 C. It is called from Child Constructor
+ */
+AXIS2_DECLARE(axis2_status_t)
+axis2_xml_schema_simple_type_resolve_methods(
+ axis2_xml_schema_simple_type_t *simple_type,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_t *type_impl,
+ axis2_hash_t *methods);
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_FREE(simple_type, env) \
+ (((axis2_xml_schema_simple_type_t *) simple_type)->ops->\
+ free(simple_type, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_GET_BASE_IMPL(simple_type, env) \
+ (((axis2_xml_schema_simple_type_t *) simple_type)->ops->\
+ get_base_impl(simple_type, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_GET_CONTENT(simple_type, env) \
+ (((axis2_xml_schema_simple_type_t *) simple_type)->ops->\
+ get_content(simple_type, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_SET_CONTENT(simple_type, env, max_occurs) \
+ (((axis2_xml_schema_simple_type_t *) simple_type)->ops->\
+ get_set_content(simple_type, env, max_occurs))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_TO_STRING(simple_type, env) \
+ (((axis2_xml_schema_simple_type_t *) simple_type)->ops->\
+ to_string(simple_type, env))
+
+/** @} */
+#ifdef __cplusplus
+}
+#endif
+#endif /* AXIS2_XML_SCHEMA_SIMPLE_TYPE_H */
Added: webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_content.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_content.h?rev=397881&view=auto
==============================================================================
--- webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_content.h (added)
+++ webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_content.h Fri Apr 28 05:28:53 2006
@@ -0,0 +1,126 @@
+/*
+ * 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.
+ */
+
+#ifndef AXIS2_XML_SCHEMA_SIMPLE_TYPE_CONTENT_H
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_CONTENT_H
+
+/**
+ * @file axis2_xml_schema_simple_type_content.h
+ * @brief Axis2 Xml Schema Particle Interface
+ * Base class for all sim_type_cont types.
+ */
+
+#include <axis2_xml_schema_annotated.h>
+#include <axis2_hash.h>
+
+/** @defgroup axis2_xml_schema_simple_type_content Xml Schema Particle
+ * @ingroup axis2_xml_schema
+ * @{
+ */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+typedef enum axis2_xml_simple_content_types_t
+{
+ AXIS2_XML_SCHEMA_SIMPLE_CONTENT_TYPE = 0,
+ AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST,
+ AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION,
+ AXIS2_XML_SCHEMA_SIMPLE_TYPE_UNION
+
+}axis2_xml_simple_content_types_t;
+
+
+typedef struct axis2_xml_schema_simple_type_content
+ axis2_xml_schema_simple_type_content_t;
+typedef struct axis2_xml_schema_simple_type_content_ops
+ axis2_xml_schema_simple_type_content_ops_t;
+
+
+struct axis2_xml_schema_simple_type_content_ops
+{
+ /**
+ * Deallocate memory
+ * @return status code
+ */
+ axis2_status_t (AXIS2_CALL *
+ free) (void *sim_type_cont,
+ axis2_env_t **env);
+
+ axis2_xml_schema_annotated_t *(AXIS2_CALL *
+ get_base_impl) (void *sim_type_cont,
+ axis2_env_t **env);
+
+ int (AXIS2_CALL *
+ get_type)(void *sim_type_cont,
+ axis2_env_t **env);
+
+ axis2_status_t (AXIS2_CALL *
+ set_type)(void *sim_type_cont,
+ axis2_env_t **env,
+ int type);
+
+};
+
+struct axis2_xml_schema_simple_type_content
+{
+ axis2_xml_schema_annotated_t base;
+ axis2_xml_schema_simple_type_content_ops_t *ops;
+};
+
+/**
+ * Creates new Xml Schema Particle
+ * Particle types are usually interchangeable.
+ * A local element declaration or reference to a global element
+ * declaration (element), a compositor ( sequence, choice, or all),
+ * a reference to a named content model group (group), or an element wildcard
+ * (any).
+ */
+AXIS2_DECLARE(axis2_xml_schema_simple_type_content_t *)
+axis2_xml_schema_simple_type_content_create(axis2_env_t **env);
+
+/**
+ * This method is internal to Axis2 C. It is called from Child Constructor
+ */
+AXIS2_DECLARE(axis2_status_t)
+axis2_xml_schema_simple_type_content_resolve_methods(
+ axis2_xml_schema_simple_type_content_t *sim_type_cont,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_content_t *sim_type_cont_impl,
+ axis2_hash_t *methods);
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_CONTENT_FREE(sim_type_cont, env) \
+ (((axis2_xml_schema_simple_type_content_t *) sim_type_cont)->ops->\
+ free(sim_type_cont, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_CONTENT_GET_BASE_IMPL(sim_type_cont, env) \
+ (((axis2_xml_schema_simple_type_content_t *) sim_type_cont)->ops->\
+ get_base_impl(sim_type_cont, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_CONTENT_SET_TYPE(sim_type_cont, env, type) \
+ (((axis2_xml_schema_simple_type_content_t *) sim_type_cont)->ops->\
+ set_type(sim_type_cont, env, type))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_CONTENT_GET_TYPE(sim_type_cont, env) \
+ (((axis2_xml_schema_simple_type_content_t *) sim_type_cont)->ops->\
+ get_type(sim_type_cont, env))
+
+/** @} */
+#ifdef __cplusplus
+}
+#endif
+#endif /* AXIS2_XML_SCHEMA_SIMPLE_TYPE_CONTENT_H */
Added: webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_list.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_list.h?rev=397881&view=auto
==============================================================================
--- webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_list.h (added)
+++ webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_list.h Fri Apr 28 05:28:53 2006
@@ -0,0 +1,135 @@
+/*
+ * 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.
+ */
+
+#ifndef AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST_H
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST_H
+
+/**
+ * @file axis2_xml_schema_simple_type_list.h
+ * @brief Axis2 Xml Schema Particle Interface
+ * Base class for all simple_type_list types.
+ */
+
+
+#include <axis2_xml_schema_simple_type.h>
+#include <axis2_xml_schema_simple_type_content.h>
+#include <axis2_xml_schema_obj_collection.h>
+#include <axis2_hash.h>
+/** @defgroup axis2_xml_schema_simple_type_list
+ * @ingroup axis2_xml_schema
+ * @{
+ */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+typedef struct axis2_xml_schema_simple_type_list
+ axis2_xml_schema_simple_type_list_t;
+typedef struct axis2_xml_schema_simple_type_list_ops
+ axis2_xml_schema_simple_type_list_ops_t;
+
+struct axis2_xml_schema_simple_type_list_ops
+{
+ /**
+ * Deallocate memory
+ * @return status code
+ */
+ axis2_status_t (AXIS2_CALL *
+ free) (void *simple_type_list,
+ axis2_env_t **env);
+
+ axis2_xml_schema_simple_type_content_t *(AXIS2_CALL *
+ get_base_impl) (void *simple_type_list,
+ axis2_env_t **env);
+
+ axis2_xml_schema_simple_type_t *(AXIS2_CALL *
+ get_item_type)(void *simple_type_list,
+ axis2_env_t **env);
+
+ axis2_status_t (AXIS2_CALL *
+ set_item_type)(void *simple_type_list,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_t *base_type);
+
+ axis2_qname_t* (AXIS2_CALL *
+ get_item_type_name)(void *simple_type_list,
+ axis2_env_t **env);
+
+ axis2_status_t (AXIS2_CALL *
+ set_item_type_name)(void *simple_type_list,
+ axis2_env_t **env,
+ axis2_qname_t *qname);
+};
+
+struct axis2_xml_schema_simple_type_list
+{
+ axis2_xml_schema_simple_type_content_t base;
+ axis2_xml_schema_simple_type_list_ops_t *ops;
+};
+
+/**
+ * Creates new Xml Schema Particle
+ * Particle types are usually interchangeable.
+ * A local element declaration or reference to a global element
+ * declaration (element), a compositor ( sequence, choice, or all),
+ * a reference to a named content model group (group), or an element wildcard
+ * (any).
+ */
+AXIS2_DECLARE(axis2_xml_schema_simple_type_list_t *)
+axis2_xml_schema_simple_type_list_create(axis2_env_t **env);
+
+/**
+ * This method is internal to Axis2 C. It is called from Child Constructor
+ */
+AXIS2_DECLARE(axis2_status_t)
+axis2_xml_schema_simple_type_list_resolve_methods(
+ axis2_xml_schema_simple_type_list_t *simple_type_list,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_list_t *simple_type_list_impl,
+ axis2_hash_t *methods);
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST_FREE(simple_type_list, env) \
+ (((axis2_xml_schema_simple_type_list_t *) simple_type_list)->ops->\
+ free(simple_type_list, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST_GET_BASE_IMPL(simple_type_list, env) \
+ (((axis2_xml_schema_simple_type_list_t *) simple_type_list)->ops->\
+ get_base_impl(simple_type_list, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST_GET_ITEM_TYPE(simple_type_list, env) \
+ (((axis2_xml_schema_simple_type_list_t *) simple_type_list)->ops->\
+ get_item_type(simple_type_list, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST_SET_BASE_TYPE(simple_type_list,\
+ env, base_type) \
+ (((axis2_xml_schema_simple_type_list_t *) simple_type_list)->ops->\
+ set_item_type(simple_type_list, env, base_type))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST_GET_ITEM_TYPE_NAME(simple_type_list, env) \
+ (((axis2_xml_schema_simple_type_list_t *) simple_type_list)->ops->\
+ get_item_type_name(simple_type_list, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST_SET_ITEM_TYPE_NAME(simple_type_list, \
+ env, base_type_name) \
+ (((axis2_xml_schema_simple_type_list_t *) simple_type_list)->ops->\
+ set_item_type_name(simple_type_list, env, base_type_name))
+
+/** @} */
+#ifdef __cplusplus
+}
+#endif
+#endif /* AXIS2_XML_SCHEMA_SIMPLE_TYPE_LIST_H */
Added: webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_restriction.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_restriction.h?rev=397881&view=auto
==============================================================================
--- webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_restriction.h (added)
+++ webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_restriction.h Fri Apr 28 05:28:53 2006
@@ -0,0 +1,152 @@
+/*
+ * 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.
+ */
+
+#ifndef AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_H
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_H
+
+/**
+ * @file axis2_xml_schema_simple_type_restriction.h
+ * @brief Axis2 Xml Schema Particle Interface
+ * Base class for all simple_type_restriction types.
+ */
+
+
+#include <axis2_xml_schema_simple_type.h>
+#include <axis2_xml_schema_simple_type_content.h>
+#include <axis2_xml_schema_obj_collection.h>
+#include <axis2_hash.h>
+/** @defgroup axis2_xml_schema_simple_type_restriction
+ * @ingroup axis2_xml_schema
+ * @{
+ */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+typedef struct axis2_xml_schema_simple_type_restriction
+ axis2_xml_schema_simple_type_restriction_t;
+typedef struct axis2_xml_schema_simple_type_restriction_ops
+ axis2_xml_schema_simple_type_restriction_ops_t;
+
+struct axis2_xml_schema_simple_type_restriction_ops
+{
+ /**
+ * Deallocate memory
+ * @return status code
+ */
+ axis2_status_t (AXIS2_CALL *
+ free) (void *simple_type_restriction,
+ axis2_env_t **env);
+
+ axis2_xml_schema_simple_type_content_t *(AXIS2_CALL *
+ get_base_impl) (void *simple_type_restriction,
+ axis2_env_t **env);
+
+ axis2_xml_schema_simple_type_t *(AXIS2_CALL *
+ get_base_type)(void *simple_type_restriction,
+ axis2_env_t **env);
+
+ axis2_status_t (AXIS2_CALL *
+ set_base_type)(void *simple_type_restriction,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_t *base_type);
+
+ axis2_qname_t* (AXIS2_CALL *
+ get_base_type_name)(void *simple_type_restriction,
+ axis2_env_t **env);
+
+ axis2_status_t (AXIS2_CALL *
+ set_base_type_name)(void *simple_type_restriction,
+ axis2_env_t **env,
+ axis2_qname_t *qname);
+
+ axis2_xml_schema_obj_collection_t* (AXIS2_CALL *
+ get_facets)(void *simple_type_restriction,
+ axis2_env_t **env);
+
+ axis2_char_t* (AXIS2_CALL *
+ to_string)(void *simple_type_restriction,
+ axis2_env_t **env,
+ axis2_char_t *prefix,
+ int tab);
+
+
+};
+
+struct axis2_xml_schema_simple_type_restriction
+{
+ axis2_xml_schema_simple_type_content_t base;
+ axis2_xml_schema_simple_type_restriction_ops_t *ops;
+};
+
+/**
+ * Creates new Xml Schema Particle
+ * Particle types are usually interchangeable.
+ * A local element declaration or reference to a global element
+ * declaration (element), a compositor ( sequence, choice, or all),
+ * a reference to a named content model group (group), or an element wildcard
+ * (any).
+ */
+AXIS2_DECLARE(axis2_xml_schema_simple_type_restriction_t *)
+axis2_xml_schema_simple_type_restriction_create(axis2_env_t **env);
+
+/**
+ * This method is internal to Axis2 C. It is called from Child Constructor
+ */
+AXIS2_DECLARE(axis2_status_t)
+axis2_xml_schema_simple_type_restriction_resolve_methods(
+ axis2_xml_schema_simple_type_restriction_t *simple_type_restriction,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_restriction_t *simple_type_restriction_impl,
+ axis2_hash_t *methods);
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_FREE(simple_type_restriction, env) \
+ (((axis2_xml_schema_simple_type_restriction_t *) simple_type_restriction)->ops->\
+ free(simple_type_restriction, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_GET_BASE_IMPL(simple_type_restriction, env) \
+ (((axis2_xml_schema_simple_type_restriction_t *) simple_type_restriction)->ops->\
+ get_base_impl(simple_type_restriction, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_GET_BASE_TYPE(simple_type_restriction, env) \
+ (((axis2_xml_schema_simple_type_restriction_t *) simple_type_restriction)->ops->\
+ get_max_occurs(simple_type_restriction, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_SET_BASE_TYPE(simple_type_restriction,\
+ env, base_type) \
+ (((axis2_xml_schema_simple_type_restriction_t *) simple_type_restriction)->ops->\
+ set_base_type(simple_type_restriction, env, base_type))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_GET_BASE_TYPE_NAME(simple_type_restriction, env) \
+ (((axis2_xml_schema_simple_type_restriction_t *) simple_type_restriction)->ops->\
+ get_base_type_name(simple_type_restriction, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_SET_BASE_TYPE_NAME(simple_type_restriction, \
+ env, base_type_name) \
+ (((axis2_xml_schema_simple_type_restriction_t *) simple_type_restriction)->ops->\
+ set_base_type_name(simple_type_restriction, env, base_type_name))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_GET_FACETS(simple_type_restriction, env) \
+ (((axis2_xml_schema_simple_type_restriction_t *) simple_type_restriction)->ops->\
+ get_facets(simple_type_restriction, env))
+
+
+/** @} */
+#ifdef __cplusplus
+}
+#endif
+#endif /* AXIS2_XML_SCHEMA_SIMPLE_TYPE_RESTRICTION_H */
Added: webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_union.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_union.h?rev=397881&view=auto
==============================================================================
--- webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_union.h (added)
+++ webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_simple_type_union.h Fri Apr 28 05:28:53 2006
@@ -0,0 +1,135 @@
+/*
+ * 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.
+ */
+
+#ifndef AXIS2_XML_SCHEMA_SIMPLE_TYPE_UNION_H
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_UNION_H
+
+/**
+ * @file axis2_xml_schema_simple_type_union.h
+ * @brief Axis2 Xml Schema Particle Interface
+ * Base class for all simple_type_union types.
+ */
+
+
+#include <axis2_xml_schema_simple_type.h>
+#include <axis2_xml_schema_simple_type_content.h>
+#include <axis2_xml_schema_obj_collection.h>
+#include <axis2_hash.h>
+#include <axis2_array_list.h>
+/** @defgroup axis2_xml_schema_simple_type_union
+ * @ingroup axis2_xml_schema
+ * @{
+ */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+typedef struct axis2_xml_schema_simple_type_union
+ axis2_xml_schema_simple_type_union_t;
+typedef struct axis2_xml_schema_simple_type_union_ops
+ axis2_xml_schema_simple_type_union_ops_t;
+
+struct axis2_xml_schema_simple_type_union_ops
+{
+ /**
+ * Deallocate memory
+ * @return status code
+ */
+ axis2_status_t (AXIS2_CALL *
+ free) (void *simple_type_union,
+ axis2_env_t **env);
+
+ axis2_xml_schema_simple_type_content_t *(AXIS2_CALL *
+ get_base_impl) (void *simple_type_union,
+ axis2_env_t **env);
+
+ axis2_xml_schema_obj_collection_t*(AXIS2_CALL *
+ get_base_types)(void *simple_type_union,
+ axis2_env_t **env);
+
+ axis2_status_t (AXIS2_CALL *
+ set_member_types_source)(void *simple_type_union,
+ axis2_env_t **env,
+ axis2_char_t *member_types_source);
+
+ axis2_char_t* (AXIS2_CALL *
+ get_member_types_source)(void *simple_type_union,
+ axis2_env_t **env);
+
+ axis2_array_list_t* (AXIS2_CALL *
+ get_member_types_qnames)(void *simple_type_union,
+ axis2_env_t **env);
+
+};
+
+struct axis2_xml_schema_simple_type_union
+{
+ axis2_xml_schema_simple_type_content_t base;
+ axis2_xml_schema_simple_type_union_ops_t *ops;
+};
+
+/**
+ * Creates new Xml Schema Particle
+ * Particle types are usually interchangeable.
+ * A local element declaration or reference to a global element
+ * declaration (element), a compositor ( sequence, choice, or all),
+ * a reference to a named content model group (group), or an element wildcard
+ * (any).
+ */
+AXIS2_DECLARE(axis2_xml_schema_simple_type_union_t *)
+axis2_xml_schema_simple_type_union_create(axis2_env_t **env);
+
+/**
+ * This method is internal to Axis2 C. It is called from Child Constructor
+ */
+AXIS2_DECLARE(axis2_status_t)
+axis2_xml_schema_simple_type_union_resolve_methods(
+ axis2_xml_schema_simple_type_union_t *simple_type_union,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_union_t *simple_type_union_impl,
+ axis2_hash_t *methods);
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_UNION_FREE(simple_type_union, env) \
+ (((axis2_xml_schema_simple_type_union_t *) simple_type_union)->ops->\
+ free(simple_type_union, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_UNION_GET_BASE_IMPL(simple_type_union, env) \
+ (((axis2_xml_schema_simple_type_union_t *) simple_type_union)->ops->\
+ get_base_impl(simple_type_union, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_UNION_GET_BASE_TYPES(simple_type_union, env) \
+ (((axis2_xml_schema_simple_type_union_t *) simple_type_union)->ops->\
+ get_max_occurs(simple_type_union, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_UNION_SET_MEMBER_TYPES_SOURCE(simple_type_union,\
+ env, member_types_sources) \
+ (((axis2_xml_schema_simple_type_union_t *) simple_type_union)->ops->\
+ set_member_types_source(simple_type_union, env, member_types_sources))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_UNION_GET_MEMBER_TYPES_SOURCE(simple_type_union, env) \
+ (((axis2_xml_schema_simple_type_union_t *) simple_type_union)->ops->\
+ get_member_types_source(simple_type_union, env))
+
+#define AXIS2_XML_SCHEMA_SIMPLE_TYPE_GET_MEMBER_TYPES_QNAMES(simple_type_union, env) \
+ (((axis2_xml_schema_simple_type_union_t *) simple_type_union)->ops->\
+ set_member_types_qnames(simple_type_union, env))
+
+/** @} */
+#ifdef __cplusplus
+}
+#endif
+#endif /* AXIS2_XML_SCHEMA_SIMPLE_TYPE_UNION_H */
Modified: webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_type.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_type.h?rev=397881&r1=397880&r2=397881&view=diff
==============================================================================
--- webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_type.h (original)
+++ webservices/axis2/trunk/c/include/xml_schema/axis2_xml_schema_type.h Fri Apr 28 05:28:53 2006
@@ -142,22 +142,50 @@
(((axis2_xml_schema_type_t *) type)->ops->\
get_base_impl(type, env))
-#define AXIS2_XML_SCHEMA_TYPE_GET_MAX_OCCURS(type, env) \
+#define AXIS2_XML_SCHEMA_TYPE_GET_BASE_SCHEMA_TYPE(type, env) \
(((axis2_xml_schema_type_t *) type)->ops->\
- get_max_occurs(type, env))
+ get_base_schema_type(type, env))
-#define AXIS2_XML_SCHEMA_TYPE_SET_MAX_OCCURS(type, env, max_occurs) \
+#define AXIS2_XML_SCHEMA_TYPE_GET_DATA_TYPE(type, env, max_occurs) \
(((axis2_xml_schema_type_t *) type)->ops->\
- set_max_occurs(type, env, max_occurs))
+ get_data_type(type, env, max_occurs))
-#define AXIS2_XML_SCHEMA_TYPE_GET_MIN_OCCURS(type, env) \
+#define AXIS2_XML_SCHEMA_TYPE_DERIVE_BY(type, env) \
(((axis2_xml_schema_type_t *) type)->ops->\
- get_min_occurs(type, env))
+ get_derive_by(type, env))
-#define AXIS2_XML_SCHEMA_TYPE_SET_MIN_OCCURS(type, env, min_occurs) \
+#define AXIS2_XML_SCHEMA_TYPE_GET_FINAL(type, env) \
(((axis2_xml_schema_type_t *) type)->ops->\
- set_min_occurs(type, env, min_occurs))
+ get_final(type, env))
+#define AXIS2_XML_SCHEMA_TYPE_SET_FINAL(type, env, final_derivation) \
+ (((axis2_xml_schema_type_t *) type)->ops->\
+ set_final(type, env, final_derivation))
+
+#define AXIS2_XML_SCHEMA_TYPE_GET_FINAL_RESOLVED(type, env) \
+ (((axis2_xml_schema_type_t *) type)->ops->\
+ get_final_resolved(type, env))
+
+#define AXIS2_XML_SCHEMA_TYPE_IS_MIXED(type, env) \
+ (((axis2_xml_schema_type_t *) type)->ops->\
+ get_is_mixed(type, env))
+
+#define AXIS2_XML_SCHEMA_TYPE_SET_MIXED(type, env) \
+ (((axis2_xml_schema_type_t *) type)->ops->\
+ get_set_mixed(type, env))
+
+#define AXIS2_XML_SCHEMA_TYPE_GET_NAME(type, env) \
+ (((axis2_xml_schema_type_t *) type)->ops->\
+ get_name(type, env))
+
+#define AXIS2_XML_SCHEMA_TYPE_SET_NAME(type, env, name) \
+ (((axis2_xml_schema_type_t *) type)->ops->\
+ set_name(type, env, name))
+
+#define AXIS2_XML_SCHEMA_TYPE_GET_QNAME(type, env) \
+ (((axis2_xml_schema_type_t *) type)->ops->\
+ get_qname(type, env))
+
/** @} */
#ifdef __cplusplus
}
Modified: webservices/axis2/trunk/c/modules/xml/om/om_output.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/xml/om/om_output.c?rev=397881&r1=397880&r2=397881&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/xml/om/om_output.c (original)
+++ webservices/axis2/trunk/c/modules/xml/om/om_output.c Fri Apr 28 05:28:53 2006
@@ -796,7 +796,7 @@
axis2_om_output_impl_t *output_impl = NULL;
axis2_char_t *soap_content_type = NULL;
- AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ AXIS2_ENV_CHECK(env, NULL);
output_impl = AXIS2_INTF_TO_IMPL(om_output);
if (output_impl->do_optimize)
Modified: webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema.c?rev=397881&r1=397880&r2=397881&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema.c (original)
+++ webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema.c Fri Apr 28 05:28:53 2006
@@ -100,9 +100,9 @@
axis2_env_t **env);
axis2_status_t AXIS2_CALL
-axis2_xml_schema_set_element_form_default(
- axis2_xml_schema_form_t *element_form_default,
- axis2_env_t **env);
+axis2_xml_schema_set_element_form_default(void *schema,
+ axis2_env_t **env,
+ axis2_xml_schema_form_t *element_form_default);
axis2_xml_schema_obj_table_t *AXIS2_CALL
axis2_xml_schema_get_elements(void *schema,
@@ -123,9 +123,9 @@
axis2_env_t **env);
axis2_status_t AXIS2_CALL
-axis2_xml_schema_set_final_default(
- axis2_xml_schema_derivation_method_t *final_default,
- axis2_env_t **env);
+axis2_xml_schema_set_final_default(void *schema,
+ axis2_env_t **env,
+ axis2_xml_schema_derivation_method_t *final_default);
axis2_xml_schema_obj_table_t *AXIS2_CALL
axis2_xml_schema_get_groups(void *schema,
@@ -170,12 +170,12 @@
axis2_validation_event_handler_t *eh);
axis2_status_t AXIS2_CALL
-axis2_xml_schema_write_a_out(void *schema,
+axis2_xml_schema_write_with_out(void *schema,
axis2_env_t **env,
void *outstream);
axis2_status_t AXIS2_CALL
-axis2_xml_schema_write_a_writer(void *schema,
+axis2_xml_schema_write_with_writer(void *schema,
void *writer);
static axis2_status_t
@@ -278,10 +278,10 @@
axis2_xml_schema_get_version;
schema_impl->schema.ops->compile =
axis2_xml_schema_compile;
- schema_impl->schema.ops->write_a_out =
- axis2_xml_schema_write_a_out;
- schema_impl->schema.ops->write_a_writer =
- axis2_xml_schema_write_a_writer;
+ schema_impl->schema.ops->write_with_out =
+ axis2_xml_schema_write_with_out;
+ schema_impl->schema.ops->write_with_writer =
+ axis2_xml_schema_write_with_writer;
schema_impl->schema.ops->get_prefix_to_namespace_map =
axis2_xml_schema_get_prefix_to_namespace_map;
schema_impl->schema.ops->set_prefix_to_namespace_map =
@@ -346,9 +346,9 @@
axis2_hash_set(schema_impl->methods, "compile",
AXIS2_HASH_KEY_STRING, axis2_xml_schema_compile);
axis2_hash_set(schema_impl->methods, "write_a_out",
- AXIS2_HASH_KEY_STRING, axis2_xml_schema_write_a_out);
+ AXIS2_HASH_KEY_STRING, axis2_xml_schema_write_with_out);
axis2_hash_set(schema_impl->methods, "write_a_writer",
- AXIS2_HASH_KEY_STRING, axis2_xml_schema_write_a_writer);
+ AXIS2_HASH_KEY_STRING, axis2_xml_schema_write_with_writer);
axis2_hash_set(schema_impl->methods, "get_prefix_to_namespace_map",
AXIS2_HASH_KEY_STRING, axis2_xml_schema_get_prefix_to_namespace_map);
axis2_hash_set(schema_impl->methods, "set_prefix_to_namespace_map",
@@ -480,10 +480,10 @@
schema_impl_l->schema.ops->get_version;
schema->ops->compile =
schema_impl_l->schema.ops->compile;
- schema->ops->write_a_out =
- schema_impl_l->schema.ops->write_a_out;
- schema->ops->write_a_writer =
- schema_impl_l->schema.ops->write_a_writer;
+ schema->ops->write_with_out =
+ schema_impl_l->schema.ops->write_with_out;
+ schema->ops->write_with_writer =
+ schema_impl_l->schema.ops->write_with_writer;
schema->ops->get_prefix_to_namespace_map =
schema_impl_l->schema.ops->get_prefix_to_namespace_map;
schema->ops->set_prefix_to_namespace_map =
@@ -576,9 +576,9 @@
}
axis2_status_t AXIS2_CALL
-axis2_xml_schema_set_element_form_default(
- axis2_xml_schema_form_t *element_form_default,
- axis2_env_t **env)
+axis2_xml_schema_set_element_form_default(void *schema,
+ axis2_env_t **env,
+ axis2_xml_schema_form_t *element_form_default)
{
return AXIS2_SUCCESS;
}
@@ -614,9 +614,9 @@
}
axis2_status_t AXIS2_CALL
-axis2_xml_schema_set_final_default(
- axis2_xml_schema_derivation_method_t *final_default,
- axis2_env_t **env)
+axis2_xml_schema_set_final_default(void *schema,
+ axis2_env_t **env,
+ axis2_xml_schema_derivation_method_t *final_default)
{
return AXIS2_SUCCESS;
}
@@ -696,7 +696,7 @@
}
axis2_status_t AXIS2_CALL
-axis2_xml_schema_write_a_out(void *schema,
+axis2_xml_schema_write_with_out(void *schema,
axis2_env_t **env,
void *outstream)
{
@@ -704,7 +704,7 @@
}
axis2_status_t AXIS2_CALL
-axis2_xml_schema_write_a_writer(void *schema,
+axis2_xml_schema_write_with_writer(void *schema,
void *writer)
{
return AXIS2_SUCCESS;
Added: webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_any_attribute.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_any_attribute.c?rev=397881&view=auto
==============================================================================
--- webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_any_attribute.c (added)
+++ webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_any_attribute.c Fri Apr 28 05:28:53 2006
@@ -0,0 +1,304 @@
+/*
+ * 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 <axis2_xml_schema_any_attribute.h>
+
+typedef struct axis2_xml_schema_any_attribute_impl
+ axis2_xml_schema_any_attribute_impl_t;
+
+/**
+ * @brief Other Extension Struct Impl
+ * Axis2 Other Extension
+ */
+struct axis2_xml_schema_any_attribute_impl
+{
+ axis2_xml_schema_any_attribute_t any_attr;
+
+ axis2_xml_schema_annotated_t *annotated;
+
+ axis2_hash_t *methods;
+
+ axis2_xml_schema_content_processing_t *process_content;
+ /**
+ * Namespaces containing the elements that can be used.
+ */
+ axis2_char_t *ns;
+};
+
+#define AXIS2_INTF_TO_IMPL(any_attr) ((axis2_xml_schema_any_attribute_impl_t *) any_attr)
+
+/******************* function prototypes **********************************/
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_any_attribute_free(void *any_attr,
+ axis2_env_t **env);
+
+axis2_xml_schema_annotated_t *AXIS2_CALL
+axis2_xml_schema_any_attribute_get_base_impl(void *any_attr,
+ axis2_env_t **env);
+
+axis2_char_t *AXIS2_CALL
+axis2_xml_schema_any_attribute_get_namespace(void *any_attr,
+ axis2_env_t **env);
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_any_attribute_set_namespace(void *any_attr,
+ axis2_env_t **env,
+ axis2_char_t *ns);
+
+axis2_xml_schema_content_processing_t *AXIS2_CALL
+axis2_xml_schema_any_attribute_get_process_content(void *any_attr,
+ axis2_env_t **env);
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_any_attribute_set_process_content(void *any_attr,
+ axis2_env_t **env,
+ axis2_xml_schema_content_processing_t *process_content);
+
+ /************************ end function prototypes ******************************/
+
+AXIS2_DECLARE(axis2_xml_schema_any_attribute_t *)
+axis2_xml_schema_any_attribute_create(axis2_env_t **env)
+{
+ axis2_xml_schema_any_attribute_impl_t *any_attr_impl = NULL;
+ axis2_status_t status = AXIS2_FAILURE;
+
+ any_attr_impl = AXIS2_MALLOC((*env)->allocator,
+ sizeof(axis2_xml_schema_any_attribute_impl_t));
+ if(!any_attr_impl)
+ {
+ AXIS2_ERROR_SET((*env)->error , AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+ any_attr_impl->any_attr.base.ops = NULL;
+ any_attr_impl->any_attr.ops = NULL;
+ any_attr_impl->ns = NULL;
+ any_attr_impl->annotated = NULL;
+ any_attr_impl->process_content = NULL;
+ any_attr_impl->methods = NULL;
+ any_attr_impl->any_attr.ops = AXIS2_MALLOC((*env)->allocator,
+ sizeof(axis2_xml_schema_any_attribute_ops_t));
+
+ if(!any_attr_impl->any_attr.ops)
+ {
+ axis2_xml_schema_any_attribute_free(&(any_attr_impl->any_attr), env);
+ AXIS2_ERROR_SET((*env)->error ,
+ AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+ any_attr_impl->process_content = axis2_xml_schema_content_processing_create(env,
+ "none");
+ if(!any_attr_impl->process_content)
+ {
+ axis2_xml_schema_any_attribute_free(&(any_attr_impl->any_attr), env);
+ return NULL;
+ }
+ any_attr_impl->any_attr.ops->free =
+ axis2_xml_schema_any_attribute_free;
+ any_attr_impl->any_attr.ops->get_base_impl =
+ axis2_xml_schema_any_attribute_get_base_impl;
+ any_attr_impl->any_attr.ops->get_namespace =
+ axis2_xml_schema_any_attribute_get_namespace;
+ any_attr_impl->any_attr.ops->set_namespace =
+ axis2_xml_schema_any_attribute_set_namespace;
+ any_attr_impl->any_attr.ops->get_process_content =
+ axis2_xml_schema_any_attribute_get_process_content;
+ any_attr_impl->any_attr.ops->set_process_content =
+ axis2_xml_schema_any_attribute_set_process_content;
+
+ any_attr_impl->methods = axis2_hash_make(env);
+ if(!any_attr_impl->methods)
+ {
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+ axis2_hash_set(any_attr_impl->methods, "free", AXIS2_HASH_KEY_STRING,
+ axis2_xml_schema_any_attribute_free);
+ axis2_hash_set(any_attr_impl->methods, "get_namespace", AXIS2_HASH_KEY_STRING,
+ axis2_xml_schema_any_attribute_get_namespace);
+ axis2_hash_set(any_attr_impl->methods, "set_namespace", AXIS2_HASH_KEY_STRING,
+ axis2_xml_schema_any_attribute_set_namespace);
+ axis2_hash_set(any_attr_impl->methods, "get_process_content",
+ AXIS2_HASH_KEY_STRING, axis2_xml_schema_any_attribute_get_process_content);
+ axis2_hash_set(any_attr_impl->methods, "set_process_content",
+ AXIS2_HASH_KEY_STRING, axis2_xml_schema_any_attribute_set_process_content);
+
+ any_attr_impl->annotated = axis2_xml_schema_annotated_create(env);
+ if(!any_attr_impl->methods)
+ {
+ axis2_xml_schema_any_attribute_free(&(any_attr_impl->any_attr), env);
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+ status = axis2_xml_schema_annotated_resolve_methods(
+ &(any_attr_impl->any_attr.base), env, any_attr_impl->annotated,
+ any_attr_impl->methods);
+ return &(any_attr_impl->any_attr);
+}
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_any_attribute_free(void *any_attr,
+ axis2_env_t **env)
+{
+ axis2_xml_schema_any_attribute_impl_t *any_attr_impl = NULL;
+
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ any_attr_impl = AXIS2_INTF_TO_IMPL(any_attr);
+
+ if(NULL != any_attr_impl->ns)
+ {
+ AXIS2_FREE((*env)->allocator, any_attr_impl->ns);
+ any_attr_impl->ns = NULL;
+ }
+
+ if(NULL != any_attr_impl->process_content)
+ {
+ AXIS2_XML_SCHEMA_CONTENT_PROCESSING_FREE(any_attr_impl->process_content, env);
+ any_attr_impl->process_content = NULL;
+ }
+
+ if(NULL != any_attr_impl->methods)
+ {
+ axis2_hash_free(any_attr_impl->methods, env);
+ any_attr_impl->methods = NULL;
+ }
+
+ if(NULL != any_attr_impl->annotated)
+ {
+ AXIS2_XML_SCHEMA_ANNOTATED_FREE(any_attr_impl->annotated, env);
+ any_attr_impl->annotated = NULL;
+ }
+
+ if(NULL != any_attr_impl->any_attr.ops)
+ {
+ AXIS2_FREE((*env)->allocator, any_attr_impl->any_attr.ops);
+ any_attr_impl->any_attr.ops = NULL;
+ }
+ if(NULL != any_attr_impl->any_attr.base.ops)
+ {
+ AXIS2_FREE((*env)->allocator, any_attr_impl->any_attr.base.ops);
+ any_attr_impl->any_attr.base.ops = NULL;
+ }
+
+ AXIS2_FREE((*env)->allocator, any_attr_impl);
+ any_attr_impl = NULL;
+ return AXIS2_SUCCESS;
+}
+
+axis2_xml_schema_annotated_t *AXIS2_CALL
+axis2_xml_schema_any_attribute_get_base_impl(void *any_attr,
+ axis2_env_t **env)
+{
+ axis2_xml_schema_any_attribute_impl_t *any_attr_impl = NULL;
+
+ AXIS2_ENV_CHECK(env, NULL);
+ any_attr_impl = AXIS2_INTF_TO_IMPL(any_attr);
+ return any_attr_impl->annotated;
+}
+
+AXIS2_DECLARE(axis2_status_t)
+axis2_xml_schema_any_attribute_resolve_methods(
+ axis2_xml_schema_any_attribute_t *any_attr,
+ axis2_env_t **env,
+ axis2_xml_schema_any_attribute_t *any_attr_impl,
+ axis2_hash_t *methods)
+{
+ axis2_xml_schema_any_attribute_impl_t *any_impl_l = NULL;
+
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ AXIS2_PARAM_CHECK((*env)->error, any_attr_impl, AXIS2_FAILURE);
+ AXIS2_PARAM_CHECK((*env)->error, methods, AXIS2_FAILURE);
+
+ any_impl_l = (axis2_xml_schema_any_attribute_impl_t *) any_attr_impl;
+
+ any_attr->ops = AXIS2_MALLOC((*env)->allocator,
+ sizeof(axis2_xml_schema_any_attribute_ops_t));
+ if(NULL != any_attr->ops)
+ {
+ AXIS2_ERROR_SET((*env)->error,
+ AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return AXIS2_FAILURE;
+ }
+
+ any_attr->ops->free = axis2_hash_get(methods, "free",
+ AXIS2_HASH_KEY_STRING);
+ any_attr->ops->get_base_impl =
+ any_impl_l->any_attr.ops->get_base_impl;
+ any_attr->ops->get_namespace =
+ any_impl_l->any_attr.ops->get_namespace;
+ any_attr->ops->set_namespace =
+ any_impl_l->any_attr.ops->set_namespace;
+ any_attr->ops->get_process_content =
+ any_impl_l->any_attr.ops->get_process_content;
+ any_attr->ops->set_process_content =
+ any_impl_l->any_attr.ops->set_process_content;
+
+ return axis2_xml_schema_annotated_resolve_methods(&(any_attr->base),
+ env, any_impl_l->annotated, methods);
+}
+
+axis2_char_t *AXIS2_CALL
+axis2_xml_schema_any_attribute_get_namespace(void *any_attr,
+ axis2_env_t **env)
+{
+ return AXIS2_INTF_TO_IMPL(any_attr)->ns;
+}
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_any_attribute_set_namespace(void *any_attr,
+ axis2_env_t **env,
+ axis2_char_t *namespc)
+{
+ axis2_xml_schema_any_attribute_impl_t *any_attr_impl = NULL;
+
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ any_attr_impl = AXIS2_INTF_TO_IMPL(any_attr);
+
+ if(!any_attr_impl->ns)
+ {
+ AXIS2_FREE((*env)->allocator, any_attr_impl->ns);
+ any_attr_impl->ns = NULL;
+ }
+ any_attr_impl->ns = AXIS2_STRDUP(any_attr_impl->ns, env);
+ return AXIS2_SUCCESS;
+}
+
+axis2_xml_schema_content_processing_t *AXIS2_CALL
+axis2_xml_schema_any_attribute_get_process_content(void *any_attr,
+ axis2_env_t **env)
+{
+ return AXIS2_INTF_TO_IMPL(any_attr)->process_content;
+}
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_any_attribute_set_process_content(void *any_attr,
+ axis2_env_t **env,
+ axis2_xml_schema_content_processing_t *
+ process_content)
+{
+ axis2_xml_schema_any_attribute_impl_t *any_attr_impl = NULL;
+
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ any_attr_impl = AXIS2_INTF_TO_IMPL(any_attr);
+
+ if(!any_attr_impl->process_content)
+ {
+ AXIS2_XML_SCHEMA_CONTENT_PROCESSING_FREE(any_attr_impl->process_content, env);
+ any_attr_impl->process_content = NULL;
+ }
+ any_attr_impl->process_content = process_content;
+ return AXIS2_SUCCESS;
+}
+
Modified: webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_identity_constraint.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_identity_constraint.c?rev=397881&r1=397880&r2=397881&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_identity_constraint.c (original)
+++ webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_identity_constraint.c Fri Apr 28 05:28:53 2006
@@ -1,4 +1,4 @@
- /*
+/*
* Copyright 2004,2005 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
@@ -18,7 +18,8 @@
#include <axis2_xml_schema_obj_collection.h>
#include <axis2_xml_schema_xpath.h>
-typedef struct axis2_xml_schema_identity_constraint_impl axis2_xml_schema_identity_constraint_impl_t;
+typedef struct axis2_xml_schema_identity_constraint_impl
+ axis2_xml_schema_identity_constraint_impl_t;
/**
* @brief Other Extension Struct Impl
@@ -74,6 +75,11 @@
identity_constraint_impl = AXIS2_MALLOC((*env)->allocator,
sizeof(axis2_xml_schema_identity_constraint_impl_t));
+ if(!identity_constraint_impl)
+ {
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
identity_constraint_impl->annotated = NULL;
identity_constraint_impl->methods = NULL;
@@ -82,7 +88,13 @@
identity_constraint_impl->selector = NULL;
identity_constraint_impl->identity_constraint.ops = AXIS2_MALLOC((*env)->allocator,
sizeof(axis2_xml_schema_identity_constraint_ops_t));
-
+ if(!(identity_constraint_impl->identity_constraint.ops))
+ {
+ axis2_xml_schema_identity_constraint_free(
+ &(identity_constraint_impl->identity_constraint), env);
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
identity_constraint_impl->identity_constraint.ops->free =
axis2_xml_schema_identity_constraint_free;
identity_constraint_impl->identity_constraint.ops->get_base_impl =
@@ -118,10 +130,12 @@
AXIS2_HASH_KEY_STRING, axis2_xml_schema_identity_constraint_set_selector);
identity_constraint_impl->annotated = axis2_xml_schema_annotated_create(env);
+ if(!identity_constraint_impl->annotated)
+ return NULL;
status = axis2_xml_schema_annotated_resolve_methods(
- &(identity_constraint_impl->identity_constraint.base), env, identity_constraint_impl->annotated,
+ &(identity_constraint_impl->identity_constraint.base),
+ env, identity_constraint_impl->annotated,
identity_constraint_impl->methods);
-
return &(identity_constraint_impl->identity_constraint);
}
@@ -134,37 +148,42 @@
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
identity_constraint_impl = AXIS2_INTF_TO_IMPL(identity_constraint);
- if(identity_constraint_impl->name)
+ if(NULL != identity_constraint_impl->name)
{
AXIS2_FREE((*env)->allocator, identity_constraint_impl->name);
identity_constraint_impl->name = NULL;
}
- if(identity_constraint_impl->selector)
+ if(NULL != identity_constraint_impl->selector)
{
AXIS2_XML_SCHEMA_XPATH_FREE(identity_constraint_impl->selector, env);
identity_constraint_impl->selector = NULL;
}
- if(identity_constraint_impl->methods)
+ if(NULL != identity_constraint_impl->methods)
{
axis2_hash_free(identity_constraint_impl->methods, env);
identity_constraint_impl->methods = NULL;
}
- if(identity_constraint_impl->annotated)
+ if(NULL != identity_constraint_impl->annotated)
{
AXIS2_XML_SCHEMA_ANNOTATED_FREE(identity_constraint_impl->annotated, env);
identity_constraint_impl->annotated = NULL;
}
- if((&(identity_constraint_impl->identity_constraint))->ops)
+ if(NULL != identity_constraint_impl->identity_constraint.ops)
{
- AXIS2_FREE((*env)->allocator, (&(identity_constraint_impl->identity_constraint))->ops);
- (&(identity_constraint_impl->identity_constraint))->ops = NULL;
+ AXIS2_FREE((*env)->allocator, identity_constraint_impl->identity_constraint.ops);
+ identity_constraint_impl->identity_constraint.ops = NULL;
+ }
+ if(NULL != identity_constraint_impl->identity_constraint.base.ops)
+ {
+ AXIS2_FREE((*env)->allocator, identity_constraint_impl->identity_constraint.base.ops);
+ identity_constraint_impl->identity_constraint.base.ops = NULL;
}
- if(identity_constraint_impl)
+ if(NULL != identity_constraint_impl)
{
AXIS2_FREE((*env)->allocator, identity_constraint_impl);
identity_constraint_impl = NULL;
@@ -201,6 +220,11 @@
identity_constraint->ops = AXIS2_MALLOC((*env)->allocator,
sizeof(axis2_xml_schema_identity_constraint_ops_t));
+ if(NULL == identity_constraint->ops)
+ {
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return AXIS2_FAILURE;
+ }
identity_constraint->ops->free = axis2_hash_get(methods, "free",
AXIS2_HASH_KEY_STRING);
identity_constraint->ops->get_base_impl =
Added: webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type.c?rev=397881&view=auto
==============================================================================
--- webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type.c (added)
+++ webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type.c Fri Apr 28 05:28:53 2006
@@ -0,0 +1,268 @@
+/*
+ * 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 <axis2_xml_schema.h>
+#include <axis2_xml_schema_constants.h>
+#include <axis2_xml_schema_simple_type.h>
+#include <axis2_xml_schema_data_type.h>
+#include <axis2_xml_schema_derivation_method.h>
+
+#include <axis2_qname.h>
+
+typedef struct axis2_xml_schema_simple_type_impl
+ axis2_xml_schema_simple_type_impl_t;
+
+/**
+ * @brief Other Extension Struct Impl
+ * Axis2 Other Extension
+ */
+struct axis2_xml_schema_simple_type_impl
+{
+ axis2_xml_schema_simple_type_t simple_type;
+ /** parent type */
+ axis2_xml_schema_type_t *schema_type;
+
+ axis2_hash_t *methods;
+
+ axis2_xml_schema_simple_type_content_t *content;
+};
+
+#define AXIS2_INTF_TO_IMPL(simple_type) ((axis2_xml_schema_simple_type_impl_t *) simple_type)
+
+/************************** function prototypes ******************************/
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_simple_type_free(void *simple_type,
+ axis2_env_t **env);
+
+axis2_xml_schema_type_t *AXIS2_CALL
+axis2_xml_schema_simple_type_get_base_impl(void *simple_type,
+ axis2_env_t **env);
+
+axis2_xml_schema_simple_type_content_t* AXIS2_CALL
+axis2_xml_schema_simple_type_get_content(void *simple_type,
+ axis2_env_t **env);
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_simple_type_set_content(void *simple_type,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_content_t *simple_content);
+
+axis2_char_t* AXIS2_CALL
+axis2_xml_schema_simple_type_to_string(void *simple_type,
+ axis2_env_t **env,
+ axis2_char_t *prefix,
+ int tab);
+
+/************************** end ****************************************/
+
+AXIS2_DECLARE(axis2_xml_schema_simple_type_t *)
+axis2_xml_schema_simple_type_create(axis2_env_t **env,
+ axis2_xml_schema_t *schema)
+{
+ axis2_xml_schema_simple_type_impl_t *simple_type = NULL;
+ axis2_status_t status = AXIS2_FAILURE;
+
+ simple_type = AXIS2_MALLOC((*env)->allocator,
+ sizeof(axis2_xml_schema_simple_type_impl_t));
+ if(!simple_type)
+ {
+ AXIS2_ERROR_SET((*env)->error,
+ AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+
+ simple_type->methods = NULL;
+ simple_type->content = NULL;
+ simple_type->schema_type = NULL;
+ simple_type->simple_type.ops = NULL;
+ simple_type->simple_type.base.ops = NULL;
+
+ simple_type->simple_type.ops = AXIS2_MALLOC((*env)->allocator,
+ sizeof(axis2_xml_schema_simple_type_ops_t));
+ if(!simple_type->simple_type.ops)
+ {
+ axis2_xml_schema_simple_type_free(&(simple_type->simple_type), env);
+ AXIS2_ERROR_SET((*env)->error,
+ AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+
+ simple_type->schema_type = axis2_xml_schema_type_create(env, schema);
+ if(!simple_type->schema_type)
+ {
+ axis2_xml_schema_simple_type_free(&(simple_type->schema_type), env);
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+
+ simple_type->simple_type.ops->free =
+ axis2_xml_schema_simple_type_free;
+
+ simple_type->simple_type.ops->get_base_impl =
+ axis2_xml_schema_simple_type_get_base_impl;
+
+ simple_type->simple_type.ops->get_content =
+ axis2_xml_schema_simple_type_get_content;
+
+ simple_type->simple_type.ops->set_content =
+ axis2_xml_schema_simple_type_set_content;
+
+ simple_type->methods = axis2_hash_make(env);
+ if(!simple_type->methods)
+ {
+ axis2_xml_schema_simple_type_free(&(simple_type->simple_type), env);
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+
+ axis2_hash_set(simple_type->methods, "free", AXIS2_HASH_KEY_STRING,
+ axis2_xml_schema_simple_type_free);
+ axis2_hash_set(simple_type->methods, "get_content",
+ AXIS2_HASH_KEY_STRING, axis2_xml_schema_simple_type_get_content);
+ axis2_hash_set(simple_type->methods, "set_content",
+ AXIS2_HASH_KEY_STRING, axis2_xml_schema_simple_type_set_content);
+
+ status = axis2_xml_schema_type_resolve_methods(&(simple_type->simple_type.base),
+ env, simple_type->schema_type, simple_type->methods);
+
+ return &(simple_type->simple_type);
+}
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_simple_type_free(void *simple_type,
+ axis2_env_t **env)
+{
+ axis2_xml_schema_simple_type_impl_t *simple_type_impl = NULL;
+
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ simple_type_impl = AXIS2_INTF_TO_IMPL(simple_type);
+
+ if(NULL != simple_type_impl->methods)
+ {
+ axis2_hash_free(simple_type_impl->methods, env);
+ simple_type_impl->methods = NULL;
+ }
+
+ if(NULL != simple_type_impl->schema_type)
+ {
+ AXIS2_XML_SCHEMA_TYPE_FREE(simple_type_impl->schema_type, env);
+ simple_type_impl->schema_type = NULL;
+ }
+
+ if(NULL != simple_type_impl->simple_type.ops)
+ {
+ AXIS2_FREE((*env)->allocator, simple_type_impl->simple_type.ops);
+ simple_type_impl->simple_type.ops = NULL;
+ }
+ if(NULL != simple_type_impl->simple_type.base.ops)
+ {
+ AXIS2_FREE((*env)->allocator, simple_type_impl->simple_type.base.ops);
+ simple_type_impl->simple_type.base.ops = NULL;
+ }
+ AXIS2_FREE((*env)->allocator, simple_type_impl);
+ simple_type_impl = NULL;
+ return AXIS2_SUCCESS;
+}
+
+axis2_xml_schema_type_t *AXIS2_CALL
+axis2_xml_schema_simple_type_get_base_impl(void *simple_type,
+ axis2_env_t **env)
+{
+ axis2_xml_schema_simple_type_impl_t *simple_type_impl = NULL;
+
+ AXIS2_ENV_CHECK(env, NULL);
+ simple_type_impl = AXIS2_INTF_TO_IMPL(simple_type);
+ return simple_type_impl->schema_type;
+
+}
+
+AXIS2_DECLARE(axis2_status_t)
+axis2_xml_schema_simple_type_resolve_methods(
+ axis2_xml_schema_simple_type_t *simple_type,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_t *simple_type_impl,
+ axis2_hash_t *methods)
+{
+ axis2_xml_schema_simple_type_impl_t *type_impl_l = NULL;
+
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ AXIS2_PARAM_CHECK((*env)->error, simple_type, AXIS2_FAILURE);
+ AXIS2_PARAM_CHECK((*env)->error, methods, AXIS2_FAILURE);
+
+ type_impl_l = (axis2_xml_schema_simple_type_impl_t *) simple_type_impl;
+
+ simple_type->ops = AXIS2_MALLOC((*env)->allocator,
+ sizeof(axis2_xml_schema_simple_type_ops_t));
+ if(!simple_type->ops)
+ {
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return AXIS2_FAILURE;
+ }
+
+ simple_type->ops->free = axis2_hash_get(methods, "free",
+ AXIS2_HASH_KEY_STRING);
+ simple_type->ops->get_base_impl =
+ type_impl_l->simple_type.ops->get_base_impl;
+ simple_type->ops->get_content =
+ type_impl_l->simple_type.ops->get_content;
+ simple_type->ops->set_content =
+ type_impl_l->simple_type.ops->set_content;
+
+ return axis2_xml_schema_type_resolve_methods(&(simple_type->base),
+ env, type_impl_l->schema_type , methods);
+}
+
+axis2_xml_schema_simple_type_content_t* AXIS2_CALL
+axis2_xml_schema_simple_type_get_content(void *simple_type,
+ axis2_env_t **env)
+{
+ axis2_xml_schema_simple_type_impl_t *simple_type_impl = NULL;
+ AXIS2_ENV_CHECK(env, NULL);
+ simple_type_impl = AXIS2_INTF_TO_IMPL(simple_type);
+ return simple_type_impl->content;
+}
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_simple_type_set_content(void *simple_type,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_content_t *simple_content)
+{
+ axis2_xml_schema_simple_type_impl_t *simple_type_impl = NULL;
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ simple_type_impl = AXIS2_INTF_TO_IMPL(simple_type);
+ if(NULL != simple_type_impl->content)
+ {
+ AXIS2_XML_SCHEMA_SIMPLE_TYPE_CONTENT_FREE(simple_type_impl->content, env);
+ simple_type_impl->content = NULL;
+ }
+ simple_type_impl->content = simple_content;
+ return AXIS2_SUCCESS;
+}
+
+axis2_char_t* AXIS2_CALL
+axis2_xml_schema_simple_type_to_string(void *simple_type,
+ axis2_env_t **env,
+ axis2_char_t *prefix,
+ int tab)
+{
+ axis2_xml_schema_simple_type_impl_t *simple_type_impl = NULL;
+ AXIS2_ENV_CHECK(env, NULL);
+ simple_type_impl = AXIS2_INTF_TO_IMPL(simple_type);
+ /** TODO implement the method */
+ return NULL;
+}
+
Added: webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type_content.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type_content.c?rev=397881&view=auto
==============================================================================
--- webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type_content.c (added)
+++ webservices/axis2/trunk/c/modules/xml/xml_schema/xml_schema_simple_type_content.c Fri Apr 28 05:28:53 2006
@@ -0,0 +1,234 @@
+/*
+ * 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 <axis2_xml_schema_simple_type_content.h>
+
+typedef struct axis2_xml_schema_simple_type_content_impl
+ axis2_xml_schema_simple_type_content_impl_t;
+
+/**
+ * @brief Other Extension Struct Impl
+ * Axis2 Other Extension
+ */
+struct axis2_xml_schema_simple_type_content_impl
+{
+ axis2_xml_schema_simple_type_content_t sim_type_cont;
+
+ axis2_xml_schema_annotated_t *annotated;
+
+ int type;
+
+ axis2_hash_t *methods;
+
+};
+
+#define AXIS2_INTF_TO_IMPL(sim_type_cont) \
+ ((axis2_xml_schema_simple_type_content_impl_t *) sim_type_cont)
+
+/*************** function prototypes *****************************************/
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_simple_type_content_free(void *sim_type_cont,
+ axis2_env_t **env);
+
+axis2_xml_schema_annotated_t *AXIS2_CALL
+axis2_xml_schema_simple_type_content_get_base_impl(void *sim_type_cont,
+ axis2_env_t **env);
+
+int AXIS2_CALL
+axis2_xml_schema_simple_type_content_get_type(void *sim_type_cont,
+ axis2_env_t **env);
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_simple_type_content_set_type(void *sim_type_cont,
+ axis2_env_t **env,
+ int type);
+
+/*************** function prototypes *****************************************/
+
+AXIS2_DECLARE(axis2_xml_schema_simple_type_content_t *)
+axis2_xml_schema_simple_type_content_create(axis2_env_t **env)
+{
+ axis2_xml_schema_simple_type_content_impl_t *sim_type_cont_impl = NULL;
+ axis2_status_t status = AXIS2_FAILURE;
+
+ sim_type_cont_impl = AXIS2_MALLOC((*env)->allocator,
+ sizeof(axis2_xml_schema_simple_type_content_impl_t));
+
+ if(!sim_type_cont_impl)
+ {
+ AXIS2_ERROR_SET((*env)->error,
+ AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+ sim_type_cont_impl->annotated = NULL;
+ sim_type_cont_impl->sim_type_cont.ops = NULL;
+ sim_type_cont_impl->sim_type_cont.base.ops = NULL;
+ sim_type_cont_impl->methods = NULL;
+ sim_type_cont_impl->type = AXIS2_XML_SCHEMA_SIMPLE_CONTENT_TYPE;
+
+
+ sim_type_cont_impl->sim_type_cont.ops = AXIS2_MALLOC((*env)->allocator,
+ sizeof(axis2_xml_schema_simple_type_content_ops_t));
+
+ if(!sim_type_cont_impl->sim_type_cont.ops)
+ {
+ axis2_xml_schema_simple_type_content_free(&(sim_type_cont_impl->sim_type_cont), env);
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+
+ sim_type_cont_impl->sim_type_cont.ops->free =
+ axis2_xml_schema_simple_type_content_free;
+ sim_type_cont_impl->sim_type_cont.ops->get_base_impl =
+ axis2_xml_schema_simple_type_content_get_base_impl;
+ sim_type_cont_impl->sim_type_cont.ops->get_type =
+ axis2_xml_schema_simple_type_content_get_type;
+ sim_type_cont_impl->sim_type_cont.ops->set_type =
+ axis2_xml_schema_simple_type_content_set_type;
+
+ sim_type_cont_impl->methods = axis2_hash_make(env);
+ if(!sim_type_cont_impl->methods)
+ {
+ axis2_xml_schema_simple_type_content_free(&(sim_type_cont_impl->sim_type_cont), env);
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return NULL;
+ }
+ axis2_hash_set(sim_type_cont_impl->methods, "free", AXIS2_HASH_KEY_STRING,
+ axis2_xml_schema_simple_type_content_free);
+ axis2_hash_set(sim_type_cont_impl->methods, "get_type",
+ AXIS2_HASH_KEY_STRING, axis2_xml_schema_simple_type_content_get_type);
+ axis2_hash_set(sim_type_cont_impl->methods, "set_type",
+ AXIS2_HASH_KEY_STRING, axis2_xml_schema_simple_type_content_set_type);
+
+ sim_type_cont_impl->annotated = axis2_xml_schema_annotated_create(env);
+ if(!sim_type_cont_impl->annotated)
+ {
+ axis2_xml_schema_simple_type_content_free(&(sim_type_cont_impl->sim_type_cont), env);
+ return NULL;
+ }
+ status = axis2_xml_schema_annotated_resolve_methods(
+ &(sim_type_cont_impl->sim_type_cont.base), env, sim_type_cont_impl->annotated,
+ sim_type_cont_impl->methods);
+
+ return &(sim_type_cont_impl->sim_type_cont);
+}
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_simple_type_content_free(void *sim_type_cont,
+ axis2_env_t **env)
+{
+ axis2_xml_schema_simple_type_content_impl_t *sim_type_cont_impl = NULL;
+
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ sim_type_cont_impl = AXIS2_INTF_TO_IMPL(sim_type_cont);
+
+ if(NULL != sim_type_cont_impl->methods)
+ {
+ axis2_hash_free(sim_type_cont_impl->methods, env);
+ sim_type_cont_impl->methods = NULL;
+ }
+
+ if(NULL != sim_type_cont_impl->annotated)
+ {
+ AXIS2_XML_SCHEMA_ANNOTATED_FREE(sim_type_cont_impl->annotated, env);
+ sim_type_cont_impl->annotated = NULL;
+ }
+
+ if(NULL != sim_type_cont_impl->sim_type_cont.ops)
+ {
+ AXIS2_FREE((*env)->allocator, sim_type_cont_impl->sim_type_cont.ops);
+ sim_type_cont_impl->sim_type_cont.ops = NULL;
+ }
+ if(NULL != sim_type_cont_impl->sim_type_cont.base.ops)
+ {
+ AXIS2_FREE((*env)->allocator, sim_type_cont_impl->sim_type_cont.base.ops);
+ sim_type_cont_impl->sim_type_cont.base.ops = NULL;
+ }
+
+ if(NULL != sim_type_cont_impl)
+ {
+ AXIS2_FREE((*env)->allocator, sim_type_cont_impl);
+ sim_type_cont_impl = NULL;
+ }
+ return AXIS2_SUCCESS;
+}
+
+axis2_xml_schema_annotated_t *AXIS2_CALL
+axis2_xml_schema_simple_type_content_get_base_impl(void *sim_type_cont,
+ axis2_env_t **env)
+{
+ axis2_xml_schema_simple_type_content_impl_t *sim_type_cont_impl = NULL;
+ AXIS2_ENV_CHECK(env, NULL);
+ sim_type_cont_impl = AXIS2_INTF_TO_IMPL(sim_type_cont);
+ return sim_type_cont_impl->annotated;
+}
+
+AXIS2_DECLARE(axis2_status_t)
+axis2_xml_schema_simple_type_content_resolve_methods(
+ axis2_xml_schema_simple_type_content_t *sim_type_cont,
+ axis2_env_t **env,
+ axis2_xml_schema_simple_type_content_t *sim_type_cont_impl,
+ axis2_hash_t *methods)
+{
+ axis2_xml_schema_simple_type_content_impl_t *sim_type_cont_impl_l = NULL;
+
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ AXIS2_PARAM_CHECK((*env)->error, sim_type_cont_impl, AXIS2_FAILURE);
+ AXIS2_PARAM_CHECK((*env)->error, methods, AXIS2_FAILURE);
+
+ sim_type_cont_impl_l =
+ (axis2_xml_schema_simple_type_content_impl_t *) sim_type_cont_impl;
+
+ sim_type_cont->ops = AXIS2_MALLOC((*env)->allocator,
+ sizeof(axis2_xml_schema_simple_type_content_ops_t));
+ if(NULL != sim_type_cont->ops)
+ {
+ AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ return AXIS2_FAILURE;
+ }
+
+ sim_type_cont->ops->free = axis2_hash_get(methods, "free",
+ AXIS2_HASH_KEY_STRING);
+ sim_type_cont->ops->get_base_impl =
+ sim_type_cont_impl_l->sim_type_cont.ops->get_base_impl;
+ sim_type_cont->ops->get_type =
+ sim_type_cont_impl_l->sim_type_cont.ops->get_type;
+ sim_type_cont->ops->set_type =
+ sim_type_cont_impl_l->sim_type_cont.ops->set_type;
+
+ return axis2_xml_schema_annotated_resolve_methods(&(sim_type_cont->base),
+ env, sim_type_cont_impl_l->annotated, methods);
+}
+
+int AXIS2_CALL
+axis2_xml_schema_simple_type_content_get_type(void *sim_type_cont,
+ axis2_env_t **env)
+{
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ return AXIS2_INTF_TO_IMPL(sim_type_cont)->type;
+}
+
+axis2_status_t AXIS2_CALL
+axis2_xml_schema_simple_type_content_set_type(void *sim_type_cont,
+ axis2_env_t **env,
+ int type)
+{
+ AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+ AXIS2_INTF_TO_IMPL(sim_type_cont)->type = type;
+ return AXIS2_SUCCESS;
+}
+