axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sam...@apache.org
Subject svn commit: r354647 - in /webservices/axis2/trunk/c: include/axis2_msg_info_headers.h modules/core/addr/src/Makefile.am modules/core/addr/src/msg_info_headers.c
Date Wed, 07 Dec 2005 01:37:03 GMT
Author: samisa
Date: Tue Dec  6 17:36:55 2005
New Revision: 354647

URL: http://svn.apache.org/viewcvs?rev=354647&view=rev
Log:
Initial version of message information header

Added:
    webservices/axis2/trunk/c/include/axis2_msg_info_headers.h
    webservices/axis2/trunk/c/modules/core/addr/src/msg_info_headers.c
Modified:
    webservices/axis2/trunk/c/modules/core/addr/src/Makefile.am

Added: webservices/axis2/trunk/c/include/axis2_msg_info_headers.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/axis2_msg_info_headers.h?rev=354647&view=auto
==============================================================================
--- webservices/axis2/trunk/c/include/axis2_msg_info_headers.h (added)
+++ webservices/axis2/trunk/c/include/axis2_msg_info_headers.h Tue Dec  6 17:36:55 2005
@@ -0,0 +1,204 @@
+/*
+ * 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_MSG_INFO_HEADERS_H
+#define AXIS2_MSG_INFO_HEADERS_H
+
+/**
+ * @file axis2_msg_info_headers.h
+ * @brief Axis2 core addressing interface
+ */
+
+#include <axis2_defines.h>
+#include <axis2_env.h>
+#include <axis2.h>
+#include <axis2_array_list.h>
+#include <axis2_endpoint_ref.h>
+#include <axis2_any_content_type.h>
+#include <axis2_svc_name.h>
+#include <axis2_relates_to.h>
+#include <axis2_om_node.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+    struct axis2_msg_info_headers;
+    struct axis2_msg_info_headers_ops;
+    
+/**
+ * @defgroup axis2_msg_info_headers Addressing relates to header
+ * @ingroup axis2_addr
+ * @{
+ */
+
+/**
+ *   \brief Dispatcher operations struct
+ */
+ AXIS2_DECLARE_DATA typedef struct axis2_msg_info_headers_ops
+    { 
+        /**
+         * Method getTo
+         *
+         * @return
+         */
+        axis2_endpoint_ref_t* (AXIS2_CALL *get_to)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env); 
+        /**
+         * Method set_to
+         *
+         * @param to
+         */
+        axis2_status_t (AXIS2_CALL *set_to)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env, axis2_endpoint_ref_t
*to);
+        /**
+         * Method getFrom
+         *
+         * @return
+         */
+        axis2_endpoint_ref_t* (AXIS2_CALL *get_from)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env);
+        /**
+         * Method set_from
+         *
+         * @param from
+         */
+        axis2_status_t (AXIS2_CALL *set_from)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env, axis2_endpoint_ref_t
*from);
+        /**
+         * Method getReply_to
+         *
+         * @return
+         */
+        axis2_endpoint_ref_t* (AXIS2_CALL *get_reply_to)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env);
+        /**
+         * Method set_reply_to
+         *
+         * @param reply_to
+         */
+        axis2_status_t (AXIS2_CALL *set_reply_to)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env, axis2_endpoint_ref_t
*reply_to);
+        /**
+         * Method getFault_to
+         *
+         * @return
+         */
+        axis2_endpoint_ref_t* (AXIS2_CALL *get_fault_to)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env);
+        /**
+         * Method set_fault_to
+         *
+         * @param fault_to
+         */
+        axis2_status_t (AXIS2_CALL *set_fault_to)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env, axis2_endpoint_ref_t
*fault_to);
+        /**
+         * Method get_action
+         *
+         * @return
+         */
+        axis2_char_t* (AXIS2_CALL *get_action)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env);
+        /**
+         * Method set_action
+         *
+         * @param action
+         */
+        axis2_status_t (AXIS2_CALL *set_action)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env, axis2_char_t *action);
+        /**
+         * Method get_message_id
+         *
+         * @return
+         */
+        axis2_char_t* (AXIS2_CALL *get_message_id)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env);
+        /**
+         * Method set_message_id
+         *
+         * @param message_id
+         */
+        axis2_status_t (AXIS2_CALL *set_message_id)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env, axis2_char_t *message_id);
+        /**
+         * Method get_relates_to
+         *
+         * @return
+         */
+        axis2_relates_to_t* (AXIS2_CALL *get_relates_to)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env);
+        /**
+         * Method set_relates_to
+         *
+         * @param relates_to
+         */
+        axis2_status_t (AXIS2_CALL *set_relates_to)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env, axis2_relates_to_t
*relates_to);
+        axis2_array_list_t* (AXIS2_CALL *get_ref_params)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env);
+        axis2_status_t (AXIS2_CALL *add_ref_param)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env, axis2_om_node_t
*ref_param);
+        axis2_status_t (AXIS2_CALL *free)(struct axis2_msg_info_headers *msg_info_headers,

+                                                       axis2_env_t **env);
+    } axis2_msg_info_headers_ops_t;
+	
+   /** 
+    * \brief Dispatcher struct
+    */
+    typedef struct axis2_msg_info_headers
+    {
+        /** Dispatcher related operations */
+        axis2_msg_info_headers_ops_t *ops;
+    } axis2_msg_info_headers_t;
+
+
+/**
+ * creates msg_info_headers struct
+ *
+ * @param value
+ * @param relationship_type
+ */
+AXIS2_DECLARE(axis2_msg_info_headers_t*) axis2_msg_info_headers_create(axis2_env_t **env,
axis2_endpoint_ref_t *to,
+                                           axis2_char_t *action);
+    
+
+#define AXIS2_MSG_INFO_HEADERS_GET_TO(msg_info_headers, env) ((msg_info_headers)->ops->get_to(msg_info_headers,
env)) 
+#define AXIS2_MSG_INFO_HEADERS_SET_TO(msg_info_headers, env, to) ((msg_info_headers)->ops->set_to(msg_info_headers,
env, to))
+#define AXIS2_MSG_INFO_HEADERS_GET_FROM(msg_info_headers, env) ((msg_info_headers)->ops->get_from(msg_info_headers,
env))
+#define AXIS2_MSG_INFO_HEADERS_SET_FROM(msg_info_headers, env, from) ((msg_info_headers)->ops->set_from(msg_info_headers,
env, from))
+#define AXIS2_MSG_INFO_HEADERS_GET_REPLY_TO(msg_info_headers, env) ((msg_info_headers)->ops->get_reply_to(msg_info_headers,
env))
+#define AXIS2_MSG_INFO_HEADERS_SET_REPLY_TO(msg_info_headers, env, reply_to) ((msg_info_headers)->ops->set_reply_to(msg_info_headers,
env, reply_to))
+#define AXIS2_MSG_INFO_HEADERS_GET_FAULT_TO(msg_info_headers, env) ((msg_info_headers)->ops->get_fault_to(msg_info_headers,
env))
+#define AXIS2_MSG_INFO_HEADERS_SET_FAULT_TO(msg_info_headers, env, fault_to) ((msg_info_headers)->ops->set_fault_to(msg_info_headers,
env, fault_to))
+#define AXIS2_MSG_INFO_HEADERS_GET_ACTION(msg_info_headers, env) ((msg_info_headers)->ops->get_action(msg_info_headers,
env))
+#define AXIS2_MSG_INFO_HEADERS_SET_ACTION(msg_info_headers, env, action) ((msg_info_headers)->ops->set_action(msg_info_headers,
env, action))
+#define AXIS2_MSG_INFO_HEADERS_GET_MESSAGE_ID(msg_info_headers, env) ((msg_info_headers)->ops->get_message_id(msg_info_headers,
env))
+#define AXIS2_MSG_INFO_HEADERS_SET_MESSAGE_ID(msg_info_headers, env, message_id) ((msg_info_headers)->ops->set_message_id(msg_info_headers,
env, message_id))
+#define AXIS2_MSG_INFO_HEADERS_GET_RELATES_TO(msg_info_headers, env) ((msg_info_headers)->ops->get_relates_to(msg_info_headers,
env))
+#define AXIS2_MSG_INFO_HEADERS_SET_RELATES_TO(msg_info_headers, env, relates_to) ((msg_info_headers)->ops->set_relates_to(msg_info_headers,
env, relates_to))
+#define AXIS2_MSG_INFO_HEADERS_GET_REF_PARAMS(msg_info_headers, env) ((msg_info_headers)->ops->get_ref_params(msg_info_headers,
env))
+#define AXIS2_MSG_INFO_HEADERS_ADD_REF_PARAM(msg_info_headers, env, ref_param) ((msg_info_headers)->ops->add_ref_param(msg_info_headers,
env, ref_param))
+#define AXIS2_MSG_INFO_HEADERS_FREE(msg_info_headers, env) ((msg_info_headers)->ops->free(msg_info_headers,
env))
+
+/** @} */
+    
+#ifdef __cplusplus
+}
+#endif
+
+#endif    /* AXIS2_MSG_INFO_HEADERS_H */

