You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by na...@apache.org on 2006/03/27 06:06:02 UTC
svn commit: r389016 [2/5] - in /webservices/axis2/trunk/c: include/
modules/core/context/ modules/core/description/ modules/core/engine/
modules/mod_addr/ modules/util/ modules/xml/om/ test/resources/xml/
test/resources/xml/om/ test/resources/xml/soap/...
Modified: webservices/axis2/trunk/c/modules/core/engine/addr_disp.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/addr_disp.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/addr_disp.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/addr_disp.c Sun Mar 26 20:05:56 2006
@@ -24,17 +24,24 @@
#include <axis2_addr.h>
#include <axis2_utils.h>
-axis2_status_t AXIS2_CALL axis2_addr_disp_invoke (struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx);
-axis2_svc_t* AXIS2_CALL axis2_addr_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env);
-axis2_op_t* AXIS2_CALL axis2_addr_disp_find_op(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env,
- axis2_svc_t *svc);
+axis2_status_t AXIS2_CALL
+axis2_addr_disp_invoke (struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx);
+
+axis2_svc_t* AXIS2_CALL
+axis2_addr_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env);
+
+axis2_op_t* AXIS2_CALL
+axis2_addr_disp_find_op(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env,
+ axis2_svc_t *svc);
+
-axis2_disp_t* AXIS2_CALL axis2_addr_disp_create(axis2_env_t **env)
+axis2_disp_t* AXIS2_CALL
+axis2_addr_disp_create(axis2_env_t **env)
{
axis2_disp_t *disp = NULL;
axis2_handler_t *handler = NULL;
@@ -81,8 +88,9 @@
* @param messageContext
* @return
*/
-axis2_svc_t* AXIS2_CALL axis2_addr_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env)
+axis2_svc_t* AXIS2_CALL
+axis2_addr_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env)
{
axis2_endpoint_ref_t *endpoint_ref = NULL;
axis2_svc_t *svc = NULL;
@@ -99,7 +107,8 @@
if (address)
{
axis2_char_t **url_tokens = NULL;
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Checking for service using WSA enpoint address : %s", address);
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Checking for service using WSA enpoint address : %s", address);
if ( (AXIS2_STRCMP(AXIS2_WSA_ANONYMOUS_URL, address) == 0 ) ||
(AXIS2_STRCMP(AXIS2_WSA_NAMESPACE_SUBMISSION, address) == 0 ))
@@ -123,11 +132,13 @@
if (conf)
{
axis2_qname_t *qname = axis2_qname_create(env, url_tokens[0], NULL, NULL);
+
svc = AXIS2_CONF_GET_SVC(conf, env, AXIS2_QNAME_GET_LOCALPART(qname, env));
AXIS2_QNAME_FREE(qname, env);
if(svc)
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Service found using WSA enpoint address");
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Service found using WSA enpoint address");
}
}
AXIS2_FREE((*env)->allocator, url_tokens[0]);
@@ -152,9 +163,10 @@
* @param msg_ctx
* @return
*/
-axis2_op_t* AXIS2_CALL axis2_addr_disp_find_op(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env,
- axis2_svc_t *svc)
+axis2_op_t* AXIS2_CALL
+axis2_addr_disp_find_op(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env,
+ axis2_svc_t *svc)
{
axis2_char_t *action = NULL;
axis2_qname_t *qname = NULL;
@@ -167,12 +179,14 @@
if (action)
{
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Checking for operation using WSA Action : %s", action);
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Checking for operation using WSA Action : %s", action);
qname = axis2_qname_create(env, action, NULL, NULL);
op = AXIS2_SVC_GET_OP_WITH_QNAME(svc, env, qname);
if (op)
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Operation found using WSA Action");
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Operation found using WSA Action");
AXIS2_QNAME_FREE(qname, env);
}
@@ -180,9 +194,10 @@
}
-axis2_status_t AXIS2_CALL axis2_addr_disp_invoke(struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_addr_disp_invoke(struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx)
{
axis2_relates_to_t *relates_to = NULL;
@@ -230,7 +245,8 @@
svc_grp_ctx = AXIS2_SVC_CTX_GET_PARENT(svc_ctx, env);
if (svc_grp_ctx)
{
- AXIS2_MSG_CTX_SET_SVC_GRP_CTX_ID(msg_ctx, env, AXIS2_SVC_GRP_CTX_GET_ID(svc_grp_ctx, env) );
+ AXIS2_MSG_CTX_SET_SVC_GRP_CTX_ID(msg_ctx, env,
+ AXIS2_SVC_GRP_CTX_GET_ID(svc_grp_ctx, env) );
}
}
Modified: webservices/axis2/trunk/c/modules/core/engine/axis2_engine.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/axis2_engine.h?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/axis2_engine.h (original)
+++ webservices/axis2/trunk/c/modules/core/engine/axis2_engine.h Sun Mar 26 20:05:56 2006
@@ -60,7 +60,10 @@
* @see Phase
* @see Handler
*/
- axis2_status_t (AXIS2_CALL *send)(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
+ axis2_status_t (AXIS2_CALL *
+ send)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
/**
* This methods represents the inflow of the Axis, this could be either at the server side or the client side.
* Here the <code>ExecutionChain</code> is created using the Phases. The Handlers at the each Phases is ordered in
@@ -70,20 +73,29 @@
* @see Phase
* @see Handler
*/
- axis2_status_t (AXIS2_CALL *receive)(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
+ axis2_status_t (AXIS2_CALL *
+ receive)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
/**
* Sends the SOAP Fault to another SOAP node.
*
* @param msg_ctx
*/
- axis2_status_t (AXIS2_CALL *send_fault)(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
+ axis2_status_t (AXIS2_CALL *
+ send_fault)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
/**
* This is invoked when a SOAP Fault is received from a Other SOAP Node
* Receives a SOAP fault from another SOAP node.
*
* @param msg_ctx
*/
- axis2_status_t (AXIS2_CALL *receive_fault)(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
+ axis2_status_t (AXIS2_CALL *
+ receive_fault)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
/**
* This method is called to handle any error that occurs at inflow or outflow. But if the
* method is called twice, it implies that sending the error handling has failed, in which case
@@ -92,8 +104,10 @@
* @param processingContext
* @param e
*/
- axis2_msg_ctx_t* (AXIS2_CALL *create_fault_msg_ctx)(struct axis2_engine *engine, axis2_env_t **env,
- axis2_msg_ctx_t *processing_context);
+ axis2_msg_ctx_t* (AXIS2_CALL *
+ create_fault_msg_ctx)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *processing_context);
/**
* Information to create the SOAPFault can be extracted from different places.
* 1. Those info may have been put in to the message context by some handler. When someone
@@ -126,17 +140,48 @@
* @param fault
* @param e
*/
- axis2_status_t (AXIS2_CALL *extract_fault_info_from_msg_ctx)(
- struct axis2_engine *engine, axis2_env_t **env,
- axis2_msg_ctx_t *msg_ctx,
- struct axis2_soap_fault *fault);
- axis2_status_t (AXIS2_CALL *verify_ctx_built)(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
- axis2_status_t (AXIS2_CALL *invoke_phases)(struct axis2_engine *engine, axis2_env_t **env, axis2_array_list_t *phases, axis2_msg_ctx_t *msg_ctx);
- axis2_status_t (AXIS2_CALL *resume_invocation_phases)(struct axis2_engine *engine, axis2_env_t **env, axis2_array_list_t *phases, axis2_msg_ctx_t *msg_ctx);
- axis2_char_t* (AXIS2_CALL *get_sender_fault_code)(struct axis2_engine *engine, axis2_env_t **env, axis2_char_t *soap_namespace);
- axis2_char_t* (AXIS2_CALL *get_receiver_fault_code)(struct axis2_engine *engine, axis2_env_t **env, axis2_char_t *soap_namespace);
- axis2_status_t (AXIS2_CALL *free)(struct axis2_engine *engine,
- axis2_env_t **env);
+ axis2_status_t (AXIS2_CALL *
+ extract_fault_info_from_msg_ctx)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx,
+ struct axis2_soap_fault *fault);
+
+
+ axis2_status_t (AXIS2_CALL *
+ verify_ctx_built)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
+
+
+ axis2_status_t (AXIS2_CALL *
+ invoke_phases)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_array_list_t *phases,
+ axis2_msg_ctx_t *msg_ctx);
+
+
+ axis2_status_t (AXIS2_CALL *
+ resume_invocation_phases)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_array_list_t *phases,
+ axis2_msg_ctx_t *msg_ctx);
+
+
+ axis2_char_t* (AXIS2_CALL *
+ get_sender_fault_code)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_char_t *soap_namespace);
+
+
+ axis2_char_t* (AXIS2_CALL *
+ get_receiver_fault_code)(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_char_t *soap_namespace);
+
+ axis2_status_t (AXIS2_CALL *
+ free)(struct axis2_engine *engine,
+ axis2_env_t **env);
+
};
/**
@@ -154,18 +199,41 @@
/************************** Start of function macros **************************/
-#define AXIS2_ENGINE_SEND(engine, env, msg_ctx) ((engine)->ops->send(engine, env, msg_ctx))
-#define AXIS2_ENGINE_RECEIVE(engine, env, msg_ctx) ((engine)->ops->receive(engine, env, msg_ctx))
-#define AXIS2_ENGINE_SEND_FAULT(engine, env, msg_ctx) ((engine)->ops->send_fault(engine, env, msg_ctx))
-#define AXIS2_ENGINE_RECEIVE_FAULT(engine, env, msg_ctx) ((engine)->ops->receive_fault(engine, env, msg_ctx))
-#define AXIS2_ENGINE_CREATE_FAULT_MSG_CTX(engine, env, msg_ctx) ((engine)->ops->create_fault_msg_ctx(engine, env, msg_ctx))
-#define AXIS2_ENGINE_EXTRACT_FAULT_INFO_FROM_MSG_CTX(engine, env, msg_ctx, fault) ((engine)->ops->extract_fault_info_from_msg_ctx(engine, env, msg_ctx, fault))
-#define AXIS2_ENGINE_VERIFY_CTX_BUILT(engine, env, msg_ctx) ((engine)->ops->verify_ctx_built(engine, env, msg_ctx))
-#define AXIS2_ENGINE_INVOKE_PHASES(engine, env, phases, msg_ctx) ((engine)->ops->invoke_phases(engine, env, phases, msg_ctx))
-#define AXIS2_ENGINE_RESUME_INVOCATION_PHASES(engine, env, phases, msg_ctx) ((engine)->ops->resume_invocation_phases(engine, env, phases, msg_ctx))
-#define AXIS2_ENGINE_GET_SENDER_FAULT_CODE(engine, env, soap_namespace) ((engine)->ops->get_sender_fault_code(engine, env, soap_namespace))
-#define AXIS2_ENGINE_GET_RECEIVER_FAULT_CODE(engine, env, soap_namespace) ((engine)->ops->get_receiver_fault_code(engine, env, soap_namespace))
-#define AXIS2_ENGINE_FREE(engine, env) ((engine)->ops->free(engine, env))
+#define AXIS2_ENGINE_SEND(engine, env, msg_ctx)\
+ ((engine)->ops->send(engine, env, msg_ctx))
+
+#define AXIS2_ENGINE_RECEIVE(engine, env, msg_ctx) \
+ ((engine)->ops->receive(engine, env, msg_ctx))
+
+#define AXIS2_ENGINE_SEND_FAULT(engine, env, msg_ctx) \
+ ((engine)->ops->send_fault(engine, env, msg_ctx))
+
+#define AXIS2_ENGINE_RECEIVE_FAULT(engine, env, msg_ctx) \
+ ((engine)->ops->receive_fault(engine, env, msg_ctx))
+
+#define AXIS2_ENGINE_CREATE_FAULT_MSG_CTX(engine, env, msg_ctx) \
+ ((engine)->ops->create_fault_msg_ctx(engine, env, msg_ctx))
+
+#define AXIS2_ENGINE_EXTRACT_FAULT_INFO_FROM_MSG_CTX(engine, env, msg_ctx, fault) \
+ ((engine)->ops->extract_fault_info_from_msg_ctx(engine, env, msg_ctx, fault))
+
+#define AXIS2_ENGINE_VERIFY_CTX_BUILT(engine, env, msg_ctx) \
+ ((engine)->ops->verify_ctx_built(engine, env, msg_ctx))
+
+#define AXIS2_ENGINE_INVOKE_PHASES(engine, env, phases, msg_ctx) \
+ ((engine)->ops->invoke_phases(engine, env, phases, msg_ctx))
+
+#define AXIS2_ENGINE_RESUME_INVOCATION_PHASES(engine, env, phases, msg_ctx) \
+ ((engine)->ops->resume_invocation_phases(engine, env, phases, msg_ctx))
+
+#define AXIS2_ENGINE_GET_SENDER_FAULT_CODE(engine, env, soap_namespace) \
+ ((engine)->ops->get_sender_fault_code(engine, env, soap_namespace))
+
+#define AXIS2_ENGINE_GET_RECEIVER_FAULT_CODE(engine, env, soap_namespace) \
+ ((engine)->ops->get_receiver_fault_code(engine, env, soap_namespace))
+
+#define AXIS2_ENGINE_FREE(engine, env) \
+ ((engine)->ops->free(engine, env))
/************************** End of function macros ****************************/
Modified: webservices/axis2/trunk/c/modules/core/engine/axis2_event.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/axis2_event.h?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/axis2_event.h (original)
+++ webservices/axis2/trunk/c/modules/core/engine/axis2_event.h Sun Mar 26 20:05:56 2006
@@ -50,10 +50,20 @@
*/
struct axis2_event_ops
{
- axis2_svc_t* (AXIS2_CALL *get_svc)(struct axis2_event *event, axis2_env_t **env);
- int (AXIS2_CALL *get_event_type)(struct axis2_event *event, axis2_env_t **env);
- axis2_status_t (AXIS2_CALL *free)(struct axis2_event *event,
- axis2_env_t **env);
+
+ axis2_svc_t* (AXIS2_CALL *
+ get_svc)(struct axis2_event *event,
+ axis2_env_t **env);
+
+
+ int (AXIS2_CALL *
+ get_event_type)(struct axis2_event *event,
+ axis2_env_t **env);
+
+
+ axis2_status_t (AXIS2_CALL *
+ free)(struct axis2_event *event,
+ axis2_env_t **env);
};
/**
@@ -65,13 +75,21 @@
axis2_event_ops_t *ops;
};
-AXIS2_DECLARE(axis2_event_t*) axis2_event_create(axis2_env_t **env, axis2_svc_t *svc, int event_type);
+AXIS2_DECLARE(axis2_event_t*)
+axis2_event_create(axis2_env_t **env,
+ axis2_svc_t *svc,
+ int event_type);
/************************** Start of function macros **************************/
-#define AXIS2_EVENT_GET_SVC(event, env) ((event)->ops->get_svc(event, env))
-#define AXIS2_EVENT_GET_EVENT_TYPE(event, env) ((event)->ops->get_event_type(event, env))
-#define AXIS2_EVENT_FREE(event, env) ((event)->ops->free (event, env))
+#define AXIS2_EVENT_GET_SVC(event, env) \
+ ((event)->ops->get_svc(event, env))
+
+#define AXIS2_EVENT_GET_EVENT_TYPE(event, env) \
+ ((event)->ops->get_event_type(event, env))
+
+#define AXIS2_EVENT_FREE(event, env) \
+ ((event)->ops->free (event, env))
/************************** End of function macros ****************************/
Modified: webservices/axis2/trunk/c/modules/core/engine/ctx_handler.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/ctx_handler.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/ctx_handler.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/ctx_handler.c Sun Mar 26 20:05:56 2006
@@ -25,11 +25,14 @@
* This will then try to find the Contexts of ServiceGroup, Service and the Operation.
*/
-axis2_status_t AXIS2_CALL axis2_ctx_handler_invoke(struct axis2_handler *handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx);
+axis2_status_t AXIS2_CALL
+axis2_ctx_handler_invoke(struct axis2_handler *handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx);
-axis2_handler_t* AXIS2_CALL axis2_ctx_handler_create(axis2_env_t **env, axis2_qname_t *qname)
+axis2_handler_t* AXIS2_CALL
+axis2_ctx_handler_create(axis2_env_t **env,
+ axis2_qname_t *qname)
{
axis2_handler_t *handler = NULL;
axis2_handler_desc_t *handler_desc = NULL;
@@ -83,9 +86,10 @@
}
-axis2_status_t AXIS2_CALL axis2_ctx_handler_invoke(struct axis2_handler *handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_ctx_handler_invoke(struct axis2_handler *handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx)
{
axis2_op_t *op = NULL;
axis2_svc_ctx_t *svc_ctx = NULL;
@@ -103,7 +107,8 @@
svc_grp_ctx = AXIS2_SVC_CTX_GET_PARENT(svc_ctx, env);
if (svc_grp_ctx)
{
- AXIS2_MSG_CTX_SET_SVC_GRP_CTX_ID(msg_ctx, env, AXIS2_SVC_GRP_CTX_GET_ID(svc_grp_ctx, env));
+ AXIS2_MSG_CTX_SET_SVC_GRP_CTX_ID(msg_ctx, env,
+ AXIS2_SVC_GRP_CTX_GET_ID(svc_grp_ctx, env));
}
return AXIS2_SUCCESS;
}
@@ -122,7 +127,9 @@
svc_grp_ctx = AXIS2_SVC_CTX_GET_PARENT(svc_ctx, env);
AXIS2_MSG_CTX_SET_SVC_CTX(msg_ctx, env, svc_ctx);
AXIS2_MSG_CTX_SET_SVC_GRP_CTX(msg_ctx, env, svc_grp_ctx);
- AXIS2_MSG_CTX_SET_SVC_GRP_CTX_ID(msg_ctx, env, AXIS2_SVC_GRP_CTX_GET_ID(svc_grp_ctx, env));
+
+ AXIS2_MSG_CTX_SET_SVC_GRP_CTX_ID(msg_ctx, env,
+ AXIS2_SVC_GRP_CTX_GET_ID(svc_grp_ctx, env));
}
return AXIS2_SUCCESS;
}
Modified: webservices/axis2/trunk/c/modules/core/engine/disp.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/disp.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/disp.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/disp.c Sun Mar 26 20:05:56 2006
@@ -38,22 +38,38 @@
/** Interface to implementation conversion macro */
#define AXIS2_INTF_TO_IMPL(disp) ((axis2_disp_impl_t *)disp)
-axis2_handler_t* AXIS2_CALL axis2_disp_get_base(struct axis2_disp *disp,
- axis2_env_t **env);
-axis2_qname_t* AXIS2_CALL axis2_disp_get_qname(struct axis2_disp *disp,
- axis2_env_t **env);
-axis2_status_t AXIS2_CALL axis2_disp_set_qname(struct axis2_disp *disp,
- axis2_env_t **env, axis2_qname_t *qname);
-axis2_status_t AXIS2_CALL axis2_disp_free (struct axis2_disp * disp,
- axis2_env_t **env);
-axis2_svc_t* AXIS2_CALL axis2_disp_find_svc(axis2_msg_ctx_t * msg_ctx,
+axis2_handler_t* AXIS2_CALL
+axis2_disp_get_base(struct axis2_disp *disp,
axis2_env_t **env);
-struct axis2_op* AXIS2_CALL axis2_disp_find_op(axis2_msg_ctx_t * msg_ctx,
- axis2_env_t **env,
- struct axis2_svc *svc);
+
+axis2_qname_t* AXIS2_CALL
+axis2_disp_get_qname(struct axis2_disp *disp,
+ axis2_env_t **env);
+
+axis2_status_t AXIS2_CALL
+axis2_disp_set_qname(struct axis2_disp *disp,
+ axis2_env_t **env,
+ axis2_qname_t *qname);
+
+
+axis2_status_t AXIS2_CALL
+axis2_disp_free (struct axis2_disp * disp,
+ axis2_env_t **env);
+
+axis2_svc_t* AXIS2_CALL
+axis2_disp_find_svc(axis2_msg_ctx_t * msg_ctx,
+ axis2_env_t **env);
+
+struct axis2_op* AXIS2_CALL
+axis2_disp_find_op(axis2_msg_ctx_t * msg_ctx,
+ axis2_env_t **env,
+ struct axis2_svc *svc);
+
-axis2_disp_t* AXIS2_CALL axis2_disp_create(axis2_env_t **env, axis2_qname_t *qname)
+axis2_disp_t* AXIS2_CALL
+axis2_disp_create(axis2_env_t **env,
+ axis2_qname_t *qname)
{
axis2_disp_impl_t *disp_impl = NULL;
axis2_handler_desc_t *handler_desc = NULL;
@@ -134,22 +150,26 @@
return &(disp_impl->disp);
}
-axis2_handler_t* AXIS2_CALL axis2_disp_get_base(struct axis2_disp *disp,
- axis2_env_t **env)
+axis2_handler_t* AXIS2_CALL
+axis2_disp_get_base(struct axis2_disp *disp,
+ axis2_env_t **env)
{
AXIS2_ENV_CHECK(env, NULL);
return AXIS2_INTF_TO_IMPL(disp)->base;
}
-axis2_qname_t* AXIS2_CALL axis2_disp_get_qname(struct axis2_disp *disp,
- axis2_env_t **env)
+axis2_qname_t* AXIS2_CALL
+axis2_disp_get_qname(struct axis2_disp *disp,
+ axis2_env_t **env)
{
AXIS2_ENV_CHECK(env, NULL);
return AXIS2_INTF_TO_IMPL(disp)->qname;
}
-axis2_status_t AXIS2_CALL axis2_disp_set_qname(struct axis2_disp *disp,
- axis2_env_t **env, axis2_qname_t *qname)
+axis2_status_t AXIS2_CALL
+axis2_disp_set_qname(struct axis2_disp *disp,
+ axis2_env_t **env,
+ axis2_qname_t *qname)
{
axis2_disp_impl_t *disp_impl = NULL;
@@ -173,9 +193,10 @@
return AXIS2_SUCCESS;
}
-axis2_status_t AXIS2_CALL axis2_disp_invoke(struct axis2_handler *handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_disp_invoke(struct axis2_handler *handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx)
{
axis2_svc_t *axis_service = NULL;
axis2_op_t *op = NULL;
@@ -215,7 +236,7 @@
axis2_status_t AXIS2_CALL
axis2_disp_free (struct axis2_disp * disp,
- axis2_env_t **env)
+ axis2_env_t **env)
{
axis2_disp_impl_t *disp_impl = NULL;
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
@@ -260,7 +281,8 @@
* @param messageContext
* @return
*/
-axis2_svc_t* AXIS2_CALL axis2_disp_find_svc(axis2_msg_ctx_t * msg_ctx,
+axis2_svc_t* AXIS2_CALL
+axis2_disp_find_svc(axis2_msg_ctx_t * msg_ctx,
axis2_env_t **env)
{
return NULL;
@@ -273,9 +295,10 @@
* @param msg_ctx
* @return
*/
-struct axis2_op* AXIS2_CALL axis2_disp_find_op(axis2_msg_ctx_t * msg_ctx,
- axis2_env_t **env,
- struct axis2_svc *svc)
+struct axis2_op* AXIS2_CALL
+axis2_disp_find_op(axis2_msg_ctx_t * msg_ctx,
+ axis2_env_t **env,
+ struct axis2_svc *svc)
{
return NULL;
}
Modified: webservices/axis2/trunk/c/modules/core/engine/engine.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/engine.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/engine.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/engine.c Sun Mar 26 20:05:56 2006
@@ -38,27 +38,78 @@
/** Interface to implementation conversion macro */
#define AXIS2_INTF_TO_IMPL(engine) ((axis2_engine_impl_t *)engine)
-axis2_status_t AXIS2_CALL axis2_engine_send(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
-axis2_status_t AXIS2_CALL axis2_engine_receive(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
-axis2_status_t AXIS2_CALL axis2_engine_send_fault(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
-axis2_status_t AXIS2_CALL axis2_engine_receive_fault(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
-axis2_msg_ctx_t* AXIS2_CALL axis2_engine_create_fault_msg_ctx(struct axis2_engine *engine, axis2_env_t **env,
- axis2_msg_ctx_t *processing_context);
-axis2_status_t AXIS2_CALL axis2_engine_extract_fault_info_from_msg_ctx(
- struct axis2_engine *engine, axis2_env_t **env,
- axis2_msg_ctx_t *msg_ctx,
- struct axis2_soap_fault *fault);
-axis2_status_t AXIS2_CALL axis2_engine_verify_ctx_built(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx);
-axis2_status_t AXIS2_CALL axis2_engine_invoke_phases(struct axis2_engine *engine, axis2_env_t **env, axis2_array_list_t *phases, axis2_msg_ctx_t *msg_ctx);
-axis2_status_t AXIS2_CALL axis2_engine_resume_invocation_phases(struct axis2_engine *engine, axis2_env_t **env, axis2_array_list_t *phases, axis2_msg_ctx_t *msg_ctx);
-axis2_char_t* AXIS2_CALL axis2_engine_get_sender_fault_code(struct axis2_engine *engine, axis2_env_t **env, axis2_char_t *soap_namespace);
-axis2_char_t* AXIS2_CALL axis2_engine_get_receiver_fault_code(struct axis2_engine *engine, axis2_env_t **env, axis2_char_t *soap_namespace);
-axis2_status_t AXIS2_CALL axis2_engine_free(struct axis2_engine *engine,
- axis2_env_t **env);
+axis2_status_t AXIS2_CALL
+axis2_engine_send(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
+
+
+axis2_status_t AXIS2_CALL
+axis2_engine_receive(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
+
+
+axis2_status_t AXIS2_CALL
+axis2_engine_send_fault(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
+
+axis2_status_t AXIS2_CALL
+axis2_engine_receive_fault(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
+
+
+axis2_msg_ctx_t* AXIS2_CALL
+axis2_engine_create_fault_msg_ctx(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *processing_context);
+
+axis2_status_t AXIS2_CALL
+axis2_engine_extract_fault_info_from_msg_ctx(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx,
+ struct axis2_soap_fault *fault);
+
+axis2_status_t AXIS2_CALL
+axis2_engine_verify_ctx_built(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
+
+axis2_status_t AXIS2_CALL
+axis2_engine_invoke_phases(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_array_list_t *phases,
+ axis2_msg_ctx_t *msg_ctx);
+
+
+axis2_status_t AXIS2_CALL
+axis2_engine_resume_invocation_phases(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_array_list_t *phases,
+ axis2_msg_ctx_t *msg_ctx);
+
+axis2_char_t* AXIS2_CALL
+axis2_engine_get_sender_fault_code(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_char_t *soap_namespace);
+
+
+axis2_char_t* AXIS2_CALL
+axis2_engine_get_receiver_fault_code(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_char_t *soap_namespace);
+
+
+axis2_status_t AXIS2_CALL
+axis2_engine_free(struct axis2_engine *engine,
+ axis2_env_t **env);
AXIS2_DECLARE(axis2_engine_t*)
-axis2_engine_create(axis2_env_t **env, axis2_conf_ctx_t *conf_ctx)
+axis2_engine_create(axis2_env_t **env,
+ axis2_conf_ctx_t *conf_ctx)
{
axis2_engine_impl_t *engine_impl = NULL;
@@ -88,25 +139,48 @@
return NULL;
}
- engine_impl->engine.ops->send = axis2_engine_send;
- engine_impl->engine.ops->receive = axis2_engine_receive;
- engine_impl->engine.ops->send_fault = axis2_engine_send_fault;
- engine_impl->engine.ops->receive_fault = axis2_engine_receive_fault;
- engine_impl->engine.ops->create_fault_msg_ctx = axis2_engine_create_fault_msg_ctx;
- engine_impl->engine.ops->extract_fault_info_from_msg_ctx = axis2_engine_extract_fault_info_from_msg_ctx;
- engine_impl->engine.ops->verify_ctx_built = axis2_engine_verify_ctx_built;
- engine_impl->engine.ops->invoke_phases = axis2_engine_invoke_phases;
- engine_impl->engine.ops->resume_invocation_phases = axis2_engine_resume_invocation_phases;
- engine_impl->engine.ops->get_sender_fault_code = axis2_engine_get_sender_fault_code;
- engine_impl->engine.ops->get_receiver_fault_code = axis2_engine_get_receiver_fault_code;
- engine_impl->engine.ops->free = axis2_engine_free;
-
+ engine_impl->engine.ops->send =
+ axis2_engine_send;
+ engine_impl->engine.ops->receive =
+ axis2_engine_receive;
+
+ engine_impl->engine.ops->send_fault =
+ axis2_engine_send_fault;
+
+ engine_impl->engine.ops->receive_fault =
+ axis2_engine_receive_fault;
+
+ engine_impl->engine.ops->create_fault_msg_ctx =
+ axis2_engine_create_fault_msg_ctx;
+
+ engine_impl->engine.ops->extract_fault_info_from_msg_ctx =
+ axis2_engine_extract_fault_info_from_msg_ctx;
+
+ engine_impl->engine.ops->verify_ctx_built =
+ axis2_engine_verify_ctx_built;
+
+ engine_impl->engine.ops->invoke_phases =
+ axis2_engine_invoke_phases;
+
+ engine_impl->engine.ops->resume_invocation_phases =
+ axis2_engine_resume_invocation_phases;
+
+ engine_impl->engine.ops->get_sender_fault_code =
+ axis2_engine_get_sender_fault_code;
+
+ engine_impl->engine.ops->get_receiver_fault_code =
+ axis2_engine_get_receiver_fault_code;
+
+ engine_impl->engine.ops->free =
+ axis2_engine_free;
+
return &(engine_impl->engine);
}
-axis2_status_t AXIS2_CALL axis2_engine_free(struct axis2_engine *engine,
- axis2_env_t **env)
+axis2_status_t AXIS2_CALL
+axis2_engine_free(struct axis2_engine *engine,
+ axis2_env_t **env)
{
axis2_engine_impl_t *engine_impl = NULL;
@@ -136,7 +210,10 @@
* @see Phase
* @see Handler
*/
-axis2_status_t AXIS2_CALL axis2_engine_send(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_engine_send(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx)
{
axis2_engine_impl_t *engine_impl = NULL;
axis2_status_t status = AXIS2_SUCCESS;
@@ -244,7 +321,10 @@
* @see Phase
* @see Handler
*/
-axis2_status_t AXIS2_CALL axis2_engine_receive(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_engine_receive(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx)
{
axis2_engine_impl_t *engine_impl = NULL;
axis2_conf_ctx_t *conf_ctx = NULL;
@@ -263,7 +343,8 @@
conf = AXIS2_CONF_CTX_GET_CONF(conf_ctx, env);
- pre_calculated_phases = AXIS2_CONF_GET_IN_PHASES_UPTO_AND_INCLUDING_POST_DISPATCH(conf, env);
+ pre_calculated_phases =
+ AXIS2_CONF_GET_IN_PHASES_UPTO_AND_INCLUDING_POST_DISPATCH(conf, env);
if (AXIS2_MSG_CTX_IS_PAUSED(msg_ctx, env))
{
@@ -336,7 +417,10 @@
*
* @param msg_ctx
*/
-axis2_status_t AXIS2_CALL axis2_engine_send_fault(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_engine_send_fault(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx)
{
axis2_op_ctx_t *op_ctx = NULL;
@@ -383,7 +467,10 @@
*
* @param msg_ctx
*/
-axis2_status_t AXIS2_CALL axis2_engine_receive_fault(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_engine_receive_fault(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx)
{
axis2_op_ctx_t *op_ctx = NULL;
@@ -445,8 +532,10 @@
* @param processingContext
* @param e
*/
-axis2_msg_ctx_t* AXIS2_CALL axis2_engine_create_fault_msg_ctx(struct axis2_engine *engine, axis2_env_t **env,
- axis2_msg_ctx_t *processing_context)
+axis2_msg_ctx_t* AXIS2_CALL
+axis2_engine_create_fault_msg_ctx(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *processing_context)
{
axis2_msg_ctx_t *fault_ctx = NULL;
axis2_engine_impl_t *engine_impl = NULL;
@@ -460,7 +549,8 @@
if (AXIS2_MSG_CTX_GET_PROCESS_FAULT(processing_context, env))
{
- AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_INVALID_STATE_PROCESSING_FAULT_ALREADY, AXIS2_FAILURE);
+ AXIS2_ERROR_SET((*env)->error,
+ AXIS2_ERROR_INVALID_STATE_PROCESSING_FAULT_ALREADY, AXIS2_FAILURE);
return NULL;
}
@@ -570,10 +660,11 @@
* @param fault
* @param e
*/
-axis2_status_t AXIS2_CALL axis2_engine_extract_fault_info_from_msg_ctx(
- struct axis2_engine *engine, axis2_env_t **env,
- axis2_msg_ctx_t *msg_ctx,
- struct axis2_soap_fault *fault)
+axis2_status_t AXIS2_CALL
+axis2_engine_extract_fault_info_from_msg_ctx(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx,
+ struct axis2_soap_fault *fault)
{
/*axis2_char_t *soap_namespace_uri = NULL;*/
@@ -644,7 +735,10 @@
return AXIS2_SUCCESS;
}
-axis2_status_t AXIS2_CALL axis2_engine_verify_ctx_built(struct axis2_engine *engine, axis2_env_t **env, axis2_msg_ctx_t *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_engine_verify_ctx_built(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx)
{
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
AXIS2_PARAM_CHECK((*env)->error, msg_ctx, AXIS2_FAILURE);
@@ -665,7 +759,11 @@
return AXIS2_SUCCESS;
}
-axis2_status_t AXIS2_CALL axis2_engine_invoke_phases(struct axis2_engine *engine, axis2_env_t **env, axis2_array_list_t *phases, axis2_msg_ctx_t *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_engine_invoke_phases(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_array_list_t *phases,
+ axis2_msg_ctx_t *msg_ctx)
{
int i = 0;
int count = 0;
@@ -676,14 +774,22 @@
count = AXIS2_ARRAY_LIST_SIZE(phases, env);
for (i = 0; (i < count && !(AXIS2_MSG_CTX_IS_PAUSED(msg_ctx, env))); i++)
{
- axis2_phase_t *phase = (axis2_phase_t *) AXIS2_ARRAY_LIST_GET(phases, env, i);
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Invoking phase %s", AXIS2_PHASE_GET_NAME(phase, env));
+ axis2_phase_t *phase = (axis2_phase_t *)
+ AXIS2_ARRAY_LIST_GET(phases, env, i);
+
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Invoking phase %s", AXIS2_PHASE_GET_NAME(phase, env));
+
AXIS2_PHASE_INVOKE(phase, env, msg_ctx);
}
return AXIS2_SUCCESS;
}
-axis2_status_t AXIS2_CALL axis2_engine_resume_invocation_phases(struct axis2_engine *engine, axis2_env_t **env, axis2_array_list_t *phases, axis2_msg_ctx_t *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_engine_resume_invocation_phases(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_array_list_t *phases,
+ axis2_msg_ctx_t *msg_ctx)
{
int i = 0;
int count = 0;
@@ -707,7 +813,8 @@
if (AXIS2_STRCMP(phase_name, paused_phase_name) == 0)
{
found_match = AXIS2_TRUE;
- AXIS2_PHASE_INVOKE_START_FROM_HANDLER(phase, env, AXIS2_MSG_CTX_GET_PAUSED_HANDLER_NAME(msg_ctx, env), msg_ctx);
+ AXIS2_PHASE_INVOKE_START_FROM_HANDLER(phase, env,
+ AXIS2_MSG_CTX_GET_PAUSED_HANDLER_NAME(msg_ctx, env), msg_ctx);
}
}
else
@@ -723,7 +830,10 @@
return AXIS2_SUCCESS;
}
-axis2_char_t* AXIS2_CALL axis2_engine_get_sender_fault_code(struct axis2_engine *engine, axis2_env_t **env, axis2_char_t *soap_namespace)
+axis2_char_t* AXIS2_CALL
+axis2_engine_get_sender_fault_code(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_char_t *soap_namespace)
{
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
AXIS2_PARAM_CHECK((*env)->error, soap_namespace, AXIS2_FAILURE);
@@ -736,7 +846,10 @@
return NULL;
}
-axis2_char_t* AXIS2_CALL axis2_engine_get_receiver_fault_code(struct axis2_engine *engine, axis2_env_t **env, axis2_char_t *soap_namespace)
+axis2_char_t* AXIS2_CALL
+axis2_engine_get_receiver_fault_code(struct axis2_engine *engine,
+ axis2_env_t **env,
+ axis2_char_t *soap_namespace)
{
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
AXIS2_PARAM_CHECK((*env)->error, soap_namespace, AXIS2_FAILURE);
Modified: webservices/axis2/trunk/c/modules/core/engine/event.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/event.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/event.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/event.c Sun Mar 26 20:05:56 2006
@@ -30,12 +30,24 @@
/** Interface to implementation conversion macro */
#define AXIS2_INTF_TO_IMPL(event) ((axis2_event_impl_t *)event)
-axis2_svc_t* AXIS2_CALL axis2_event_get_svc(struct axis2_event *event, axis2_env_t **env);
-int AXIS2_CALL axis2_event_get_event_type(struct axis2_event *event, axis2_env_t **env);
-axis2_status_t AXIS2_CALL axis2_event_free(struct axis2_event *event,
- axis2_env_t **env);
-
-axis2_event_t* AXIS2_CALL axis2_event_create(axis2_env_t **env, axis2_svc_t *svc, int event_type)
+axis2_svc_t* AXIS2_CALL
+axis2_event_get_svc(struct axis2_event *event,
+ axis2_env_t **env);
+
+
+int AXIS2_CALL
+axis2_event_get_event_type(struct axis2_event *event,
+ axis2_env_t **env);
+
+axis2_status_t AXIS2_CALL
+axis2_event_free(struct axis2_event *event,
+ axis2_env_t **env);
+
+
+axis2_event_t* AXIS2_CALL
+axis2_event_create(axis2_env_t **env,
+ axis2_svc_t *svc,
+ int event_type)
{
axis2_event_impl_t *event_impl = NULL;
@@ -73,20 +85,25 @@
return &(event_impl->event);
}
-axis2_svc_t* AXIS2_CALL axis2_event_get_svc(struct axis2_event *event, axis2_env_t **env)
+axis2_svc_t* AXIS2_CALL
+axis2_event_get_svc(struct axis2_event *event,
+ axis2_env_t **env)
{
AXIS2_ENV_CHECK(env, NULL);
return AXIS2_INTF_TO_IMPL(event)->svc;
}
-int AXIS2_CALL axis2_event_get_event_type(struct axis2_event *event, axis2_env_t **env)
+int AXIS2_CALL
+axis2_event_get_event_type(struct axis2_event *event,
+ axis2_env_t **env)
{
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
return AXIS2_INTF_TO_IMPL(event)->event_type;
}
-axis2_status_t AXIS2_CALL axis2_event_free (struct axis2_event *event,
- axis2_env_t **env)
+axis2_status_t AXIS2_CALL
+axis2_event_free (struct axis2_event *event,
+ axis2_env_t **env)
{
axis2_event_impl_t *event_impl = NULL;
Modified: webservices/axis2/trunk/c/modules/core/engine/handler.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/handler.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/handler.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/handler.c Sun Mar 26 20:05:56 2006
@@ -30,28 +30,45 @@
/** Interface to implementation conversion macro */
#define AXIS2_INTF_TO_IMPL(handler) ((axis2_handler_impl_t *)handler)
-axis2_status_t AXIS2_CALL axis2_handler_free (struct axis2_handler * handler,
- axis2_env_t **env);
-axis2_qname_t* AXIS2_CALL axis2_handler_get_name(struct axis2_handler * handler,
- axis2_env_t **env) ;
-axis2_status_t AXIS2_CALL axis2_handler_invoke (struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx);
-axis2_param_t* AXIS2_CALL axis2_handler_get_param (struct axis2_handler * handler,
- axis2_env_t **env,
- axis2_char_t *name);
-axis2_status_t AXIS2_CALL axis2_handler_init (struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_handler_desc *handler_desc);
-axis2_handler_desc_t* AXIS2_CALL axis2_handler_get_handler_desc (struct axis2_handler * handler,
- axis2_env_t **env);
+
+axis2_status_t AXIS2_CALL
+axis2_handler_free (struct axis2_handler * handler,
+ axis2_env_t **env);
+
+axis2_qname_t* AXIS2_CALL
+axis2_handler_get_name(struct axis2_handler * handler,
+ axis2_env_t **env) ;
+
+
+axis2_status_t AXIS2_CALL
+axis2_handler_invoke (struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx);
+
+axis2_param_t* AXIS2_CALL
+axis2_handler_get_param (struct axis2_handler * handler,
+ axis2_env_t **env,
+ axis2_char_t *name);
+
+
+axis2_status_t AXIS2_CALL
+axis2_handler_init (struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_handler_desc *handler_desc);
+
+
+axis2_handler_desc_t* AXIS2_CALL
+axis2_handler_get_handler_desc (struct axis2_handler * handler,
+ axis2_env_t **env);
+
/*void* AXIS2_CALL axis2_handler_get_derived(struct axis2_handler * handler,
axis2_env_t **env);
axis2_status_t AXIS2_CALL axis2_handler_set_derived(struct axis2_handler * handler,
axis2_env_t **env, void* derived);
*/
-axis2_handler_t* AXIS2_CALL axis2_handler_create(axis2_env_t **env)
+axis2_handler_t* AXIS2_CALL
+axis2_handler_create(axis2_env_t **env)
{
axis2_handler_impl_t *handler_impl = NULL;
@@ -79,12 +96,24 @@
return NULL;
}
- handler_impl->handler.ops->free = axis2_handler_free;
- handler_impl->handler.ops->init = axis2_handler_init;
- handler_impl->handler.ops->invoke = axis2_handler_invoke;
- handler_impl->handler.ops->get_name = axis2_handler_get_name;
- handler_impl->handler.ops->get_param = axis2_handler_get_param;
- handler_impl->handler.ops->get_handler_desc = axis2_handler_get_handler_desc;
+ handler_impl->handler.ops->free =
+ axis2_handler_free;
+
+ handler_impl->handler.ops->init =
+ axis2_handler_init;
+
+ handler_impl->handler.ops->invoke =
+ axis2_handler_invoke;
+
+ handler_impl->handler.ops->get_name =
+ axis2_handler_get_name;
+
+ handler_impl->handler.ops->get_param =
+ axis2_handler_get_param;
+
+ handler_impl->handler.ops->get_handler_desc =
+ axis2_handler_get_handler_desc;
+
/*handler_impl->handler.ops->get_derived= axis2_handler_get_derived;
handler_impl->handler.ops->set_derived= axis2_handler_set_derived;
*/
@@ -122,17 +151,19 @@
return AXIS2_HANDLER_DESC_GET_QNAME(AXIS2_INTF_TO_IMPL(handler)->handler_desc, env);
}
-axis2_status_t AXIS2_CALL axis2_handler_invoke (struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_handler_invoke (struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx)
{
/**TODO invoke has to be implemented by an implementing handler */
return AXIS2_SUCCESS;
}
-axis2_param_t* AXIS2_CALL axis2_handler_get_param (struct axis2_handler * handler,
- axis2_env_t **env,
- axis2_char_t *name)
+axis2_param_t* AXIS2_CALL
+axis2_handler_get_param (struct axis2_handler * handler,
+ axis2_env_t **env,
+ axis2_char_t *name)
{
AXIS2_ENV_CHECK(env, NULL);
@@ -142,9 +173,10 @@
return AXIS2_HANDLER_DESC_GET_PARAM(AXIS2_INTF_TO_IMPL(handler)->handler_desc, env, name);
}
-axis2_status_t AXIS2_CALL axis2_handler_init (struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_handler_desc *handler_desc)
+axis2_status_t AXIS2_CALL
+axis2_handler_init (struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_handler_desc *handler_desc)
{
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
AXIS2_INTF_TO_IMPL(handler)->handler_desc = handler_desc;
@@ -153,8 +185,9 @@
return AXIS2_SUCCESS;
}
-axis2_handler_desc_t* AXIS2_CALL axis2_handler_get_handler_desc (struct axis2_handler * handler,
- axis2_env_t **env)
+axis2_handler_desc_t* AXIS2_CALL
+axis2_handler_get_handler_desc (struct axis2_handler * handler,
+ axis2_env_t **env)
{
AXIS2_ENV_CHECK(env, NULL);
return AXIS2_INTF_TO_IMPL(handler)->handler_desc;
Modified: webservices/axis2/trunk/c/modules/core/engine/phase.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/phase.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/phase.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/phase.c Sun Mar 26 20:05:56 2006
@@ -49,40 +49,106 @@
#define AXIS2_INTF_TO_IMPL(phase) ((axis2_phase_impl_t *)phase)
-axis2_status_t AXIS2_CALL axis2_phase_add_handler_at(struct axis2_phase *phase,
- axis2_env_t **env,
- int index,
- axis2_handler_t *handler);
-axis2_status_t AXIS2_CALL axis2_phase_add_handler(struct axis2_phase *phase,
- axis2_env_t **env,
- axis2_handler_t *handler);
-axis2_status_t AXIS2_CALL axis2_phase_invoke(struct axis2_phase *phase,
- axis2_env_t **env,
- axis2_msg_ctx_t *msg_ctx);
-axis2_char_t* AXIS2_CALL axis2_phase_get_name(struct axis2_phase *phase,
- axis2_env_t **env);
-int AXIS2_CALL axis2_phase_get_handler_count(struct axis2_phase *phase,
+axis2_status_t AXIS2_CALL
+axis2_phase_add_handler_at(struct axis2_phase *phase,
+ axis2_env_t **env,
+ int index,
+ axis2_handler_t *handler);
+
+axis2_status_t AXIS2_CALL
+axis2_phase_add_handler(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_handler_t *handler);
+
+axis2_status_t AXIS2_CALL
+axis2_phase_invoke(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx);
+
+
+axis2_char_t* AXIS2_CALL
+axis2_phase_get_name(struct axis2_phase *phase,
+ axis2_env_t **env);
+
+
+int AXIS2_CALL
+axis2_phase_get_handler_count(struct axis2_phase *phase,
axis2_env_t **env);
-int AXIS2_CALL _axis2_phase_get_before_after(axis2_handler_t *handler, axis2_env_t **env);
-axis2_status_t AXIS2_CALL axis2_phase_set_first_handler(struct axis2_phase *phase,
- axis2_env_t **env, axis2_handler_t * handler);
-axis2_status_t AXIS2_CALL axis2_phase_set_last_handler(struct axis2_phase *phase,
- axis2_env_t **env, axis2_handler_t * handler);
-axis2_status_t AXIS2_CALL axis2_phase_add_handler_desc(struct axis2_phase *phase,
- axis2_env_t **env, axis2_handler_desc_t * handler_desc);
-axis2_bool_t AXIS2_CALL _axis2_phase_is_valid_before(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler);
-axis2_bool_t AXIS2_CALL _axis2_phase_is_valid_after(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler);
-axis2_status_t AXIS2_CALL axis2_phase_insert_before(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler);
-axis2_status_t AXIS2_CALL axis2_phase_insert_after(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler) ;
-axis2_status_t AXIS2_CALL axis2_phase_insert_before_and_after(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler);
-axis2_status_t AXIS2_CALL axis2_phase_insert_handler_desc(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_desc_t * handler_desc);
-axis2_array_list_t* AXIS2_CALL axis2_phase_get_handlers(axis2_phase_t *phase, axis2_env_t **env);
-axis2_status_t AXIS2_CALL axis2_phase_invoke_start_from_handler(axis2_phase_t *phase, axis2_env_t **env, axis2_qname_t *qname, axis2_msg_ctx_t *msg_ctx) ;
-axis2_status_t AXIS2_CALL axis2_phase_free (struct axis2_phase *phase,
- axis2_env_t **env);
-
+
+int AXIS2_CALL
+_axis2_phase_get_before_after(axis2_handler_t *handler,
+ axis2_env_t **env);
-axis2_phase_t* AXIS2_CALL axis2_phase_create(axis2_env_t **env, const axis2_char_t *phase_name)
+
+axis2_status_t AXIS2_CALL
+axis2_phase_set_first_handler(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler);
+
+
+axis2_status_t AXIS2_CALL
+axis2_phase_set_last_handler(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler);
+
+
+axis2_status_t AXIS2_CALL
+axis2_phase_add_handler_desc(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_handler_desc_t * handler_desc);
+
+axis2_bool_t AXIS2_CALL
+_axis2_phase_is_valid_before(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler);
+
+axis2_bool_t AXIS2_CALL
+_axis2_phase_is_valid_after(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler);
+
+
+axis2_status_t AXIS2_CALL
+axis2_phase_insert_before(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler);
+
+axis2_status_t AXIS2_CALL
+axis2_phase_insert_after(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler) ;
+
+
+axis2_status_t AXIS2_CALL
+axis2_phase_insert_before_and_after(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler);
+
+
+axis2_status_t AXIS2_CALL
+axis2_phase_insert_handler_desc(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_desc_t * handler_desc);
+
+
+axis2_array_list_t* AXIS2_CALL
+axis2_phase_get_handlers(axis2_phase_t *phase,
+ axis2_env_t **env);
+
+axis2_status_t AXIS2_CALL
+axis2_phase_invoke_start_from_handler(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_qname_t *qname,
+ axis2_msg_ctx_t *msg_ctx) ;
+
+axis2_status_t AXIS2_CALL
+axis2_phase_free (struct axis2_phase *phase,
+ axis2_env_t **env);
+
+
+axis2_phase_t* AXIS2_CALL
+axis2_phase_create(axis2_env_t **env,
+ const axis2_char_t *phase_name)
{
axis2_phase_impl_t *phase_impl = NULL;
@@ -132,29 +198,59 @@
return NULL;
}
- phase_impl->phase.ops->add_handler_at = axis2_phase_add_handler_at;
- phase_impl->phase.ops->add_handler = axis2_phase_add_handler;
- phase_impl->phase.ops->invoke = axis2_phase_invoke;
- phase_impl->phase.ops->get_name = axis2_phase_get_name;
- phase_impl->phase.ops->get_handler_count = axis2_phase_get_handler_count;
- phase_impl->phase.ops->set_first_handler = axis2_phase_set_first_handler;
- phase_impl->phase.ops->set_last_handler = axis2_phase_set_last_handler;
- phase_impl->phase.ops->add_handler_desc = axis2_phase_add_handler_desc;
- phase_impl->phase.ops->insert_before = axis2_phase_insert_before;
- phase_impl->phase.ops->insert_after = axis2_phase_insert_after;
- phase_impl->phase.ops->insert_before_and_after = axis2_phase_insert_before_and_after;
- phase_impl->phase.ops->insert_handler_desc = axis2_phase_insert_handler_desc;
- phase_impl->phase.ops->get_handlers = axis2_phase_get_handlers;
- phase_impl->phase.ops->invoke_start_from_handler = axis2_phase_invoke_start_from_handler;
- phase_impl->phase.ops->free = axis2_phase_free;
+ phase_impl->phase.ops->add_handler_at =
+ axis2_phase_add_handler_at;
+
+ phase_impl->phase.ops->add_handler =
+ axis2_phase_add_handler;
+
+ phase_impl->phase.ops->invoke =
+ axis2_phase_invoke;
+
+ phase_impl->phase.ops->get_name =
+ axis2_phase_get_name;
+
+ phase_impl->phase.ops->get_handler_count =
+ axis2_phase_get_handler_count;
+
+ phase_impl->phase.ops->set_first_handler =
+ axis2_phase_set_first_handler;
+
+ phase_impl->phase.ops->set_last_handler =
+ axis2_phase_set_last_handler;
+
+ phase_impl->phase.ops->add_handler_desc =
+ axis2_phase_add_handler_desc;
+
+ phase_impl->phase.ops->insert_before =
+ axis2_phase_insert_before;
+
+ phase_impl->phase.ops->insert_after =
+ axis2_phase_insert_after;
+
+ phase_impl->phase.ops->insert_before_and_after =
+ axis2_phase_insert_before_and_after;
+
+ phase_impl->phase.ops->insert_handler_desc =
+ axis2_phase_insert_handler_desc;
+
+ phase_impl->phase.ops->get_handlers =
+ axis2_phase_get_handlers;
+
+ phase_impl->phase.ops->invoke_start_from_handler =
+ axis2_phase_invoke_start_from_handler;
+
+ phase_impl->phase.ops->free =
+ axis2_phase_free;
return &(phase_impl->phase);
}
-axis2_status_t AXIS2_CALL axis2_phase_add_handler_at(struct axis2_phase *phase,
- axis2_env_t **env,
- int index,
- axis2_handler_t *handler)
+axis2_status_t AXIS2_CALL
+axis2_phase_add_handler_at(struct axis2_phase *phase,
+ axis2_env_t **env,
+ int index,
+ axis2_handler_t *handler)
{
axis2_phase_impl_t *phase_impl = NULL;
@@ -162,7 +258,8 @@
phase_impl = AXIS2_INTF_TO_IMPL(phase);
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "axis2_handler_t *%s added to the index %d of the phase %s",
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "axis2_handler_t *%s added to the index %d of the phase %s",
AXIS2_QNAME_GET_LOCALPART(AXIS2_HANDLER_GET_NAME(handler, env), env),
index,
phase_impl->name);
@@ -170,9 +267,10 @@
return AXIS2_ARRAY_LIST_ADD_AT(phase_impl->handlers, env, index, handler);
}
-axis2_status_t AXIS2_CALL axis2_phase_add_handler(struct axis2_phase *phase,
- axis2_env_t **env,
- axis2_handler_t *handler)
+axis2_status_t AXIS2_CALL
+axis2_phase_add_handler(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_handler_t *handler)
{
axis2_phase_impl_t *phase_impl = NULL;
@@ -187,9 +285,10 @@
return AXIS2_ARRAY_LIST_ADD(phase_impl->handlers, env, handler);
}
-axis2_status_t AXIS2_CALL axis2_phase_invoke(struct axis2_phase *phase,
- axis2_env_t **env,
- axis2_msg_ctx_t *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_phase_invoke(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_msg_ctx_t *msg_ctx)
{
axis2_phase_impl_t *phase_impl = NULL;
int index = 0, size = 0;
@@ -210,9 +309,12 @@
}
else
{
- AXIS2_LOG_INFO((*env)->log, "Invoke the first handler %s within the phase %s",
- AXIS2_QNAME_GET_LOCALPART(AXIS2_HANDLER_GET_NAME(phase_impl->first_handler, env), env),
+ AXIS2_LOG_INFO((*env)->log,
+ "Invoke the first handler %s within the phase %s",
+ AXIS2_QNAME_GET_LOCALPART(
+ AXIS2_HANDLER_GET_NAME(phase_impl->first_handler, env), env),
phase_impl->name);
+
status = AXIS2_HANDLER_INVOKE(phase_impl->first_handler, env, msg_ctx);
if (status != AXIS2_SUCCESS)
return status;
@@ -229,12 +331,15 @@
}
else
{
- axis2_handler_t *handler = (axis2_handler_t*) AXIS2_ARRAY_LIST_GET(phase_impl->handlers, env, index);
+ axis2_handler_t *handler = (axis2_handler_t*)
+ AXIS2_ARRAY_LIST_GET(phase_impl->handlers, env, index);
if (handler)
{
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Invoke the handler %s within the phase %s",
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Invoke the handler %s within the phase %s",
AXIS2_QNAME_GET_LOCALPART(AXIS2_HANDLER_GET_NAME(handler, env), env),
phase_impl->name);
+
status = AXIS2_HANDLER_INVOKE(handler, env, msg_ctx);
if (status != AXIS2_SUCCESS)
return status;
@@ -267,14 +372,16 @@
}
-axis2_char_t* AXIS2_CALL axis2_phase_get_name(struct axis2_phase *phase,
+axis2_char_t* AXIS2_CALL
+axis2_phase_get_name(struct axis2_phase *phase,
axis2_env_t **env)
{
AXIS2_ENV_CHECK(env, NULL);
return AXIS2_INTF_TO_IMPL(phase)->name;
}
-int AXIS2_CALL axis2_phase_get_handler_count(struct axis2_phase *phase,
+int AXIS2_CALL
+axis2_phase_get_handler_count(struct axis2_phase *phase,
axis2_env_t **env)
{
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
@@ -284,7 +391,9 @@
/*/////////////////////////////////////////////////////////////// FROM PhaseMetaData /////////*/
-int AXIS2_CALL _axis2_phase_get_before_after(axis2_handler_t *handler, axis2_env_t **env)
+int AXIS2_CALL
+_axis2_phase_get_before_after(axis2_handler_t *handler,
+ axis2_env_t **env)
{
axis2_char_t *before = NULL, *after = NULL;
axis2_handler_desc_t *handler_desc = NULL;
@@ -332,8 +441,10 @@
}
}
-axis2_status_t AXIS2_CALL axis2_phase_set_first_handler(struct axis2_phase *phase,
- axis2_env_t **env, axis2_handler_t * handler)
+axis2_status_t AXIS2_CALL
+axis2_phase_set_first_handler(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler)
{
axis2_phase_impl_t *phase_impl = NULL;
@@ -360,8 +471,10 @@
return AXIS2_SUCCESS;
}
-axis2_status_t AXIS2_CALL axis2_phase_set_last_handler(struct axis2_phase *phase,
- axis2_env_t **env, axis2_handler_t * handler)
+axis2_status_t AXIS2_CALL
+axis2_phase_set_last_handler(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler)
{
axis2_phase_impl_t *phase_impl = NULL;
@@ -388,8 +501,10 @@
return AXIS2_SUCCESS;
}
-axis2_status_t AXIS2_CALL axis2_phase_add_handler_desc(struct axis2_phase *phase,
- axis2_env_t **env, axis2_handler_desc_t * handler_desc)
+axis2_status_t AXIS2_CALL
+axis2_phase_add_handler_desc(struct axis2_phase *phase,
+ axis2_env_t **env,
+ axis2_handler_desc_t * handler_desc)
{
axis2_phase_impl_t *phase_impl = NULL;
axis2_phase_rule_t *rules = NULL;
@@ -472,7 +587,10 @@
}
}
-axis2_bool_t AXIS2_CALL _axis2_phase_is_valid_before(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler)
+axis2_bool_t AXIS2_CALL
+_axis2_phase_is_valid_before(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler)
{
axis2_phase_impl_t *phase_impl = NULL;
axis2_phase_rule_t *rules = NULL;
@@ -515,7 +633,10 @@
return AXIS2_TRUE;
}
-axis2_bool_t AXIS2_CALL _axis2_phase_is_valid_after(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler)
+axis2_bool_t AXIS2_CALL
+_axis2_phase_is_valid_after(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler)
{
axis2_phase_impl_t *phase_impl = NULL;
axis2_phase_rule_t *rules = NULL;
@@ -558,7 +679,10 @@
return AXIS2_TRUE;
}
-axis2_status_t AXIS2_CALL axis2_phase_insert_before(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler)
+axis2_status_t AXIS2_CALL
+axis2_phase_insert_before(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler)
{
axis2_phase_impl_t *phase_impl = NULL;
axis2_phase_rule_t *rules = NULL;
@@ -651,7 +775,10 @@
return AXIS2_ARRAY_LIST_ADD(phase_impl->handlers, env, handler);
}
-axis2_status_t AXIS2_CALL axis2_phase_insert_after(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler)
+axis2_status_t AXIS2_CALL
+axis2_phase_insert_after(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler)
{
axis2_phase_impl_t *phase_impl = NULL;
axis2_phase_rule_t *rules = NULL;
@@ -744,7 +871,10 @@
return AXIS2_ARRAY_LIST_ADD(phase_impl->handlers, env, handler);
}
-axis2_status_t AXIS2_CALL axis2_phase_insert_before_and_after(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_t * handler)
+axis2_status_t AXIS2_CALL
+axis2_phase_insert_before_and_after(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_t * handler)
{
int before = -1;
int after = -1;
@@ -894,7 +1024,10 @@
return AXIS2_ARRAY_LIST_ADD(phase_impl->handlers, env, handler);
}
-axis2_status_t AXIS2_CALL axis2_phase_insert_handler_desc(axis2_phase_t *phase, axis2_env_t **env, axis2_handler_desc_t * handler_desc)
+axis2_status_t AXIS2_CALL
+axis2_phase_insert_handler_desc(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_handler_desc_t * handler_desc)
{
axis2_phase_impl_t *phase_impl = NULL;
int type = 0;
@@ -948,13 +1081,19 @@
return status;
}
-axis2_array_list_t* AXIS2_CALL axis2_phase_get_handlers(axis2_phase_t *phase, axis2_env_t **env)
+axis2_array_list_t* AXIS2_CALL
+axis2_phase_get_handlers(axis2_phase_t *phase,
+ axis2_env_t **env)
{
AXIS2_ENV_CHECK(env, NULL);
return AXIS2_INTF_TO_IMPL(phase)->handlers;
}
-axis2_status_t AXIS2_CALL axis2_phase_invoke_start_from_handler(axis2_phase_t *phase, axis2_env_t **env, axis2_qname_t *qname, axis2_msg_ctx_t *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_phase_invoke_start_from_handler(axis2_phase_t *phase,
+ axis2_env_t **env,
+ axis2_qname_t *qname,
+ axis2_msg_ctx_t *msg_ctx)
{
axis2_phase_impl_t *phase_impl = NULL;
int size = 0, i = 0;
@@ -992,8 +1131,9 @@
return AXIS2_FAILURE;
}
-axis2_status_t AXIS2_CALL axis2_phase_free (struct axis2_phase *phase,
- axis2_env_t **env)
+axis2_status_t AXIS2_CALL
+axis2_phase_free (struct axis2_phase *phase,
+ axis2_env_t **env)
{
axis2_phase_impl_t *phase_impl = NULL;
Modified: webservices/axis2/trunk/c/modules/core/engine/req_uri_disp.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/req_uri_disp.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/req_uri_disp.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/req_uri_disp.c Sun Mar 26 20:05:56 2006
@@ -24,17 +24,24 @@
#include <axis2_addr.h>
#include <axis2_utils.h>
-axis2_status_t AXIS2_CALL axis2_req_uri_disp_invoke (struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx);
-axis2_svc_t* AXIS2_CALL axis2_req_uri_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env);
-axis2_op_t* AXIS2_CALL axis2_req_uri_disp_find_op(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env,
- axis2_svc_t *svc);
+axis2_status_t AXIS2_CALL
+axis2_req_uri_disp_invoke (struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx);
+
+axis2_svc_t* AXIS2_CALL
+axis2_req_uri_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env);
+
+
+axis2_op_t* AXIS2_CALL
+axis2_req_uri_disp_find_op(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env,
+ axis2_svc_t *svc);
-axis2_disp_t* AXIS2_CALL axis2_req_uri_disp_create(axis2_env_t **env)
+axis2_disp_t* AXIS2_CALL
+axis2_req_uri_disp_create(axis2_env_t **env)
{
axis2_disp_t *disp = NULL;
axis2_handler_t *handler = NULL;
@@ -56,7 +63,8 @@
handler = AXIS2_DISP_GET_BASE(disp, env);
if (!handler)
{
- AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_INVALID_HANDLER_STATE, AXIS2_FAILURE);
+ AXIS2_ERROR_SET((*env)->error,
+ AXIS2_ERROR_INVALID_HANDLER_STATE, AXIS2_FAILURE);
return NULL;
}
@@ -81,8 +89,9 @@
* @param messageContext
* @return
*/
-axis2_svc_t* AXIS2_CALL axis2_req_uri_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env)
+axis2_svc_t* AXIS2_CALL
+axis2_req_uri_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env)
{
axis2_endpoint_ref_t *endpoint_ref = NULL;
axis2_svc_t *svc = NULL;
@@ -99,7 +108,8 @@
if (address)
{
axis2_char_t **url_tokens = NULL;
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Checking for service using target endpoint address : %s", address);
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Checking for service using target endpoint address : %s", address);
url_tokens = axis2_parse_request_url_for_svc_and_op(env, address);
@@ -118,7 +128,8 @@
{
svc = AXIS2_CONF_GET_SVC(conf, env, url_tokens[0]);
if (svc)
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Service found using target endpoint address");
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Service found using target endpoint address");
}
}
}
@@ -138,9 +149,10 @@
* @param msg_ctx
* @return
*/
-axis2_op_t* AXIS2_CALL axis2_req_uri_disp_find_op(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env,
- axis2_svc_t *svc)
+axis2_op_t* AXIS2_CALL
+axis2_req_uri_disp_find_op(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env,
+ axis2_svc_t *svc)
{
axis2_endpoint_ref_t *endpoint_ref = NULL;
axis2_op_t *op = NULL;
@@ -166,12 +178,14 @@
if (url_tokens[1])
{
axis2_qname_t *op_qname = NULL;
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Checking for operation using target endpoint uri fragment : %s", url_tokens[1]);
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Checking for operation using target endpoint uri fragment : %s", url_tokens[1]);
op_qname = axis2_qname_create(env, url_tokens[1], NULL, NULL);
op = AXIS2_SVC_GET_OP_WITH_NAME(svc, env, AXIS2_QNAME_GET_LOCALPART(op_qname, env));
AXIS2_QNAME_FREE(op_qname, env);
if (op)
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Operation found using target endpoint uri fragment");
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Operation found using target endpoint uri fragment");
}
if(NULL != url_tokens[0])
AXIS2_FREE((*env)->allocator, url_tokens[0]);
@@ -185,9 +199,10 @@
return op;
}
-axis2_status_t AXIS2_CALL axis2_req_uri_disp_invoke(struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_req_uri_disp_invoke(struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx)
{
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
Modified: webservices/axis2/trunk/c/modules/core/engine/soap_action_disp.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/soap_action_disp.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/soap_action_disp.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/soap_action_disp.c Sun Mar 26 20:05:56 2006
@@ -24,17 +24,25 @@
#include <axis2_addr.h>
#include <axis2_utils.h>
-axis2_status_t AXIS2_CALL axis2_soap_action_disp_invoke (struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx);
-axis2_svc_t* AXIS2_CALL axis2_soap_action_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env);
-axis2_op_t* AXIS2_CALL axis2_soap_action_disp_find_op(axis2_msg_ctx_t *msg_ctx,
+axis2_status_t AXIS2_CALL
+axis2_soap_action_disp_invoke (struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx);
+
+
+axis2_svc_t* AXIS2_CALL
+axis2_soap_action_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env);
+
+
+axis2_op_t* AXIS2_CALL
+axis2_soap_action_disp_find_op(axis2_msg_ctx_t *msg_ctx,
axis2_env_t **env,
axis2_svc_t *svc);
-axis2_disp_t* AXIS2_CALL axis2_soap_action_disp_create(axis2_env_t **env)
+axis2_disp_t* AXIS2_CALL
+axis2_soap_action_disp_create(axis2_env_t **env)
{
axis2_disp_t *disp = NULL;
axis2_handler_t *handler = NULL;
@@ -81,8 +89,9 @@
* @param messageContext
* @return
*/
-axis2_svc_t* AXIS2_CALL axis2_soap_action_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env)
+axis2_svc_t* AXIS2_CALL
+axis2_soap_action_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env)
{
AXIS2_ENV_CHECK(env, NULL);
@@ -98,7 +107,8 @@
* @param msg_ctx
* @return
*/
-axis2_op_t* AXIS2_CALL axis2_soap_action_disp_find_op(axis2_msg_ctx_t *msg_ctx,
+axis2_op_t* AXIS2_CALL
+axis2_soap_action_disp_find_op(axis2_msg_ctx_t *msg_ctx,
axis2_env_t **env,
axis2_svc_t *svc)
{
@@ -112,7 +122,8 @@
if (action)
{
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Checking for operation using SOAPAction : %s", action);
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Checking for operation using SOAPAction : %s", action);
op = AXIS2_SVC_GET_OP_BY_SOAP_ACTION(svc, env, action);
if (!op)
@@ -132,7 +143,10 @@
if (op_name)
{
axis2_qname_t *op_qname = axis2_qname_create(env, op_name, NULL, NULL);
- op = AXIS2_SVC_GET_OP_WITH_NAME(svc, env, AXIS2_QNAME_GET_LOCALPART(op_qname, env));
+
+ op = AXIS2_SVC_GET_OP_WITH_NAME(svc, env,
+ AXIS2_QNAME_GET_LOCALPART(op_qname, env));
+
AXIS2_QNAME_FREE(op_qname, env);
}
}
@@ -144,9 +158,10 @@
return op;
}
-axis2_status_t AXIS2_CALL axis2_soap_action_disp_invoke(struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_soap_action_disp_invoke(struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx)
{
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
Modified: webservices/axis2/trunk/c/modules/core/engine/soap_body_disp.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/soap_body_disp.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/soap_body_disp.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/soap_body_disp.c Sun Mar 26 20:05:56 2006
@@ -24,17 +24,24 @@
#include <axis2_soap_envelope.h>
#include <axis2_soap_body.h>
-axis2_status_t AXIS2_CALL axis2_soap_body_disp_invoke (struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx);
-axis2_svc_t* AXIS2_CALL axis2_soap_body_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env);
-axis2_op_t* AXIS2_CALL axis2_soap_body_disp_find_op(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env,
- axis2_svc_t *svc);
+axis2_status_t AXIS2_CALL
+axis2_soap_body_disp_invoke (struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx);
+
+axis2_svc_t* AXIS2_CALL
+axis2_soap_body_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env);
+
+
+axis2_op_t* AXIS2_CALL
+axis2_soap_body_disp_find_op(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env,
+ axis2_svc_t *svc);
-axis2_disp_t* AXIS2_CALL axis2_soap_body_disp_create(axis2_env_t **env)
+axis2_disp_t* AXIS2_CALL
+axis2_soap_body_disp_create(axis2_env_t **env)
{
axis2_disp_t *disp = NULL;
axis2_handler_t *handler = NULL;
@@ -49,14 +56,16 @@
disp = axis2_disp_create(env, qname);
if (!disp)
{
- AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+ AXIS2_ERROR_SET((*env)->error,
+ AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
return NULL;
}
handler = AXIS2_DISP_GET_BASE(disp, env);
if (!handler)
{
- AXIS2_ERROR_SET((*env)->error, AXIS2_ERROR_INVALID_HANDLER_STATE, AXIS2_FAILURE);
+ AXIS2_ERROR_SET((*env)->error,
+ AXIS2_ERROR_INVALID_HANDLER_STATE, AXIS2_FAILURE);
return NULL;
}
@@ -81,8 +90,9 @@
* @param messageContext
* @return
*/
-axis2_svc_t* AXIS2_CALL axis2_soap_body_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env)
+axis2_svc_t* AXIS2_CALL
+axis2_soap_body_disp_find_svc(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env)
{
axis2_soap_envelope_t *soap_envelope = NULL;
axis2_svc_t *svc = NULL;
@@ -114,7 +124,8 @@
if (uri)
{
axis2_char_t **url_tokens = NULL;
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Checking for service using SOAP message body's first child's namespace URI : %s", uri);
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Checking for service using SOAP message body's first child's namespace URI : %s", uri);
url_tokens = axis2_parse_request_url_for_svc_and_op(env, uri);
@@ -133,7 +144,8 @@
{
svc = AXIS2_CONF_GET_SVC(conf, env, url_tokens[0]);
if (svc)
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Service found using SOAP message body's first child's namespace URI");
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Service found using SOAP message body's first child's namespace URI");
}
}
AXIS2_FREE((*env)->allocator, url_tokens[0]);
@@ -161,9 +173,10 @@
* @param msg_ctx
* @return
*/
-axis2_op_t* AXIS2_CALL axis2_soap_body_disp_find_op(axis2_msg_ctx_t *msg_ctx,
- axis2_env_t **env,
- axis2_svc_t *svc)
+axis2_op_t* AXIS2_CALL
+axis2_soap_body_disp_find_op(axis2_msg_ctx_t *msg_ctx,
+ axis2_env_t **env,
+ axis2_svc_t *svc)
{
axis2_soap_envelope_t *soap_envelope = NULL;
axis2_op_t *op = NULL;
@@ -194,12 +207,17 @@
if (element_name)
{
axis2_qname_t *op_qname = NULL;
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Checking for operation using SOAP message body's first child's local name : %s", element_name);
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Checking for operation using SOAP message body's first child's local name : %s",
+ element_name);
op_qname = axis2_qname_create(env, element_name, NULL, NULL);
+
op = AXIS2_SVC_GET_OP_WITH_NAME(svc, env, AXIS2_QNAME_GET_LOCALPART(op_qname, env));
+
AXIS2_QNAME_FREE(op_qname, env);
if (op)
- AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI, "Operation found using SOAP message body's first child's local name");
+ AXIS2_LOG_DEBUG((*env)->log, AXIS2_LOG_SI,
+ "Operation found using SOAP message body's first child's local name");
}
}
@@ -211,9 +229,10 @@
return op;
}
-axis2_status_t AXIS2_CALL axis2_soap_body_disp_invoke(struct axis2_handler * handler,
- axis2_env_t **env,
- struct axis2_msg_ctx *msg_ctx)
+axis2_status_t AXIS2_CALL
+axis2_soap_body_disp_invoke(struct axis2_handler * handler,
+ axis2_env_t **env,
+ struct axis2_msg_ctx *msg_ctx)
{
AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
Modified: webservices/axis2/trunk/c/modules/mod_addr/addr_out_handler.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/mod_addr/addr_out_handler.c?rev=389016&r1=389015&r2=389016&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/mod_addr/addr_out_handler.c (original)
+++ webservices/axis2/trunk/c/modules/mod_addr/addr_out_handler.c Sun Mar 26 20:05:56 2006
@@ -399,9 +399,6 @@
axis2_om_attribute_t *om_attr = NULL;
axis2_om_namespace_t *addr_ns_obj = NULL;
axis2_om_namespace_t *dec_ns = NULL;
- addr_ns_obj =
- axis2_om_namespace_create (env, addr_ns,
- AXIS2_WSA_DEFAULT_PREFIX);
relates_to_header_ele =
(axis2_om_element_t *)
AXIS2_OM_NODE_GET_DATA_ELEMENT (relates_to_header_node,
@@ -410,20 +407,41 @@
{
dec_ns = AXIS2_OM_ELEMENT_FIND_DECLARED_NAMESPACE(relates_to_header_ele, env,
addr_ns, AXIS2_WSA_DEFAULT_PREFIX);
- if(!dec_ns)
+ if(NULL != dec_ns)
{
- AXIS2_OM_NAMESPACE_FREE(addr_ns_obj, env);
addr_ns_obj = dec_ns;
}
+ else
+ {
+ addr_ns_obj = axis2_om_namespace_create (env, addr_ns, AXIS2_WSA_DEFAULT_PREFIX);
+ }
+
+ om_attr = axis2_om_attribute_create (env,
+ AXIS2_WSA_RELATES_TO_RELATIONSHIP_TYPE,
+ AXIS2_WSA_RELATES_TO_RELATIONSHIP_TYPE_DEFAULT_VALUE_SUBMISSION,
+ addr_ns_obj);
+
+ AXIS2_OM_ELEMENT_ADD_ATTRIBUTE (relates_to_header_ele, env,
+ om_attr, relates_to_header_node);
+
+ }
+ if(NULL != relates_to_header_ele)
+ {
+ dec_ns = AXIS2_OM_ELEMENT_FIND_DECLARED_NAMESPACE(relates_to_header_ele, env,
+ addr_ns, AXIS2_WSA_DEFAULT_PREFIX);
+ if(NULL == dec_ns)
+ {
+ dec_ns = AXIS2_OM_ELEMENT_FIND_NAMESPACE(relates_to_header_ele, env,
+ relates_to_header_node, addr_ns, AXIS2_WSA_DEFAULT_PREFIX);
+ if(NULL != dec_ns)
+ {
+ AXIS2_OM_NAMESPACE_FREE(addr_ns_obj, env);
+ addr_ns_obj = NULL ;
+ AXIS2_OM_ATTRIBUTE_SET_NAMESPACE(om_attr, env, dec_ns);
+ }
+ }
}
- om_attr =
- axis2_om_attribute_create (env,
- AXIS2_WSA_RELATES_TO_RELATIONSHIP_TYPE,
- AXIS2_WSA_RELATES_TO_RELATIONSHIP_TYPE_DEFAULT_VALUE_SUBMISSION,
- addr_ns_obj);
- AXIS2_OM_ELEMENT_ADD_ATTRIBUTE (relates_to_header_ele, env,
- om_attr,
- relates_to_header_node);
+
}
}
}