Modified: webservices/axis2/trunk/c/modules/core/addr/src/Makefile.am
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/addr/src/Makefile.am?rev=354647&r1=354646&r2=354647&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/addr/src/Makefile.am (original)
+++ webservices/axis2/trunk/c/modules/core/addr/src/Makefile.am Tue Dec  6 17:36:55 2005
@@ -1,6 +1,6 @@
 lib_LTLIBRARIES = libaxis2_addr.la
 AM_CPPFLAGS = $(CPPFLAGS)
-libaxis2_addr_la_SOURCES = relates_to.c svc_name.c any_content_type.c endpoint_ref.c
+libaxis2_addr_la_SOURCES = relates_to.c svc_name.c any_content_type.c endpoint_ref.c msg_info_headers.c
 
 libaxis2_addr_la_LIBADD = $(LDFLAGS)
 INCLUDES = -I${CUTEST_HOME}/include \

Added: webservices/axis2/trunk/c/modules/core/addr/src/msg_info_headers.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/addr/src/msg_info_headers.c?rev=354647&view=auto
==============================================================================
--- webservices/axis2/trunk/c/modules/core/addr/src/msg_info_headers.c (added)
+++ webservices/axis2/trunk/c/modules/core/addr/src/msg_info_headers.c Tue Dec  6 17:36:55
2005
@@ -0,0 +1,409 @@
+/*
+ * 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.
+ */
+ 
+ /** <wsa:RelatesTo RelationshipType="..."?>xs:anyURI</wsa:RelatesTo> */
+
+#include <axis2_msg_info_headers.h>
+#include <axis2_string.h>
+
+typedef struct axis2_msg_info_headers_impl
+{
+    axis2_msg_info_headers_t msg_info_headers;    
+    /** The address of the intended receiver of the message. This is mandatory */
+    axis2_endpoint_ref_t *to;
+    /** Reference of the endpoint where the message originated from */
+    axis2_endpoint_ref_t *from;
+    /** Pair of values that indicate how this message related to another message */
+    axis2_relates_to_t *relates_to;    
+    /** identifies the intended receiver for replies to the message */
+    axis2_endpoint_ref_t *reply_to;
+    /** identifies the intended receiver for faults related to the message */
+    axis2_endpoint_ref_t *fault_to;
+    /** action */
+    axis2_char_t *action;    
+    /** message Id */
+    axis2_char_t *message_id;
+    /** referance parameters */
+    axis2_array_list_t *ref_params;
+} axis2_msg_info_headers_impl_t;
+
+/** Interface to implementation conversion macro */
+#define AXIS2_INTF_TO_IMPL(msg_info_headers) ((axis2_msg_info_headers_impl_t *)msg_info_headers)
+
+axis2_endpoint_ref_t* AXIS2_CALL axis2_msg_info_headers_get_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env); 
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_to(struct axis2_msg_info_headers *msg_info_headers,

+                                               axis2_env_t **env, axis2_endpoint_ref_t *to);
+axis2_endpoint_ref_t* AXIS2_CALL axis2_msg_info_headers_get_from(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env);
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_from(struct axis2_msg_info_headers *msg_info_headers,

+                                               axis2_env_t **env, axis2_endpoint_ref_t *from);
+axis2_endpoint_ref_t* AXIS2_CALL axis2_msg_info_headers_get_reply_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env);
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_reply_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_endpoint_ref_t *reply_to);
+axis2_endpoint_ref_t* AXIS2_CALL axis2_msg_info_headers_get_fault_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env);
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_fault_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_endpoint_ref_t *fault_to);
+axis2_char_t* AXIS2_CALL axis2_msg_info_headers_get_action(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env);
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_action(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_char_t *action);
+axis2_char_t* AXIS2_CALL axis2_msg_info_headers_get_message_id(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env);
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_message_id(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_char_t *message_id);
+axis2_relates_to_t* AXIS2_CALL axis2_msg_info_headers_get_relates_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env);
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_relates_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_relates_to_t *relates_to);
+axis2_array_list_t* AXIS2_CALL axis2_msg_info_headers_get_ref_params(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env);
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_add_ref_param(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_om_node_t *ref_param);
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_free(struct axis2_msg_info_headers *msg_info_headers,

+                                               axis2_env_t **env);
+
+
+/**
+ * Addressing Header MUST have a to and an action
+ *
+ * @param wsaTo
+ * @param action
+ */
+axis2_msg_info_headers_t* AXIS2_CALL axis2_msg_info_headers_create(axis2_env_t **env, axis2_endpoint_ref_t
*to,
+                                           axis2_char_t *action) 
+{
+    axis2_msg_info_headers_impl_t *msg_info_headers_impl = NULL;
+    
+    AXIS2_ENV_CHECK(env, NULL);
+    
+    msg_info_headers_impl = AXIS2_MALLOC( (*env)->allocator, sizeof(axis2_msg_info_headers_impl_t)
);
+    if (!msg_info_headers_impl)
+    { 
+        AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        return NULL;        
+    }
+
+    msg_info_headers_impl->msg_info_headers.ops = NULL;
+    msg_info_headers_impl->to = NULL;
+    msg_info_headers_impl->from = NULL;
+    msg_info_headers_impl->relates_to = NULL;    
+    msg_info_headers_impl->reply_to = NULL;
+    msg_info_headers_impl->fault_to = NULL;
+    msg_info_headers_impl->action = NULL;    
+    msg_info_headers_impl->message_id = NULL;
+    msg_info_headers_impl->ref_params = NULL;
+
+    if (to)
+    {
+        msg_info_headers_impl->to = to;
+    }
+    
+    if (action)
+    {
+        msg_info_headers_impl->action = AXIS2_STRDUP(action, env);
+        if (!(msg_info_headers_impl->action))
+        {
+            AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+            axis2_msg_info_headers_free(&(msg_info_headers_impl->msg_info_headers),
env);
+            return NULL;        
+        }
+    }
+    
+    /* initialize operations */
+    msg_info_headers_impl->msg_info_headers.ops  = AXIS2_MALLOC( (*env)->allocator,
sizeof(axis2_msg_info_headers_ops_t) );
+    if (!msg_info_headers_impl->msg_info_headers.ops)
+    {
+        AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        axis2_msg_info_headers_free(&(msg_info_headers_impl->msg_info_headers), env);
+        return NULL;        
+    }
+
+    msg_info_headers_impl->msg_info_headers.ops->get_to = axis2_msg_info_headers_get_to;
+    msg_info_headers_impl->msg_info_headers.ops->set_to = axis2_msg_info_headers_set_to;
+    msg_info_headers_impl->msg_info_headers.ops->get_from = axis2_msg_info_headers_get_from;
+    msg_info_headers_impl->msg_info_headers.ops->set_from = axis2_msg_info_headers_set_from;
+    msg_info_headers_impl->msg_info_headers.ops->get_reply_to = axis2_msg_info_headers_get_reply_to;
+    msg_info_headers_impl->msg_info_headers.ops->set_reply_to = axis2_msg_info_headers_set_reply_to;
+    msg_info_headers_impl->msg_info_headers.ops->get_fault_to = axis2_msg_info_headers_get_fault_to;
+    msg_info_headers_impl->msg_info_headers.ops->set_fault_to = axis2_msg_info_headers_set_fault_to;
+    msg_info_headers_impl->msg_info_headers.ops->get_action = axis2_msg_info_headers_get_action;
+    msg_info_headers_impl->msg_info_headers.ops->set_action = axis2_msg_info_headers_set_action;
+    msg_info_headers_impl->msg_info_headers.ops->get_message_id = axis2_msg_info_headers_get_message_id;
+    msg_info_headers_impl->msg_info_headers.ops->set_message_id = axis2_msg_info_headers_set_message_id;
+    msg_info_headers_impl->msg_info_headers.ops->get_relates_to = axis2_msg_info_headers_get_relates_to;
+    msg_info_headers_impl->msg_info_headers.ops->set_relates_to = axis2_msg_info_headers_set_relates_to;
+    msg_info_headers_impl->msg_info_headers.ops->get_ref_params = axis2_msg_info_headers_get_ref_params;
+    msg_info_headers_impl->msg_info_headers.ops->add_ref_param = axis2_msg_info_headers_add_ref_param;
+    msg_info_headers_impl->msg_info_headers.ops->free = axis2_msg_info_headers_free;
+
+    return &(msg_info_headers_impl->msg_info_headers);
+}
+
+/**
+ * Method getTo
+ *
+ * @return
+ */
+axis2_endpoint_ref_t* AXIS2_CALL axis2_msg_info_headers_get_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env) 
+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, NULL);
+    return AXIS2_INTF_TO_IMPL(msg_info_headers)->to;
+}
+
+/**
+ * Method set_to
+ *
+ * @param to
+ */
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_to(struct axis2_msg_info_headers *msg_info_headers,

+                                               axis2_env_t **env, axis2_endpoint_ref_t *to)

+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, AXIS2_FAILURE);
+    AXIS2_INTF_TO_IMPL(msg_info_headers)->to = to;
+    return AXIS2_SUCCESS;
+}
+
+/**
+ * Method getFrom
+ *
+ * @return
+ */
+axis2_endpoint_ref_t* AXIS2_CALL axis2_msg_info_headers_get_from(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env) 
+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, NULL);
+    return AXIS2_INTF_TO_IMPL(msg_info_headers)->from;
+}
+
+/**
+ * Method set_from
+ *
+ * @param from
+ */
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_from(struct axis2_msg_info_headers *msg_info_headers,

+                                               axis2_env_t **env, axis2_endpoint_ref_t *from)

+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, AXIS2_FAILURE);
+    AXIS2_INTF_TO_IMPL(msg_info_headers)->from = from;
+    return AXIS2_SUCCESS;
+}
+
+/**
+ * Method getReply_to
+ *
+ * @return
+ */
+axis2_endpoint_ref_t* AXIS2_CALL axis2_msg_info_headers_get_reply_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env) 
+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, NULL);
+    return AXIS2_INTF_TO_IMPL(msg_info_headers)->reply_to;
+}
+
+/**
+ * Method set_reply_to
+ *
+ * @param reply_to
+ */
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_reply_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_endpoint_ref_t *reply_to)

+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, AXIS2_FAILURE);
+    AXIS2_INTF_TO_IMPL(msg_info_headers)->reply_to = reply_to;
+    return AXIS2_SUCCESS;
+}
+
+/**
+ * Method getFault_to
+ *
+ * @return
+ */
+axis2_endpoint_ref_t* AXIS2_CALL axis2_msg_info_headers_get_fault_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env) 
+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, NULL);
+    return AXIS2_INTF_TO_IMPL(msg_info_headers)->fault_to;
+}
+
+/**
+ * Method set_fault_to
+ *
+ * @param fault_to
+ */
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_fault_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_endpoint_ref_t *fault_to)

+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, AXIS2_FAILURE);
+    AXIS2_INTF_TO_IMPL(msg_info_headers)->fault_to = fault_to;
+    return AXIS2_SUCCESS;
+}
+
+/**
+ * Method get_action
+ *
+ * @return
+ */
+axis2_char_t* AXIS2_CALL axis2_msg_info_headers_get_action(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env) 
+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, NULL);
+    return AXIS2_INTF_TO_IMPL(msg_info_headers)->action;
+}
+
+/**
+ * Method set_action
+ *
+ * @param action
+ */
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_action(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_char_t *action) 
+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, AXIS2_FAILURE);
+    AXIS2_INTF_TO_IMPL(msg_info_headers)->action = action;
+    return AXIS2_SUCCESS;
+}
+
+/**
+ * Method get_message_id
+ *
+ * @return
+ */
+axis2_char_t* AXIS2_CALL axis2_msg_info_headers_get_message_id(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env) 
+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, NULL);
+    return AXIS2_INTF_TO_IMPL(msg_info_headers)->message_id;
+}
+
+/**
+ * Method set_message_id
+ *
+ * @param message_id
+ */
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_message_id(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_char_t *message_id)

+{
+    axis2_msg_info_headers_impl_t *msg_info_headers_impl = NULL;
+    
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, AXIS2_FAILURE);
+    
+    msg_info_headers_impl = AXIS2_INTF_TO_IMPL(msg_info_headers);
+    
+    if (msg_info_headers_impl->message_id)
+    {
+        AXIS2_FREE((*env)->allocator, msg_info_headers_impl->message_id);
+        msg_info_headers_impl->message_id = NULL;        
+    }
+    
+    if (message_id)
+    {
+        msg_info_headers_impl->message_id = AXIS2_STRDUP(message_id, env);
+        if (!(msg_info_headers_impl->message_id))
+        {
+            AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);    
       
+            return AXIS2_FAILURE;        
+        }
+    }
+    
+    return AXIS2_SUCCESS;
+}
+
+/**
+ * Method get_relates_to
+ *
+ * @return
+ */
+axis2_relates_to_t* AXIS2_CALL axis2_msg_info_headers_get_relates_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env) 
+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, NULL);
+    return AXIS2_INTF_TO_IMPL(msg_info_headers)->relates_to;
+}
+
+/**
+ * Method set_relates_to
+ *
+ * @param relates_to
+ */
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_set_relates_to(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_relates_to_t *relates_to)

+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, AXIS2_FAILURE);
+    AXIS2_INTF_TO_IMPL(msg_info_headers)->relates_to = relates_to;
+    return AXIS2_SUCCESS;
+}
+
+axis2_array_list_t* AXIS2_CALL axis2_msg_info_headers_get_ref_params(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env) 
+{
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, NULL);
+    return AXIS2_INTF_TO_IMPL(msg_info_headers)->ref_params;
+}
+
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_add_ref_param(struct axis2_msg_info_headers
*msg_info_headers, 
+                                               axis2_env_t **env, axis2_om_node_t *ref_param)

+{
+    axis2_msg_info_headers_impl_t *msg_info_headers_impl = NULL;
+    
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, AXIS2_FAILURE);
+    
+    msg_info_headers_impl = AXIS2_INTF_TO_IMPL(msg_info_headers);
+    
+    if (!(msg_info_headers_impl->ref_params))
+    {
+        msg_info_headers_impl->ref_params = axis2_array_list_create(env, 10);
+        if (!(msg_info_headers_impl->ref_params))
+            return AXIS2_FAILURE;
+    }
+
+    if (ref_param) 
+    {
+        return AXIS2_ARRAY_LIST_ADD(msg_info_headers_impl->ref_params, env, ref_param);
+    }
+    
+    return AXIS2_SUCCESS;
+}
+
+axis2_status_t AXIS2_CALL axis2_msg_info_headers_free(struct axis2_msg_info_headers *msg_info_headers,

+                                               axis2_env_t **env)
+{
+    axis2_msg_info_headers_impl_t *msg_info_headers_impl = NULL;
+    
+    AXIS2_FUNC_PARAM_CHECK(msg_info_headers, env, AXIS2_FAILURE);
+    
+    msg_info_headers_impl = AXIS2_INTF_TO_IMPL(msg_info_headers);
+    
+    if (msg_info_headers_impl->msg_info_headers.ops)
+    {
+        AXIS2_FREE((*env)->allocator, msg_info_headers_impl->msg_info_headers.ops);
+        msg_info_headers_impl->msg_info_headers.ops = NULL;
+    }
+    
+    if (msg_info_headers_impl->ref_params)
+    {
+        AXIS2_ARRAY_LIST_FREE(msg_info_headers_impl->ref_params, env);
+        msg_info_headers_impl->ref_params = NULL;
+    }    
+    
+    AXIS2_FREE((*env)->allocator, msg_info_headers_impl);
+    msg_info_headers_impl = NULL;
+    
+    return AXIS2_SUCCESS;
+}



Mime
View raw message