axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From p...@apache.org
Subject svn commit: r433922 - in /webservices/axis2/trunk/c: include/axis2_phase_holder.h include/axis2_phase_resolver.h modules/core/phaseresolver/phase_resolver.c
Date Wed, 23 Aug 2006 06:09:43 GMT
Author: pini
Date: Tue Aug 22 23:09:42 2006
New Revision: 433922

URL: http://svn.apache.org/viewvc?rev=433922&view=rev
Log:
Fomatting fixes and parameter changes to const.

Modified:
    webservices/axis2/trunk/c/include/axis2_phase_holder.h
    webservices/axis2/trunk/c/include/axis2_phase_resolver.h
    webservices/axis2/trunk/c/modules/core/phaseresolver/phase_resolver.c

Modified: webservices/axis2/trunk/c/include/axis2_phase_holder.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/include/axis2_phase_holder.h?rev=433922&r1=433921&r2=433922&view=diff
==============================================================================
--- webservices/axis2/trunk/c/include/axis2_phase_holder.h (original)
+++ webservices/axis2/trunk/c/include/axis2_phase_holder.h Tue Aug 22 23:09:42 2006
@@ -65,6 +65,7 @@
          * De-allocate memory
          * @param phase_holder pointer to phase holder
          * @param env pointer to environment struct
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
          */
         axis2_status_t (AXIS2_CALL *
                 free)(
@@ -87,6 +88,7 @@
          * @param phase_holder pointer to phase holder
          * @param env pointer to environment struct
          * @para handler pointer to handler
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
          */
         axis2_status_t (AXIS2_CALL *
                 add_handler)(
@@ -115,6 +117,7 @@
          * @param env pointer to environment struct
          * @param phase pointer to phase
          * @param handlers pointer to handlers
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
          */
         axis2_status_t (AXIS2_CALL *
                 build_transport_handler_chain)(

Modified: webservices/axis2/trunk/c/include/axis2_phase_resolver.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/include/axis2_phase_resolver.h?rev=433922&r1=433921&r2=433922&view=diff
==============================================================================
--- webservices/axis2/trunk/c/include/axis2_phase_resolver.h (original)
+++ webservices/axis2/trunk/c/include/axis2_phase_resolver.h Tue Aug 22 23:09:42 2006
@@ -75,12 +75,13 @@
      * Wsdl Phase Resolver ops struct
      * Encapsulator struct for ops of axis2_phase_resolver
      */
-    AXIS2_DECLARE_DATA struct axis2_phase_resolver_ops
+    struct axis2_phase_resolver_ops
     {
-        /** De-allocate memory
-    * @param phase_recolver pointer to phase resolver
-    * @param env pointer to environment struct
-         * @return status code
+        /** 
+         * De-allocate memory
+         * @param phase_recolver pointer to phase resolver
+         * @param env pointer to environment struct
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
          */
         axis2_status_t (AXIS2_CALL *
                 free)(
@@ -88,8 +89,9 @@
                     const axis2_env_t *env);
 
         /**
-    * @param phase_resolver pointer to phase resolver
-    * @param env pointer to environment struct
+         * @param phase_resolver pointer to phase resolver
+         * @param env pointer to environment struct
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
          */
         axis2_status_t (AXIS2_CALL *
                 build_chains)(
@@ -98,9 +100,10 @@
 
         /**
          * To build the opration for the opeartion which the module going to be added
-    * @param phase_resolver pointer to phase resolver
+         * @param phase_resolver pointer to phase resolver
          * @param env pointer to environment struct
-    * @param op pointer to operation
+         * @param op pointer to operation
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
          */
         axis2_status_t (AXIS2_CALL *
                 build_module_op)(
@@ -110,8 +113,9 @@
 
         /**
          * Method buildTranspotsChains
-    * @param phase_resolver pointer to phase resolver
-    * @param env pointer to environment struct
+         * @param phase_resolver pointer to phase resolver
+         * @param env pointer to environment struct
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
          */
         axis2_status_t (AXIS2_CALL *
                 build_transport_chains)(
@@ -119,11 +123,12 @@
                     const axis2_env_t *env);
 
 
-   /**
-    * @param phase_resolver pointer to phase resolver
-    * @param env pointer to environment struct
-    * @param module pointer to module
-    */
+        /**
+         * @param phase_resolver pointer to phase resolver
+         * @param env pointer to environment struct
+         * @param module pointer to module
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
+         */
         axis2_status_t (AXIS2_CALL *
                 engage_module_globally)(
                     axis2_phase_resolver_t *phase_resolver,
@@ -132,10 +137,11 @@
 
         /**
          * To engage modules come form global
-    * @param phase_resolver pointer to phase resolver
-    * @param env pointer to environment struct
-    * @param svc pointer to service
-    * @param module_desc pointer to module descriptoin
+         * @param phase_resolver pointer to phase resolver
+         * @param env pointer to environment struct
+         * @param svc pointer to service
+         * @param module_desc pointer to module descriptoin
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
          */
         axis2_status_t (AXIS2_CALL *
                 engage_module_to_svc_from_global)(
@@ -144,12 +150,13 @@
                     struct axis2_svc *svc,
                     struct axis2_module_desc *module_desc);
 
-   /**
-    * @param phase_resolver pointer to phase resolver
-    * @param env pointer to environmnet struct
-    * @param svc pointer to service
-    * @param module_desc pointedr to module description
-    */
+        /**
+         * @param phase_resolver pointer to phase resolver
+         * @param env pointer to environmnet struct
+         * @param svc pointer to service
+         * @param module_desc pointedr to module description
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
+         */
         axis2_status_t (AXIS2_CALL *
                 engage_module_to_svc)(
                     axis2_phase_resolver_t *phase_resolver,
@@ -157,12 +164,13 @@
                     struct axis2_svc *svc,
                     struct axis2_module_desc *module_desc);
 
-   /**
-    * @param phase_resolver pointer to phase resolver
-    * @param env pointer to environment struct
-    * @param axis_op pointer to axis operation
-    * @param pointer to module description
-    */
+        /**
+         * @param phase_resolver pointer to phase resolver
+         * @param env pointer to environment struct
+         * @param axis_op pointer to axis operation
+         * @param pointer to module description
+         * @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
+         */
         axis2_status_t (AXIS2_CALL *
                 engage_module_to_op)(
                     axis2_phase_resolver_t *phase_resolver,
@@ -176,9 +184,9 @@
     /**
      * Phase Resolver struct  
      */
-    AXIS2_DECLARE_DATA struct axis2_phase_resolver
+    struct axis2_phase_resolver
     {
-   /** Operations of phase resolver */
+        /** Operations of phase resolver */
         axis2_phase_resolver_ops_t *ops;
     };
 
@@ -187,7 +195,7 @@
      * @param env pointer to environment struct
      * @return pointer to newly created phase resolver
      */
-    AXIS2_EXTERN axis2_phase_resolver_t * AXIS2_CALL
+    AXIS2_EXTERN axis2_phase_resolver_t *AXIS2_CALL
     axis2_phase_resolver_create (
         const axis2_env_t *env);
 
@@ -196,7 +204,7 @@
      * @param env pointer to environment struct
      * @param axis2_config pointer to aixs2 configuratoin
      */
-    AXIS2_EXTERN axis2_phase_resolver_t * AXIS2_CALL
+    AXIS2_EXTERN axis2_phase_resolver_t *AXIS2_CALL
     axis2_phase_resolver_create_with_config (
         const axis2_env_t *env,
         struct axis2_conf *axis2_config);
@@ -206,7 +214,7 @@
      * @param aixs2_config pointer to aixs2_config
      * @param svc pointer to service
      */
-    AXIS2_EXTERN axis2_phase_resolver_t * AXIS2_CALL
+    AXIS2_EXTERN axis2_phase_resolver_t *AXIS2_CALL
     axis2_phase_resolver_create_with_config_and_svc (
         const axis2_env_t *env,
         struct axis2_conf *axis2_config,
@@ -215,48 +223,48 @@
 /*************************** Function macros **********************************/
 
 /** Frees the phase resolver.
-*   @sa axis2_phase_resolver_ops#free */
+    @sa axis2_phase_resolver_ops#free */
 #define AXIS2_PHASE_RESOLVER_FREE(phase_resolver, env) \
       ((phase_resolver)->ops->free (phase_resolver, env))
 
 /** Build chains.
-*   @sa axis2_phase_resolver_ops#build_chains */
+    @sa axis2_phase_resolver_ops#build_chains */
 #define AXIS2_PHASE_RESOLVER_BUILD_CHAINS(phase_resolver, env) \
       ((phase_resolver)->ops->build_chains (phase_resolver, env))
 
 /** Build module operations.
-*   @sa axis2_phase_resolver_ops#build_module_op */
+    @sa axis2_phase_resolver_ops#build_module_op */
 #define AXIS2_PHASE_RESOLVER_BUILD_MODULE_OP(phase_resolver, env, op) \
       ((phase_resolver)->ops->build_module_op (phase_resolver, env, op))
 
 /** Build transport chains.
-*   @sa axis2_phase_resolver_ops#build_transport_chains */
+    @sa axis2_phase_resolver_ops#build_transport_chains */
 #define AXIS2_PHASE_RESOLVER_BUILD_TRANSPORT_CHAINS(phase_resolver, env) \
       ((phase_resolver)->ops->build_transport_chains (phase_resolver, env))
 
 /** Engages module globally.
-*   @sa axis2_phase_resolver_ops#engage_module_globally */
+    @sa axis2_phase_resolver_ops#engage_module_globally */
 #define AXIS2_PHASE_RESOLVER_ENGAGE_MODULE_GLOBALLY(phase_resolver, env, module) \
       ((phase_resolver)->ops->engage_module_globally (phase_resolver, env, module))
 
 /** Engages module to service from global.
-*   @sa axis2_phase_resolver_ops#engage_module_to_svc_from_global */
+    @sa axis2_phase_resolver_ops#engage_module_to_svc_from_global */
 #define AXIS2_PHASE_RESOLVER_ENGAGE_MODULE_TO_SVC_FROM_GLOBAL(phase_resolver, env, svc, module_desc) \
       ((phase_resolver)->ops->engage_module_to_svc_from_global (phase_resolver, env, svc, module_desc))
 
 /** Engage module to service.
-*   @sa axis2_phase_resolver_ops#engage_module_to_svc */
+    @sa axis2_phase_resolver_ops#engage_module_to_svc */
 #define AXIS2_PHASE_RESOLVER_ENGAGE_MODULE_TO_SVC(phase_resolver, env, svc, module_desc) \
       ((phase_resolver)->ops->engage_module_to_svc (phase_resolver, env, svc, module_desc))
 
 /** Engage module to operation.
-*   @sa axis2_phase_resolver_ops#engage_module_to_op */
+    @sa axis2_phase_resolver_ops#engage_module_to_op */
 #define AXIS2_PHASE_RESOLVER_ENGAGE_MODULE_TO_OP(phase_resolver, env, axis_op, module_desc) \
       ((phase_resolver)->ops->engage_module_to_op (phase_resolver, env, axis_op, module_desc))
 
 
 /*************************** End of function macros ***************************/
-/** @} */
+    /** @} */
 
 #ifdef __cplusplus
 }

Modified: webservices/axis2/trunk/c/modules/core/phaseresolver/phase_resolver.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/phaseresolver/phase_resolver.c?rev=433922&r1=433921&r2=433922&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/phaseresolver/phase_resolver.c (original)
+++ webservices/axis2/trunk/c/modules/core/phaseresolver/phase_resolver.c Tue Aug 22 23:09:42 2006
@@ -22,18 +22,18 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
- 
+
 #include <axis2_phase_resolver.h>
 #include <axis2_property.h>
-   
-/** 
+
+/**
  * @brief Wsdl phase holder struct impl
  * Phase Resolver
  * This class hold all the phases found in the services.xml and server.xml
- */ 
+ */
 typedef struct axis2_phase_resolver_impl
 {
-   axis2_phase_resolver_t phase_resolver;
+    axis2_phase_resolver_t phase_resolver;
     /**
      * Field axisConfig
      */
@@ -48,26 +48,28 @@
      * Field phaseHolder
      */
     axis2_phase_holder_t *phase_holder;
-    
-} axis2_phase_resolver_impl_t;
+}
+axis2_phase_resolver_impl_t;
 
 #define AXIS2_INTF_TO_IMPL(phase_resolver) ((axis2_phase_resolver_impl_t *)phase_resolver)
 
 /************************* Function prototypes ********************************/
 
 axis2_status_t AXIS2_CALL
-   axis2_phase_resolver_free (
-                axis2_phase_resolver_t *phase_resolver,
-            const axis2_env_t *env);
+axis2_phase_resolver_free(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env);
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_build_chains(axis2_phase_resolver_t *phase_resolver,
-                                    const axis2_env_t *env);
+axis2_phase_resolver_build_chains(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env);
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_build_module_op(axis2_phase_resolver_t *phase_resolver,
-                                    const axis2_env_t *env,
-                                    axis2_op_t *op);
+axis2_phase_resolver_build_module_op(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_op_t *op);
 
 /**
  * this opeartion is used to build all the three cahins ,
@@ -77,189 +79,193 @@
  * type = 3 fault flow
  *
  * @param type
- */                                    
+ */
 static axis2_status_t
-axis2_phase_resolver_build_execution_chains(axis2_phase_resolver_t *phase_resolver,
-                                    const axis2_env_t *env,
-                                    int type,
-                                    axis2_op_t *op);
+axis2_phase_resolver_build_execution_chains(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    int type,
+    axis2_op_t *op);
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_build_transport_chains(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env);
-
+axis2_phase_resolver_build_transport_chains(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env);
 
 static axis2_status_t
-axis2_phase_resolver_build_in_transport_chains(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_transport_in_desc_t *transport);
+axis2_phase_resolver_build_in_transport_chains(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_transport_in_desc_t *transport);
 
-/**
- * Method buildTransportChains
- *
- * @param transport
- */
 static axis2_status_t
-axis2_phase_resolver_build_out_transport_chains(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_transport_out_desc_t *transport);
-
+axis2_phase_resolver_build_out_transport_chains(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_transport_out_desc_t *transport);
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_engage_module_globally(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_module_desc_t *module);
+axis2_phase_resolver_engage_module_globally(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_module_desc_t *module);
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_engage_module_to_svc_from_global(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_svc_t *svc,
-                                                axis2_module_desc_t *module_desc);
-
+axis2_phase_resolver_engage_module_to_svc_from_global(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_svc_t *svc,
+    axis2_module_desc_t *module_desc);
 
 static axis2_status_t
-axis2_phase_resolver_engage_to_global_chain(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_module_desc_t *module_desc);
-
+axis2_phase_resolver_engage_to_global_chain(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_module_desc_t *module_desc);
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_engage_module_to_svc(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_svc_t *svc,
-                                                axis2_module_desc_t *module_desc);
-                                                    
+axis2_phase_resolver_engage_module_to_svc(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_svc_t *svc,
+    axis2_module_desc_t *module_desc);
+
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_engage_module_to_op(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_op_t *axis_op,
-                                                axis2_module_desc_t *module_desc);
+axis2_phase_resolver_engage_module_to_op(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_op_t *axis_op,
+    axis2_module_desc_t *module_desc);
 
 /************************** End of function prototypes ************************/
 
-AXIS2_EXTERN axis2_phase_resolver_t * AXIS2_CALL
-axis2_phase_resolver_create (const axis2_env_t *env)
+AXIS2_EXTERN axis2_phase_resolver_t *AXIS2_CALL
+axis2_phase_resolver_create(
+    const axis2_env_t *env)
 {
     axis2_phase_resolver_impl_t *phase_resolver_impl = NULL;
-    
-   AXIS2_ENV_CHECK(env, NULL);
-   
-   phase_resolver_impl = (axis2_phase_resolver_impl_t *) AXIS2_MALLOC(env->allocator,
-         sizeof(axis2_phase_resolver_impl_t));
-    
+
+    AXIS2_ENV_CHECK(env, NULL);
+
+    phase_resolver_impl = (axis2_phase_resolver_impl_t *) AXIS2_MALLOC(env->allocator,
+            sizeof(axis2_phase_resolver_impl_t));
+
     if(NULL == phase_resolver_impl)
     {
-        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE); 
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
         return NULL;
     }
-   
+
     phase_resolver_impl->phase_resolver.ops = NULL;
     phase_resolver_impl->axis2_config = NULL;
     phase_resolver_impl->svc = NULL;
     phase_resolver_impl->phase_holder = NULL;
-    
-   
-    
-   phase_resolver_impl->phase_resolver.ops = 
-      AXIS2_MALLOC (env->allocator, sizeof(axis2_phase_resolver_ops_t));
-   if(NULL == phase_resolver_impl->phase_resolver.ops)
+
+
+
+    phase_resolver_impl->phase_resolver.ops =
+        AXIS2_MALLOC (env->allocator, sizeof(axis2_phase_resolver_ops_t));
+    if(NULL == phase_resolver_impl->phase_resolver.ops)
     {
         axis2_phase_resolver_free(&(phase_resolver_impl->phase_resolver), env);
-      AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
         return NULL;
     }
-    
-    phase_resolver_impl->phase_resolver.ops->free =  
+
+    phase_resolver_impl->phase_resolver.ops->free =
         axis2_phase_resolver_free;
-   
-    phase_resolver_impl->phase_resolver.ops->build_chains = 
+
+    phase_resolver_impl->phase_resolver.ops->build_chains =
         axis2_phase_resolver_build_chains;
-    
-    phase_resolver_impl->phase_resolver.ops->build_module_op = 
+
+    phase_resolver_impl->phase_resolver.ops->build_module_op =
         axis2_phase_resolver_build_module_op;
-    
-    phase_resolver_impl->phase_resolver.ops->build_transport_chains =     
+
+    phase_resolver_impl->phase_resolver.ops->build_transport_chains =
         axis2_phase_resolver_build_transport_chains;
-    
-    phase_resolver_impl->phase_resolver.ops->engage_module_globally = 
+
+    phase_resolver_impl->phase_resolver.ops->engage_module_globally =
         axis2_phase_resolver_engage_module_globally;
-        
-    phase_resolver_impl->phase_resolver.ops->engage_module_to_svc_from_global = 
+
+    phase_resolver_impl->phase_resolver.ops->engage_module_to_svc_from_global =
         axis2_phase_resolver_engage_module_to_svc_from_global;
-        
-    phase_resolver_impl->phase_resolver.ops->engage_module_to_svc = 
+
+    phase_resolver_impl->phase_resolver.ops->engage_module_to_svc =
         axis2_phase_resolver_engage_module_to_svc;
-        
-    phase_resolver_impl->phase_resolver.ops->engage_module_to_op = 
+
+    phase_resolver_impl->phase_resolver.ops->engage_module_to_op =
         axis2_phase_resolver_engage_module_to_op;
-    
-  
-   return &(phase_resolver_impl->phase_resolver);
+
+
+    return &(phase_resolver_impl->phase_resolver);
 }
 
-AXIS2_EXTERN axis2_phase_resolver_t * AXIS2_CALL 
-axis2_phase_resolver_create_with_config (const axis2_env_t *env, 
-                                         axis2_conf_t *axis2_config)
+AXIS2_EXTERN axis2_phase_resolver_t *AXIS2_CALL
+axis2_phase_resolver_create_with_config(
+    const axis2_env_t *env,
+    axis2_conf_t *axis2_config)
 {
     axis2_phase_resolver_impl_t *phase_resolver_impl = NULL;
-    
+
     AXIS2_ENV_CHECK(env, NULL);
     AXIS2_PARAM_CHECK(env->error, axis2_config, NULL);
-    
+
     phase_resolver_impl = (axis2_phase_resolver_impl_t *)
-        axis2_phase_resolver_create(env);
-    
+            axis2_phase_resolver_create(env);
+
     phase_resolver_impl->axis2_config = axis2_config;
-    
+
     return &(phase_resolver_impl->phase_resolver);
 }
 
-AXIS2_EXTERN axis2_phase_resolver_t * AXIS2_CALL
-axis2_phase_resolver_create_with_config_and_svc (const axis2_env_t *env, 
-                                                axis2_conf_t *axis2_config,
-                                                axis2_svc_t *svc)
+AXIS2_EXTERN axis2_phase_resolver_t *AXIS2_CALL
+axis2_phase_resolver_create_with_config_and_svc(
+    const axis2_env_t *env,
+    axis2_conf_t *axis2_config,
+    axis2_svc_t *svc)
 {
     axis2_phase_resolver_impl_t *phase_resolver_impl = NULL;
-    
+
     AXIS2_ENV_CHECK(env, NULL);
     AXIS2_PARAM_CHECK(env->error, axis2_config, NULL);
-    
+
     phase_resolver_impl = (axis2_phase_resolver_impl_t *)
-        axis2_phase_resolver_create(env);
-    
+            axis2_phase_resolver_create(env);
+
     if(!phase_resolver_impl)
     {
         return NULL;
     }
     phase_resolver_impl->axis2_config = axis2_config;
-    
+
     phase_resolver_impl->svc = svc;
-    
+
     return &(phase_resolver_impl->phase_resolver);
 }
 
 /***************************Function implementation****************************/
 
-axis2_status_t AXIS2_CALL 
-axis2_phase_resolver_free (axis2_phase_resolver_t *phase_resolver, 
-                            const axis2_env_t *env)
+axis2_status_t AXIS2_CALL
+axis2_phase_resolver_free(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env)
 {
     axis2_phase_resolver_impl_t *phase_resolver_impl = NULL;
-    
+
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
-    
+
     phase_resolver_impl = AXIS2_INTF_TO_IMPL(phase_resolver);
-     
+
     phase_resolver_impl->axis2_config = NULL;
-    
+
     phase_resolver_impl->svc = NULL;
-    
+
     if(phase_resolver_impl->phase_holder)
     {
         AXIS2_PHASE_HOLDER_FREE(phase_resolver_impl->phase_holder, env);
         phase_resolver_impl->phase_holder = NULL;
     }
-   
+
     if(phase_resolver->ops)
     {
         AXIS2_FREE(env->allocator, phase_resolver->ops);
@@ -271,29 +277,30 @@
         AXIS2_FREE(env->allocator, phase_resolver_impl);
         phase_resolver_impl = NULL;
     }
-    
-   return AXIS2_SUCCESS;
+
+    return AXIS2_SUCCESS;
 }
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_build_chains(axis2_phase_resolver_t *phase_resolver,
-                                    const axis2_env_t *env) 
+axis2_phase_resolver_build_chains(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env)
 {
     axis2_phase_resolver_impl_t *resolver_impl = NULL;
     axis2_hash_index_t *index_i = 0;
     axis2_status_t status = AXIS2_FAILURE;
     axis2_op_t *op = NULL;
     axis2_hash_t *ops = NULL;
-    
+
     resolver_impl = AXIS2_INTF_TO_IMPL(phase_resolver);
-   
+
     if (!(resolver_impl->svc))
         return AXIS2_FAILURE;
 
     ops = AXIS2_SVC_GET_OPS(resolver_impl->svc, env);
-    
-    for (index_i = axis2_hash_first (ops, env); index_i; index_i = 
-            axis2_hash_next (env, index_i))
+
+    for (index_i = axis2_hash_first (ops, env); index_i; index_i =
+                axis2_hash_next (env, index_i))
     {
         void *v = NULL;
         int j = 0;
@@ -302,38 +309,39 @@
         for(j = 1; j < 5; j++)
         {
             status = axis2_phase_resolver_build_execution_chains(phase_resolver,
-                env, j, op );
+                    env, j, op );
         }
     }
 
-    return status;    
+    return status;
 }
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_build_module_op(axis2_phase_resolver_t *phase_resolver,
-                                    const axis2_env_t *env,
-                                    axis2_op_t *op)
+axis2_phase_resolver_build_module_op(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_op_t *op)
 {
     int i = 0;
     axis2_status_t status = AXIS2_FAILURE;
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     AXIS2_PARAM_CHECK(env->error, op, AXIS2_FAILURE);
-    
-   
-    for (i = 1; i < 5; i++) 
+
+
+    for (i = 1; i < 5; i++)
     {
-        status = axis2_phase_resolver_build_execution_chains(phase_resolver, env, 
-                    i, op);
+        status = axis2_phase_resolver_build_execution_chains(phase_resolver, env,
+                i, op);
     }
     return status;
 }
 
 static axis2_status_t
 axis2_phase_resolver_build_execution_chains(
-        axis2_phase_resolver_t *phase_resolver,
-        const axis2_env_t *env,
-        int type,
-        axis2_op_t *op)
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    int type,
+    axis2_op_t *op)
 {
     axis2_phase_resolver_impl_t *resolver_impl = NULL;
     axis2_array_list_t *all_handlers = NULL;
@@ -343,78 +351,79 @@
     int status = AXIS2_FAILURE;
     axis2_flow_t *flow = NULL;
     axis2_property_t *property = NULL;
-    
+
     resolver_impl = AXIS2_INTF_TO_IMPL(phase_resolver);
-    
+
     /**************************************************************************/
     /********************* Handlers from   axis2.xml from modules *************/
     /**************************************************************************/
-    
+
     moduleqnames = AXIS2_CONF_GET_ALL_ENGAGED_MODULES(
-        resolver_impl->axis2_config, env);
-    
+                resolver_impl->axis2_config, env);
+
     size = AXIS2_ARRAY_LIST_SIZE(moduleqnames, env);
     status = AXIS2_ERROR_GET_STATUS_CODE(env->error);
     if(AXIS2_SUCCESS != status)
     {
         return status;
     }
-    
-    for (i = 0; i < size; i++) 
+
+    for (i = 0; i < size; i++)
     {
         axis2_qname_t *modulename = NULL;
         axis2_module_desc_t *module_desc = NULL;
-            
-        modulename = (axis2_qname_t *) AXIS2_ARRAY_LIST_GET(moduleqnames, env, 
-            i);
-        module_desc = AXIS2_CONF_GET_MODULE(resolver_impl->axis2_config, env, 
-            modulename);
-        if (NULL != module_desc) 
+
+        modulename = (axis2_qname_t *) AXIS2_ARRAY_LIST_GET(moduleqnames, env,
+                i);
+        module_desc = AXIS2_CONF_GET_MODULE(resolver_impl->axis2_config, env,
+                modulename);
+        if (NULL != module_desc)
         {
-            switch (type) 
+            switch (type)
             {
-                case AXIS2_IN_FLOW:
-                {
-                    flow = AXIS2_MODULE_DESC_GET_IN_FLOW(module_desc, env);
-                    break;
-                }
-                case AXIS2_OUT_FLOW:
-                {
-                    flow = AXIS2_MODULE_DESC_GET_OUT_FLOW(module_desc, env);
-                    break;
-                }
-                case AXIS2_FAULT_IN_FLOW:
-                {
-                    flow = AXIS2_MODULE_DESC_GET_FAULT_IN_FLOW(module_desc, env);
-                    break;
-                }
-                case AXIS2_FAULT_OUT_FLOW:
-                {
-                    flow = AXIS2_MODULE_DESC_GET_FAULT_OUT_FLOW(module_desc, env);
-                    break;
-                }
+            case AXIS2_IN_FLOW:
+            {
+                flow = AXIS2_MODULE_DESC_GET_IN_FLOW(module_desc, env);
+                break;
+            }
+            case AXIS2_OUT_FLOW:
+            {
+                flow = AXIS2_MODULE_DESC_GET_OUT_FLOW(module_desc, env);
+                break;
+            }
+            case AXIS2_FAULT_IN_FLOW:
+            {
+                flow = AXIS2_MODULE_DESC_GET_FAULT_IN_FLOW(module_desc, env);
+                break;
+            }
+            case AXIS2_FAULT_OUT_FLOW:
+            {
+                flow = AXIS2_MODULE_DESC_GET_FAULT_OUT_FLOW(module_desc, env);
+                break;
             }
-            status = AXIS2_SVC_ADD_TO_ENGAGED_MODULE_LIST(resolver_impl->svc, 
-                env, module_desc);
-            if(AXIS2_SUCCESS != status) 
+            }
+            status = AXIS2_SVC_ADD_TO_ENGAGED_MODULE_LIST(resolver_impl->svc,
+                    env, module_desc);
+            if(AXIS2_SUCCESS != status)
             {
                 return status;
             }
             status = AXIS2_OP_ADD_TO_ENGAGE_MODULE_LIST(op, env, module_desc);
-            if(AXIS2_SUCCESS != status) 
+            if(AXIS2_SUCCESS != status)
             {
                 return status;
             }
-            
-        } else 
+
+        }
+        else
         {
-                
-            AXIS2_ERROR_SET(env->error, AXIS2_ERROR_INVALID_MODULE_REF, 
-                AXIS2_FAILURE);
+
+            AXIS2_ERROR_SET(env->error, AXIS2_ERROR_INVALID_MODULE_REF,
+                    AXIS2_FAILURE);
             return AXIS2_FAILURE;
         }
 
-        if (NULL != flow) 
+        if (NULL != flow)
         {
             int j = 0;
             int count = 0;
@@ -423,19 +432,19 @@
             {
                 return AXIS2_ERROR_GET_STATUS_CODE(env->error);
             }
-           
-            
+
+
             /*if(!all_handlers)
             {
                 return AXIS2_FAILURE;
             }*/
 
-            for (j = 0; j < count; j++) 
+            for (j = 0; j < count; j++)
             {
                 axis2_handler_desc_t *metadata = NULL;
                 axis2_char_t *phase_name = NULL;
                 axis2_phase_rule_t *phase_rule = NULL;
-                    
+
                 metadata = AXIS2_FLOW_GET_HANDLER(flow, env, j);
                 phase_rule = AXIS2_HANDLER_DESC_GET_RULES(metadata, env);
                 phase_name = AXIS2_PHASE_RULE_GET_NAME(phase_rule, env);
@@ -444,10 +453,10 @@
                     return AXIS2_FAILURE;
                 }
                 if ((0 != AXIS2_STRCMP(AXIS2_PHASE_TRANSPORTIN, phase_name)) &&
-                    (0 != AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) &&
-                    (0 != AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) &&
-                    (0 != AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
-                { 
+                        (0 != AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) &&
+                        (0 != AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) &&
+                        (0 != AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
+                {
                     if(!all_handlers)
                     {
                         all_handlers = axis2_array_list_create(env, 0);
@@ -456,124 +465,126 @@
                     }
                     status = AXIS2_ARRAY_LIST_ADD(all_handlers, env, metadata);
                     if(AXIS2_SUCCESS != status)
-                    {   
+                    {
                         if(all_handlers)
-                        {  
+                        {
                             AXIS2_ARRAY_LIST_FREE(all_handlers, env);
-                            all_handlers = NULL;                        
-                        }                        
+                            all_handlers = NULL;
+                        }
                         return status;
                     }
-                } else 
+                }
+                else
                 {
                     AXIS2_LOG_DEBUG(env->log, AXIS2_LOG_SI, "This handler is\
-                        trying to added to system pre defined phases , but those\
-                        handlers are already added to global chain which run\
-                        irrespective of the service");
+                            trying to added to system pre defined phases , but those\
+                            handlers are already added to global chain which run\
+                            irrespective of the service");
                 }
             }
         }
 
     }
 
-    
+
     /**************************************************************************/
     /************************** SERVICE HANDLERS ******************************/
     /**************************************************************************/
-    flow = NULL; 
-    switch (type) 
+    flow = NULL;
+    switch (type)
     {
-            
-        case AXIS2_IN_FLOW:
-        {
-            
-            property = (axis2_property_t *) 
+
+    case AXIS2_IN_FLOW:
+    {
+
+        property = (axis2_property_t *)
                 AXIS2_WSDL_COMPONENT_GET_COMPONENT_PROPERTY(resolver_impl->
-                svc->wsdl_svc->wsdl_component, env, AXIS2_IN_FLOW_KEY);
-            if(property)
-                flow = (axis2_flow_t *) AXIS2_PROPERTY_GET_VALUE(property, env);
-            break;
-        }
-        case AXIS2_OUT_FLOW:
-        {
-            property = (axis2_property_t *) 
+                        svc->wsdl_svc->wsdl_component, env, AXIS2_IN_FLOW_KEY);
+        if(property)
+            flow = (axis2_flow_t *) AXIS2_PROPERTY_GET_VALUE(property, env);
+        break;
+    }
+    case AXIS2_OUT_FLOW:
+    {
+        property = (axis2_property_t *)
                 AXIS2_WSDL_COMPONENT_GET_COMPONENT_PROPERTY(resolver_impl->
-                svc->wsdl_svc->wsdl_component, env, AXIS2_OUT_FLOW_KEY);
-            if(property)
-                flow = (axis2_flow_t *) AXIS2_PROPERTY_GET_VALUE(property, env);
-            break;
-        }
-        case AXIS2_FAULT_IN_FLOW:
-        {
-            property = (axis2_property_t *) 
+                        svc->wsdl_svc->wsdl_component, env, AXIS2_OUT_FLOW_KEY);
+        if(property)
+            flow = (axis2_flow_t *) AXIS2_PROPERTY_GET_VALUE(property, env);
+        break;
+    }
+    case AXIS2_FAULT_IN_FLOW:
+    {
+        property = (axis2_property_t *)
                 AXIS2_WSDL_COMPONENT_GET_COMPONENT_PROPERTY(resolver_impl->
-                svc->wsdl_svc->wsdl_component, env, AXIS2_IN_FAULTFLOW_KEY);
-            if(property)
-                flow = (axis2_flow_t *) AXIS2_PROPERTY_GET_VALUE(property, env);
-            break;
-        }
-        case AXIS2_FAULT_OUT_FLOW:
-        {
-            property = (axis2_property_t *) 
+                        svc->wsdl_svc->wsdl_component, env, AXIS2_IN_FAULTFLOW_KEY);
+        if(property)
+            flow = (axis2_flow_t *) AXIS2_PROPERTY_GET_VALUE(property, env);
+        break;
+    }
+    case AXIS2_FAULT_OUT_FLOW:
+    {
+        property = (axis2_property_t *)
                 AXIS2_WSDL_COMPONENT_GET_COMPONENT_PROPERTY(resolver_impl->
-                svc->wsdl_svc->wsdl_component, env, AXIS2_OUT_FAULTFLOW_KEY);
-            if(property)
-                flow = (axis2_flow_t *) AXIS2_PROPERTY_GET_VALUE(property, env);
-            break;
-        }
+                        svc->wsdl_svc->wsdl_component, env, AXIS2_OUT_FAULTFLOW_KEY);
+        if(property)
+            flow = (axis2_flow_t *) AXIS2_PROPERTY_GET_VALUE(property, env);
+        break;
     }
-    
-    if (NULL != flow) 
+    }
+
+    if (NULL != flow)
     {
         int j = 0;
         int count = 0;
         count = AXIS2_FLOW_GET_HANDLER_COUNT(flow, env);
-        
+
         if(AXIS2_SUCCESS != AXIS2_ERROR_GET_STATUS_CODE(env->error))
         {
             if(all_handlers)
-            {  
+            {
                 AXIS2_ARRAY_LIST_FREE(all_handlers, env);
-                all_handlers = NULL;                        
-            }                        
-            return AXIS2_ERROR_GET_STATUS_CODE(env->error);              
+                all_handlers = NULL;
+            }
+            return AXIS2_ERROR_GET_STATUS_CODE(env->error);
         }
-        for (j = 0; j < count; j++) 
+        for (j = 0; j < count; j++)
         {
             axis2_handler_desc_t *metadata = NULL;
             axis2_char_t *phase_name = NULL;
             axis2_phase_rule_t *phase_rule = NULL;
-                
+
             metadata = AXIS2_FLOW_GET_HANDLER(flow, env, j);
             phase_rule = AXIS2_HANDLER_DESC_GET_RULES(metadata, env);
             if(phase_rule)
             {
                 phase_name = AXIS2_PHASE_RULE_GET_NAME(phase_rule, env);
             }
-            
+
             /* TODO change this in properway */
             if(!phase_name || (0 == AXIS2_STRCMP(phase_name, "")))
             {
                 AXIS2_ERROR_SET(env->error, AXIS2_ERROR_PHASE_IS_NOT_SPECIFED,
-                    AXIS2_FAILURE);
+                        AXIS2_FAILURE);
                 return AXIS2_FAILURE;
-                
-            } 
+
+            }
             else if ((0 == AXIS2_STRCMP(AXIS2_PHASE_TRANSPORTIN, phase_name)) ||
-                (0 == AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) ||
-                (0 == AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) ||
-                (0 == AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
+                    (0 == AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) ||
+                    (0 == AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) ||
+                    (0 == AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
             {
                 if(all_handlers)
-                {  
+                {
                     AXIS2_ARRAY_LIST_FREE(all_handlers, env);
-                    all_handlers = NULL;                        
+                    all_handlers = NULL;
                 }
-                AXIS2_ERROR_SET(env->error, 
-                    AXIS2_ERROR_SERVICE_MODULE_CAN_NOT_REFER_GLOBAL_PHASE, AXIS2_FAILURE);
+                AXIS2_ERROR_SET(env->error,
+                        AXIS2_ERROR_SERVICE_MODULE_CAN_NOT_REFER_GLOBAL_PHASE, AXIS2_FAILURE);
                 return AXIS2_FAILURE;
-                
-            } else 
+
+            }
+            else
             {
                 if(!all_handlers)
                 {
@@ -583,11 +594,11 @@
                 }
 
                 status = AXIS2_ARRAY_LIST_ADD(all_handlers, env, metadata);
-                
-                if(AXIS2_SUCCESS != status) 
+
+                if(AXIS2_SUCCESS != status)
                 {
                     if(all_handlers)
-                    { 
+                    {
                         int size = 0;
                         int i = 0;
                         size = AXIS2_ARRAY_LIST_SIZE(all_handlers, env);
@@ -595,68 +606,68 @@
                         {
                             axis2_handler_desc_t *handler_desc = NULL;
 
-                            handler_desc = AXIS2_ARRAY_LIST_GET(all_handlers, 
-                                env, i);
+                            handler_desc = AXIS2_ARRAY_LIST_GET(all_handlers,
+                                    env, i);
                             AXIS2_HANDLER_DESC_FREE(handler_desc, env);
                         }
                         AXIS2_ARRAY_LIST_FREE(all_handlers, env);
-                        all_handlers = NULL;                        
+                        all_handlers = NULL;
                     }
                     return status;
                 }
             }
         }
     }
-    
+
     else if (!all_handlers)
     {
         /* no flows configured */
         return AXIS2_SUCCESS;
     }
-    
+
     if(resolver_impl->phase_holder)
     {
         AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
     }
-    
-    switch (type) 
+
+    switch (type)
     {
-        case AXIS2_IN_FLOW:
-        {
-            axis2_array_list_t *phase_list = NULL;
+    case AXIS2_IN_FLOW:
+    {
+        axis2_array_list_t *phase_list = NULL;
 
-            phase_list = AXIS2_OP_GET_REMAINING_PHASES_IN_FLOW(op, env);
-            resolver_impl->phase_holder = 
-                axis2_phase_holder_create_with_phases(env, phase_list);
-            break;
-        }
-        case AXIS2_OUT_FLOW:
-        {
-            axis2_array_list_t *phase_list = NULL;
-            
-            phase_list = AXIS2_OP_GET_PHASES_OUT_FLOW(op, env);
-            resolver_impl->phase_holder = 
-                axis2_phase_holder_create_with_phases(env, phase_list);
-            break;
-        }
-        case AXIS2_FAULT_IN_FLOW:
-        {
-            axis2_array_list_t *phase_list = NULL;
-            
-            phase_list = AXIS2_OP_GET_PHASES_IN_FAULT_FLOW(op, env);
-            resolver_impl->phase_holder = 
-                axis2_phase_holder_create_with_phases(env, phase_list);
-            break;
-        }
-        case AXIS2_FAULT_OUT_FLOW:
-        {
-            axis2_array_list_t *phase_list = NULL;
-            
-            phase_list = AXIS2_OP_GET_PHASES_OUT_FAULT_FLOW(op, env);
-            resolver_impl->phase_holder = 
-                axis2_phase_holder_create_with_phases(env, phase_list);
-            break;
-        }
+        phase_list = AXIS2_OP_GET_REMAINING_PHASES_IN_FLOW(op, env);
+        resolver_impl->phase_holder =
+            axis2_phase_holder_create_with_phases(env, phase_list);
+        break;
+    }
+    case AXIS2_OUT_FLOW:
+    {
+        axis2_array_list_t *phase_list = NULL;
+
+        phase_list = AXIS2_OP_GET_PHASES_OUT_FLOW(op, env);
+        resolver_impl->phase_holder =
+            axis2_phase_holder_create_with_phases(env, phase_list);
+        break;
+    }
+    case AXIS2_FAULT_IN_FLOW:
+    {
+        axis2_array_list_t *phase_list = NULL;
+
+        phase_list = AXIS2_OP_GET_PHASES_IN_FAULT_FLOW(op, env);
+        resolver_impl->phase_holder =
+            axis2_phase_holder_create_with_phases(env, phase_list);
+        break;
+    }
+    case AXIS2_FAULT_OUT_FLOW:
+    {
+        axis2_array_list_t *phase_list = NULL;
+
+        phase_list = AXIS2_OP_GET_PHASES_OUT_FAULT_FLOW(op, env);
+        resolver_impl->phase_holder =
+            axis2_phase_holder_create_with_phases(env, phase_list);
+        break;
+    }
     }
     /* TODO There is no point of having this code. If no flows, it should
      * not come here. It should have returned when flows are null
@@ -665,36 +676,37 @@
         return AXIS2_SUCCESS;
     }
     */
-    
+
     size = AXIS2_ARRAY_LIST_SIZE(all_handlers, env);
     if(AXIS2_SUCCESS != AXIS2_ERROR_GET_STATUS_CODE(env->error))
     {
         return AXIS2_ERROR_GET_STATUS_CODE(env->error);
     }
-    
-    for (i = 0; i < size; i++) 
+
+    for (i = 0; i < size; i++)
     {
         axis2_handler_desc_t *metadata = NULL;
-            
+
         metadata = (axis2_handler_desc_t *)
-            AXIS2_ARRAY_LIST_GET(all_handlers, env, i);
+                AXIS2_ARRAY_LIST_GET(all_handlers, env, i);
         if (resolver_impl->phase_holder)
         {
-            status = AXIS2_PHASE_HOLDER_ADD_HANDLER(resolver_impl->phase_holder, 
-                env, metadata);
+            status = AXIS2_PHASE_HOLDER_ADD_HANDLER(resolver_impl->phase_holder,
+                    env, metadata);
         }
     }
-    
+
     /* Free the locally created all_handlers list */
     if(all_handlers)
         AXIS2_ARRAY_LIST_FREE(all_handlers, env);
-    
+
     return status;
 }
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_build_transport_chains(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env)
+axis2_phase_resolver_build_transport_chains(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env)
 {
     axis2_phase_resolver_impl_t *resolver_impl = NULL;
     axis2_hash_t *transports_in = NULL;
@@ -704,50 +716,50 @@
     axis2_transport_out_desc_t *transport_out = NULL;
     void *v = NULL;
     axis2_status_t status = AXIS2_FAILURE;
-   
+
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     resolver_impl = AXIS2_INTF_TO_IMPL(phase_resolver);
-    
-    transports_in = AXIS2_CONF_GET_ALL_IN_TRANSPORTS(resolver_impl->axis2_config, 
-        env);
+
+    transports_in = AXIS2_CONF_GET_ALL_IN_TRANSPORTS(resolver_impl->axis2_config,
+            env);
     if(!transports_in)
     {
-        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_TRANSPORT_IN_CONFIGURED, 
-            AXIS2_FAILURE);
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_TRANSPORT_IN_CONFIGURED,
+                AXIS2_FAILURE);
         return AXIS2_SUCCESS;
     }
-    
-    transports_out = AXIS2_CONF_GET_ALL_OUT_TRANSPORTS(resolver_impl->axis2_config, 
-        env);
+
+    transports_out = AXIS2_CONF_GET_ALL_OUT_TRANSPORTS(resolver_impl->axis2_config,
+            env);
     if(!transports_out)
     {
-        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_TRANSPORT_OUT_CONFIGURED, 
-            AXIS2_FAILURE);
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_TRANSPORT_OUT_CONFIGURED,
+                AXIS2_FAILURE);
         return AXIS2_SUCCESS;
     }
-    
-    for (index_i = axis2_hash_first (transports_in, env); index_i; index_i = 
-        axis2_hash_next (env, index_i))
+
+    for (index_i = axis2_hash_first (transports_in, env); index_i; index_i =
+                axis2_hash_next (env, index_i))
     {
 
         axis2_hash_this (index_i, NULL, NULL, &v);
         transport_in = (axis2_transport_in_desc_t *) v;
-        status = axis2_phase_resolver_build_in_transport_chains(phase_resolver, 
-            env, transport_in);
+        status = axis2_phase_resolver_build_in_transport_chains(phase_resolver,
+                env, transport_in);
         if(AXIS2_SUCCESS != status)
         {
             return status;
         }
     }
-    
-    for (index_i = axis2_hash_first (transports_out, env); index_i; index_i = 
-        axis2_hash_next (env, index_i))
+
+    for (index_i = axis2_hash_first (transports_out, env); index_i; index_i =
+                axis2_hash_next (env, index_i))
     {
 
         axis2_hash_this (index_i, NULL, NULL, &v);
         transport_out = (axis2_transport_out_desc_t *) v;
-        status = axis2_phase_resolver_build_out_transport_chains(phase_resolver, 
-            env, transport_out);
+        status = axis2_phase_resolver_build_out_transport_chains(phase_resolver,
+                env, transport_out);
         if(AXIS2_SUCCESS != status)
         {
             return status;
@@ -763,59 +775,59 @@
 
 
 static axis2_status_t
-axis2_phase_resolver_build_in_transport_chains(axis2_phase_resolver_t *
-                                                    phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_transport_in_desc_t *
-                                                    transport)
+axis2_phase_resolver_build_in_transport_chains(
+    axis2_phase_resolver_t *
+    phase_resolver,
+    const axis2_env_t *env,
+    axis2_transport_in_desc_t *transport)
 {
     int type = 0;
     int j = 0;
     axis2_status_t status = AXIS2_FAILURE;
     axis2_array_list_t *handlers = NULL;
-   
+
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     AXIS2_PARAM_CHECK(env->error, transport, AXIS2_FAILURE);
 
-    for (type = 1; type < 4; type++) 
+    for (type = 1; type < 4; type++)
     {
         axis2_flow_t *flow = NULL;
         axis2_phase_t *phase = NULL;
 
-        switch (type) 
+        switch (type)
         {
-            case AXIS2_IN_FLOW:
-            {
-                flow = AXIS2_TRANSPORT_IN_DESC_GET_IN_FLOW(transport, env);
-                phase = AXIS2_TRANSPORT_IN_DESC_GET_IN_PHASE(transport, env);
-                break;
-            }
-            case AXIS2_FAULT_IN_FLOW:
-            {
-                flow = AXIS2_TRANSPORT_IN_DESC_GET_FAULTFLOW(transport, env);
-                phase = AXIS2_TRANSPORT_IN_DESC_GET_FAULTPHASE(transport, env);
-                break;
-            }
+        case AXIS2_IN_FLOW:
+        {
+            flow = AXIS2_TRANSPORT_IN_DESC_GET_IN_FLOW(transport, env);
+            phase = AXIS2_TRANSPORT_IN_DESC_GET_IN_PHASE(transport, env);
+            break;
         }
-        if (NULL != flow) 
+        case AXIS2_FAULT_IN_FLOW:
+        {
+            flow = AXIS2_TRANSPORT_IN_DESC_GET_FAULTFLOW(transport, env);
+            phase = AXIS2_TRANSPORT_IN_DESC_GET_FAULTPHASE(transport, env);
+            break;
+        }
+        }
+        if (NULL != flow)
         {
             axis2_phase_holder_t *phase_holder = NULL;
             int size = 0;
 
             size = AXIS2_FLOW_GET_HANDLER_COUNT(flow, env);
             handlers = axis2_array_list_create(env, 0);
-            for (j = 0; j < size; j++) 
+            for (j = 0; j < size; j++)
             {
                 axis2_handler_desc_t *metadata = NULL;
                 axis2_phase_rule_t *rule = NULL;
-                
+
                 metadata = AXIS2_FLOW_GET_HANDLER(flow, env, j);
                 rule = AXIS2_HANDLER_DESC_GET_RULES(metadata, env);
                 if(rule)
                 {
-                    status = AXIS2_PHASE_RULE_SET_NAME(rule, env, 
-                        AXIS2_TRANSPORT_PHASE);
-                } 
+                    status = AXIS2_PHASE_RULE_SET_NAME(rule, env,
+                            AXIS2_TRANSPORT_PHASE);
+                }
                 if(AXIS2_SUCCESS != status)
                 {
                     if(handlers)
@@ -871,18 +883,19 @@
                     }
                     AXIS2_ARRAY_LIST_FREE(handlers, env);
                 }
-                AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, 
+                AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY,
                         AXIS2_FAILURE);
                 return AXIS2_FAILURE;
             }
-            
+
             status = AXIS2_PHASE_HOLDER_BUILD_TRANSPORT_HANDLER_CHAIN(
-                phase_holder, env, phase, handlers);
+                        phase_holder, env, phase, handlers);
             if(phase_holder)
             {
                 AXIS2_PHASE_HOLDER_FREE(phase_holder, env);
             }
-        } else 
+        }
+        else
         {
             /* Do nothing */
         }
@@ -895,37 +908,39 @@
 }
 
 static axis2_status_t
-axis2_phase_resolver_build_out_transport_chains(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_transport_out_desc_t *transport)
+axis2_phase_resolver_build_out_transport_chains(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_transport_out_desc_t *transport)
 {
     int type = 0;
     axis2_status_t status = AXIS2_FAILURE;
     axis2_array_list_t *handlers = NULL;
-       
+
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     AXIS2_PARAM_CHECK(env->error, transport, AXIS2_FAILURE);
-    for (type = 1; type < 5; type++) 
+    for (type = 1; type < 5; type++)
     {
         axis2_flow_t *flow = NULL;
         axis2_phase_t *phase = NULL;
-        
-        switch (type) {
-            case AXIS2_OUT_FLOW:
-            {
-                flow = AXIS2_TRANSPORT_OUT_DESC_GET_OUT_FLOW(transport, env);
-                phase = AXIS2_TRANSPORT_OUT_DESC_GET_OUT_PHASE(transport, env);
-                break;
-            }
-            case AXIS2_FAULT_OUT_FLOW:
-            {
-                flow = AXIS2_TRANSPORT_OUT_DESC_GET_FAULTFLOW(transport, env);
-                phase = AXIS2_TRANSPORT_OUT_DESC_GET_FAULTPHASE(transport, env);
-                break;
-            }
+
+        switch (type)
+        {
+        case AXIS2_OUT_FLOW:
+        {
+            flow = AXIS2_TRANSPORT_OUT_DESC_GET_OUT_FLOW(transport, env);
+            phase = AXIS2_TRANSPORT_OUT_DESC_GET_OUT_PHASE(transport, env);
+            break;
         }
-        
-        if (NULL != flow) 
+        case AXIS2_FAULT_OUT_FLOW:
+        {
+            flow = AXIS2_TRANSPORT_OUT_DESC_GET_FAULTFLOW(transport, env);
+            phase = AXIS2_TRANSPORT_OUT_DESC_GET_FAULTPHASE(transport, env);
+            break;
+        }
+        }
+
+        if (NULL != flow)
         {
             axis2_phase_holder_t *phase_holder = NULL;
             int hndlr_count = 0;
@@ -936,20 +951,20 @@
                 return AXIS2_ERROR_GET_STATUS_CODE(env->error);
             }
             handlers = axis2_array_list_create(env, 0);
-            
-            for (j = 0; j < hndlr_count; j++) 
+
+            for (j = 0; j < hndlr_count; j++)
             {
                 axis2_handler_desc_t *metadata = NULL;
                 axis2_phase_rule_t *rule = NULL;
 
                 metadata = AXIS2_FLOW_GET_HANDLER(flow, env, j);
-                
+
 
                 rule = AXIS2_HANDLER_DESC_GET_RULES(metadata, env);
                 if(rule)
                 {
-                    status = AXIS2_PHASE_RULE_SET_NAME(rule, env, 
-                        AXIS2_TRANSPORT_PHASE);
+                    status = AXIS2_PHASE_RULE_SET_NAME(rule, env,
+                            AXIS2_TRANSPORT_PHASE);
                 }
                 if(AXIS2_SUCCESS != status)
                 {
@@ -966,10 +981,10 @@
                             AXIS2_HANDLER_DESC_FREE(handler_d, env);
                         }
                         AXIS2_ARRAY_LIST_FREE(handlers, env);
-                    }   
+                    }
                     return status;
                 }
-                
+
                 status = AXIS2_ARRAY_LIST_ADD(handlers, env, metadata);
                 if(AXIS2_FAILURE == status)
                 {
@@ -1010,12 +1025,13 @@
                 AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
                 return AXIS2_FAILURE;
             }
-            
+
             status = AXIS2_PHASE_HOLDER_BUILD_TRANSPORT_HANDLER_CHAIN(
-                phase_holder, env, phase, handlers);
+                        phase_holder, env, phase, handlers);
             if(phase_holder)
                 AXIS2_PHASE_HOLDER_FREE(phase_holder, env);
-        } else 
+        }
+        else
         {
             /* Do nothing */
         }
@@ -1025,23 +1041,23 @@
     return status;
 }
 
-
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_engage_module_globally(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_module_desc_t *module_desc)
+axis2_phase_resolver_engage_module_globally(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_module_desc_t *module_desc)
 {
     axis2_phase_resolver_impl_t *resolver_impl = NULL;
     axis2_hash_t *svc_grps = NULL;
     axis2_hash_index_t *index_i = NULL;
     axis2_status_t status = AXIS2_FAILURE;
-    
+
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     AXIS2_PARAM_CHECK(env->error, module_desc, AXIS2_FAILURE);
     resolver_impl = AXIS2_INTF_TO_IMPL(phase_resolver);
-    
-    status = axis2_phase_resolver_engage_to_global_chain(phase_resolver, env, 
-        module_desc);
+
+    status = axis2_phase_resolver_engage_to_global_chain(phase_resolver, env,
+            module_desc);
     if(AXIS2_SUCCESS != status)
     {
         return status;
@@ -1051,42 +1067,42 @@
     {
         return AXIS2_FAILURE;
     }
-    for(index_i = axis2_hash_first (svc_grps, env); index_i; index_i = 
-        axis2_hash_next (env, index_i))
+    for(index_i = axis2_hash_first (svc_grps, env); index_i; index_i =
+                axis2_hash_next (env, index_i))
     {
         axis2_hash_t *svcs = NULL;
         axis2_svc_grp_t *svc_grp = NULL;
         void *v = NULL;
         axis2_hash_index_t *index_j = NULL;
-        const axis2_qname_t *mod_name = NULL; 
+        const axis2_qname_t *mod_name = NULL;
 
         axis2_hash_this (index_i, NULL, NULL, &v);
         svc_grp = (axis2_svc_grp_t *) v;
-        svcs = AXIS2_SVC_GRP_GET_SVCS(svc_grp, env);    
-        
-        for(index_j = axis2_hash_first (svcs, env); index_j; index_j = 
-            axis2_hash_next (env, index_j))
+        svcs = AXIS2_SVC_GRP_GET_SVCS(svc_grp, env);
+
+        for(index_j = axis2_hash_first (svcs, env); index_j; index_j =
+                    axis2_hash_next (env, index_j))
         {
             axis2_svc_t *svc = NULL;
             void *w = NULL;
 
             axis2_hash_this (index_j, NULL, NULL, &w);
             svc = (axis2_svc_t *) w;
-                
-            status = AXIS2_SVC_ADD_MODULE_OPS(svc, env, module_desc, 
-                resolver_impl->axis2_config);
+
+            status = AXIS2_SVC_ADD_MODULE_OPS(svc, env, module_desc,
+                    resolver_impl->axis2_config);
             if(AXIS2_SUCCESS != status)
             {
                 return status;
             }
             status = axis2_phase_resolver_engage_module_to_svc_from_global(
-                phase_resolver, env, svc, module_desc);
-            
+                        phase_resolver, env, svc, module_desc);
+
             if(AXIS2_SUCCESS != status)
             {
                 return status;
             }
-            
+
             status = AXIS2_SVC_ADD_TO_ENGAGED_MODULE_LIST(svc, env, module_desc);
             if(AXIS2_SUCCESS != status)
             {
@@ -1094,9 +1110,9 @@
             }
         }
         mod_name = AXIS2_MODULE_DESC_GET_QNAME(module_desc, env);
-        status = AXIS2_SVC_GRP_ADD_MODULE(svc_grp, env, 
-            mod_name);
-        
+        status = AXIS2_SVC_GRP_ADD_MODULE(svc_grp, env,
+                mod_name);
+
         if(AXIS2_SUCCESS != status)
         {
             return status;
@@ -1106,10 +1122,11 @@
 }
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_engage_module_to_svc_from_global(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_svc_t *svc,
-                                                axis2_module_desc_t *module_desc)
+axis2_phase_resolver_engage_module_to_svc_from_global(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_svc_t *svc,
+    axis2_module_desc_t *module_desc)
 {
     axis2_phase_resolver_impl_t *resolver_impl = NULL;
     axis2_hash_t *ops = NULL;
@@ -1117,20 +1134,20 @@
     axis2_hash_index_t *index_i = NULL;
     int type = 0;
     axis2_status_t status = AXIS2_FAILURE;
-   
+
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     AXIS2_PARAM_CHECK(env->error, svc, AXIS2_FAILURE);
     AXIS2_PARAM_CHECK(env->error, module_desc, AXIS2_FAILURE);
     resolver_impl = AXIS2_INTF_TO_IMPL(phase_resolver);
-    
+
     ops = AXIS2_SVC_GET_OPS(svc, env);
     if (!ops)
     {
         return AXIS2_FAILURE;
     }
 
-    for (index_i = axis2_hash_first (ops, env); index_i; 
-        index_i = axis2_hash_next (env, index_i))
+    for (index_i = axis2_hash_first (ops, env); index_i;
+            index_i = axis2_hash_next (env, index_i))
     {
         void *v = NULL;
         axis2_op_t *op_desc = NULL;
@@ -1150,11 +1167,11 @@
             axis2_module_desc_t *module_desc_l = NULL;
             const axis2_qname_t *module_desc_qname_l = NULL;
 
-            module_desc_l = (axis2_module_desc_t *) 
-                AXIS2_ARRAY_LIST_GET(modules, env, j);
-           
-            module_desc_qname_l = AXIS2_MODULE_DESC_GET_QNAME(module_desc_l , 
-                env);
+            module_desc_l = (axis2_module_desc_t *)
+                    AXIS2_ARRAY_LIST_GET(modules, env, j);
+
+            module_desc_qname_l = AXIS2_MODULE_DESC_GET_QNAME(module_desc_l ,
+                    env);
             if(AXIS2_QNAME_EQUALS(module_desc_qname_l, env, module_desc_qname))
             {
                 engaged = AXIS2_TRUE;
@@ -1167,98 +1184,99 @@
         }
         for(type = 1; type < 5; type++)
         {
-            switch (type) {
-                case AXIS2_IN_FLOW:
-                {
-                    axis2_array_list_t *phase_list = NULL; 
+            switch (type)
+            {
+            case AXIS2_IN_FLOW:
+            {
+                axis2_array_list_t *phase_list = NULL;
 
-                    phase_list = AXIS2_OP_GET_REMAINING_PHASES_IN_FLOW(op_desc, env);
-                    if(resolver_impl->phase_holder)
-                    {
-                        AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
-                        resolver_impl->phase_holder = NULL;
-                    }
-                    resolver_impl->phase_holder = 
-                        axis2_phase_holder_create_with_phases(env, phase_list);
-                    break;
-                }
-                case AXIS2_OUT_FLOW:
+                phase_list = AXIS2_OP_GET_REMAINING_PHASES_IN_FLOW(op_desc, env);
+                if(resolver_impl->phase_holder)
                 {
-                    axis2_array_list_t *phase_list = NULL;
-
-                    phase_list = AXIS2_OP_GET_PHASES_OUT_FLOW(op_desc, env);
-                    if(resolver_impl->phase_holder)
-                    {
-                        AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
-                        resolver_impl->phase_holder = NULL;
-                    }
-                    resolver_impl->phase_holder = 
-                        axis2_phase_holder_create_with_phases(env, phase_list);
-                    break;
+                    AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
+                    resolver_impl->phase_holder = NULL;
                 }
-                case AXIS2_FAULT_IN_FLOW:
-                {
-                    axis2_array_list_t *phase_list = NULL;
+                resolver_impl->phase_holder =
+                    axis2_phase_holder_create_with_phases(env, phase_list);
+                break;
+            }
+            case AXIS2_OUT_FLOW:
+            {
+                axis2_array_list_t *phase_list = NULL;
 
-                    phase_list = AXIS2_OP_GET_PHASES_IN_FAULT_FLOW(op_desc, env);
-                    if(resolver_impl->phase_holder)
-                    {
-                        AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
-                        resolver_impl->phase_holder = NULL;
-                    }
-                    resolver_impl->phase_holder = 
-                        axis2_phase_holder_create_with_phases(env, phase_list);
-                    break;
+                phase_list = AXIS2_OP_GET_PHASES_OUT_FLOW(op_desc, env);
+                if(resolver_impl->phase_holder)
+                {
+                    AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
+                    resolver_impl->phase_holder = NULL;
                 }
-                case AXIS2_FAULT_OUT_FLOW:
+                resolver_impl->phase_holder =
+                    axis2_phase_holder_create_with_phases(env, phase_list);
+                break;
+            }
+            case AXIS2_FAULT_IN_FLOW:
+            {
+                axis2_array_list_t *phase_list = NULL;
+
+                phase_list = AXIS2_OP_GET_PHASES_IN_FAULT_FLOW(op_desc, env);
+                if(resolver_impl->phase_holder)
                 {
-                    axis2_array_list_t *phase_list = NULL; 
+                    AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
+                    resolver_impl->phase_holder = NULL;
+                }
+                resolver_impl->phase_holder =
+                    axis2_phase_holder_create_with_phases(env, phase_list);
+                break;
+            }
+            case AXIS2_FAULT_OUT_FLOW:
+            {
+                axis2_array_list_t *phase_list = NULL;
 
-                    phase_list = AXIS2_OP_GET_PHASES_OUT_FAULT_FLOW(op_desc, env);
-                    if(resolver_impl->phase_holder)
-                    {
-                        AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
-                        resolver_impl->phase_holder = NULL;
-                    }
-                    resolver_impl->phase_holder = 
-                        axis2_phase_holder_create_with_phases(env, phase_list);
-                    break;
+                phase_list = AXIS2_OP_GET_PHASES_OUT_FAULT_FLOW(op_desc, env);
+                if(resolver_impl->phase_holder)
+                {
+                    AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
+                    resolver_impl->phase_holder = NULL;
                 }
+                resolver_impl->phase_holder =
+                    axis2_phase_holder_create_with_phases(env, phase_list);
+                break;
+            }
             }
             /******************************************************************/
             /******************* Modules refered by axis2.xml *****************/
             /******************************************************************/
-            switch (type) 
+            switch (type)
             {
-                case AXIS2_IN_FLOW:
-                {
-                    flow = AXIS2_MODULE_DESC_GET_IN_FLOW(module_desc, env);
-                    break;
-                }
-                case AXIS2_OUT_FLOW:
-                {
-                    flow = AXIS2_MODULE_DESC_GET_OUT_FLOW(module_desc, env);
-                    break;
-                }
-                case AXIS2_FAULT_IN_FLOW:
-                {
-                    flow = AXIS2_MODULE_DESC_GET_FAULT_IN_FLOW(module_desc, env);
-                    break;
-                }
-                case AXIS2_FAULT_OUT_FLOW:
-                {
-                    flow = AXIS2_MODULE_DESC_GET_FAULT_OUT_FLOW(module_desc, env);
-                    break;
-                }
+            case AXIS2_IN_FLOW:
+            {
+                flow = AXIS2_MODULE_DESC_GET_IN_FLOW(module_desc, env);
+                break;
+            }
+            case AXIS2_OUT_FLOW:
+            {
+                flow = AXIS2_MODULE_DESC_GET_OUT_FLOW(module_desc, env);
+                break;
+            }
+            case AXIS2_FAULT_IN_FLOW:
+            {
+                flow = AXIS2_MODULE_DESC_GET_FAULT_IN_FLOW(module_desc, env);
+                break;
+            }
+            case AXIS2_FAULT_OUT_FLOW:
+            {
+                flow = AXIS2_MODULE_DESC_GET_FAULT_OUT_FLOW(module_desc, env);
+                break;
             }
-            if (NULL != flow) 
+            }
+            if (NULL != flow)
             {
                 int handler_count = 0;
-                
+
                 handler_count  = AXIS2_FLOW_GET_HANDLER_COUNT(flow, env);
-                for (j = 0; j < handler_count; j++) 
+                for (j = 0; j < handler_count; j++)
                 {
-                    axis2_handler_desc_t *metadata = NULL;    
+                    axis2_handler_desc_t *metadata = NULL;
                     axis2_char_t *phase_name = NULL;
                     axis2_phase_rule_t *phase_rule = NULL;
 
@@ -1273,16 +1291,16 @@
                         return AXIS2_FAILURE;
                     }
                     if ((0 != AXIS2_STRCMP(AXIS2_PHASE_TRANSPORTIN, phase_name)) &&
-                        (0 != AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) &&
-                        (0 != AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) &&
-                        (0 != AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
+                            (0 != AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) &&
+                            (0 != AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) &&
+                            (0 != AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
                     {
                         status = AXIS2_PHASE_HOLDER_ADD_HANDLER(resolver_impl->
-                            phase_holder, env, metadata);
-                       /* if(AXIS2_SUCCESS != status)
-                        {
-                            return status;
-                        }*/
+                                phase_holder, env, metadata);
+                        /* if(AXIS2_SUCCESS != status)
+                         {
+                             return status;
+                         }*/
                     }
                 }
             }
@@ -1293,125 +1311,126 @@
             return status;
         }
     }
-    
+
     return AXIS2_SUCCESS;
 }
 
 
 static axis2_status_t
-axis2_phase_resolver_engage_to_global_chain(axis2_phase_resolver_t *phase_resolver,
-                                                const axis2_env_t *env,
-                                                axis2_module_desc_t *module_desc)
+axis2_phase_resolver_engage_to_global_chain(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_module_desc_t *module_desc)
 {
     axis2_phase_resolver_impl_t *resolver_impl = NULL;
     int type = 0;
     axis2_status_t status = AXIS2_FAILURE;
-   
+
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     resolver_impl = AXIS2_INTF_TO_IMPL(phase_resolver);
-    
-    for (type = 1; type < 5; type++) 
+
+    for (type = 1; type < 5; type++)
     {
         axis2_flow_t *flow = NULL;
 
-        switch (type) 
+        switch (type)
         {
-            case AXIS2_IN_FLOW:
-            {
-                axis2_array_list_t *phase_list = NULL;
+        case AXIS2_IN_FLOW:
+        {
+            axis2_array_list_t *phase_list = NULL;
 
-                phase_list = 
-                    AXIS2_CONF_GET_IN_PHASES_UPTO_AND_INCLUDING_POST_DISPATCH(
-                        resolver_impl->axis2_config, env);
-                if(resolver_impl->phase_holder)
-                {
-                    AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
-                    resolver_impl->phase_holder = NULL;
-                } 
-                resolver_impl->phase_holder = 
-                    axis2_phase_holder_create_with_phases(env, phase_list);
-                if(!resolver_impl->phase_holder) continue;
-                break;
-            }
-            case AXIS2_OUT_FLOW:
+            phase_list =
+                AXIS2_CONF_GET_IN_PHASES_UPTO_AND_INCLUDING_POST_DISPATCH(
+                    resolver_impl->axis2_config, env);
+            if(resolver_impl->phase_holder)
             {
-                axis2_array_list_t *phase_list = NULL;
-
-                phase_list = AXIS2_CONF_GET_OUT_FLOW(resolver_impl->axis2_config,
-                        env);
-                if(resolver_impl->phase_holder)
-                {
-                    AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
-                    resolver_impl->phase_holder = NULL;
-                } 
-                resolver_impl->phase_holder = 
-                    axis2_phase_holder_create_with_phases(env, phase_list);
-                if(!resolver_impl->phase_holder) continue;
-                break;
+                AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
+                resolver_impl->phase_holder = NULL;
             }
-            case AXIS2_FAULT_IN_FLOW:
+            resolver_impl->phase_holder =
+                axis2_phase_holder_create_with_phases(env, phase_list);
+            if(!resolver_impl->phase_holder) continue;
+            break;
+        }
+        case AXIS2_OUT_FLOW:
+        {
+            axis2_array_list_t *phase_list = NULL;
+
+            phase_list = AXIS2_CONF_GET_OUT_FLOW(resolver_impl->axis2_config,
+                    env);
+            if(resolver_impl->phase_holder)
             {
-                axis2_array_list_t *phase_list = NULL;
+                AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
+                resolver_impl->phase_holder = NULL;
+            }
+            resolver_impl->phase_holder =
+                axis2_phase_holder_create_with_phases(env, phase_list);
+            if(!resolver_impl->phase_holder) continue;
+            break;
+        }
+        case AXIS2_FAULT_IN_FLOW:
+        {
+            axis2_array_list_t *phase_list = NULL;
 
-                phase_list = AXIS2_CONF_GET_IN_FAULT_FLOW(resolver_impl->
+            phase_list = AXIS2_CONF_GET_IN_FAULT_FLOW(resolver_impl->
                     axis2_config, env);
-                if(resolver_impl->phase_holder)
-                {
-                    AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
-                    resolver_impl->phase_holder = NULL;
-                } 
-                resolver_impl->phase_holder = 
-                    axis2_phase_holder_create_with_phases(env, phase_list);
-                if(!resolver_impl->phase_holder) continue;
-                break;
-            }
-            case AXIS2_FAULT_OUT_FLOW:
+            if(resolver_impl->phase_holder)
             {
-                axis2_array_list_t *phase_list = NULL;
+                AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
+                resolver_impl->phase_holder = NULL;
+            }
+            resolver_impl->phase_holder =
+                axis2_phase_holder_create_with_phases(env, phase_list);
+            if(!resolver_impl->phase_holder) continue;
+            break;
+        }
+        case AXIS2_FAULT_OUT_FLOW:
+        {
+            axis2_array_list_t *phase_list = NULL;
 
-                phase_list = AXIS2_CONF_GET_OUT_FAULT_FLOW(resolver_impl->
+            phase_list = AXIS2_CONF_GET_OUT_FAULT_FLOW(resolver_impl->
                     axis2_config, env);
-                if(resolver_impl->phase_holder)
-                {
-                    AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
-                    resolver_impl->phase_holder = NULL;
-                } 
-                resolver_impl->phase_holder = 
-                    axis2_phase_holder_create_with_phases(env, phase_list);
-                if(!resolver_impl->phase_holder) continue;
-                break;
+            if(resolver_impl->phase_holder)
+            {
+                AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
+                resolver_impl->phase_holder = NULL;
             }
+            resolver_impl->phase_holder =
+                axis2_phase_holder_create_with_phases(env, phase_list);
+            if(!resolver_impl->phase_holder) continue;
+            break;
+        }
         }
         /**********************************************************************/
         /****************** Modules refered by axis2.xml **********************/
         /**********************************************************************/
-        switch (type) 
+        switch (type)
         {
-            case AXIS2_IN_FLOW:
-            {
-                flow = AXIS2_MODULE_DESC_GET_IN_FLOW(module_desc, env);
-                break;
-            }
-            case AXIS2_OUT_FLOW:
-            {
-                flow = AXIS2_MODULE_DESC_GET_OUT_FLOW(module_desc, env);
-                break;
-            }
-            case AXIS2_FAULT_IN_FLOW:
-            {
-                flow = AXIS2_MODULE_DESC_GET_FAULT_IN_FLOW(module_desc, env);
-                break;
-            }
-            case AXIS2_FAULT_OUT_FLOW:
-            {
-                flow = AXIS2_MODULE_DESC_GET_FAULT_OUT_FLOW(module_desc, env);
-                break;
-            }
+        case AXIS2_IN_FLOW:
+        {
+            flow = AXIS2_MODULE_DESC_GET_IN_FLOW(module_desc, env);
+            break;
         }
-        if (NULL != flow) 
+        case AXIS2_OUT_FLOW:
+        {
+            flow = AXIS2_MODULE_DESC_GET_OUT_FLOW(module_desc, env);
+            break;
+        }
+        case AXIS2_FAULT_IN_FLOW:
+        {
+            flow = AXIS2_MODULE_DESC_GET_FAULT_IN_FLOW(module_desc, env);
+            break;
+        }
+        case AXIS2_FAULT_OUT_FLOW:
+        {
+            flow = AXIS2_MODULE_DESC_GET_FAULT_OUT_FLOW(module_desc, env);
+            break;
+        }
+        }
+        if (NULL != flow)
         {
             int j = 0;
-            for (j = 0; j < AXIS2_FLOW_GET_HANDLER_COUNT(flow, env); j++) 
+            for (j = 0; j < AXIS2_FLOW_GET_HANDLER_COUNT(flow, env); j++)
             {
                 axis2_handler_desc_t *metadata = NULL;
                 axis2_char_t *phase_name = NULL;
@@ -1428,19 +1447,19 @@
                     return AXIS2_FAILURE;
                 }
                 if ((0 == AXIS2_STRCMP(AXIS2_PHASE_TRANSPORTIN, phase_name)) ||
-                    (0 == AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) ||
-                    (0 == AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) ||
-                    (0 == AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
+                        (0 == AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) ||
+                        (0 == AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) ||
+                        (0 == AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
                 {
                     status = AXIS2_PHASE_HOLDER_ADD_HANDLER(resolver_impl->
-                        phase_holder, env, metadata);
+                            phase_holder, env, metadata);
                     if(AXIS2_SUCCESS != status)
                     {
                         return status;
                     }
-          
-                } 
-                /*else 
+
+                }
+                /*else
                 {
                      * These handlers will go to op's handler chains , since 
                      * the module try to add handlres to both sytem predefined
@@ -1451,32 +1470,33 @@
             }
         }
     }
-    
+
     return AXIS2_SUCCESS;
 }
 
 
 axis2_status_t AXIS2_CALL
-axis2_phase_resolver_engage_module_to_svc(axis2_phase_resolver_t *phase_resolver,
-                                            const axis2_env_t *env,
-                                            axis2_svc_t *svc,
-                                            axis2_module_desc_t *module_desc)
+axis2_phase_resolver_engage_module_to_svc(
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_svc_t *svc,
+    axis2_module_desc_t *module_desc)
 {
     axis2_phase_resolver_impl_t *resolver_impl = NULL;
     axis2_hash_t *ops = NULL;
     axis2_hash_index_t *index_i = NULL;
     axis2_status_t status = AXIS2_FAILURE;
     const axis2_qname_t *module_d_qname = NULL;
-    
+
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     resolver_impl = AXIS2_INTF_TO_IMPL(phase_resolver);
-    
+
     ops = AXIS2_SVC_GET_OPS(svc, env);
     if(!ops)
     {
         return AXIS2_FAILURE;
     }
-    status = AXIS2_SVC_ADD_MODULE_OPS(svc, env, module_desc, 
+    status = AXIS2_SVC_ADD_MODULE_OPS(svc, env, module_desc,
             resolver_impl->axis2_config);
 
     if(AXIS2_SUCCESS != status)
@@ -1484,8 +1504,8 @@
         return status;
     }
     module_d_qname = AXIS2_MODULE_DESC_GET_QNAME(module_desc, env);
-    for (index_i = axis2_hash_first (ops, env); index_i; index_i = 
-            axis2_hash_next (env, index_i))
+    for (index_i = axis2_hash_first (ops, env); index_i; index_i =
+                axis2_hash_next (env, index_i))
     {
         axis2_array_list_t *modules = NULL;
         axis2_op_t *op_desc = NULL;
@@ -1523,18 +1543,18 @@
                     module_desc);
             }*/
         }
-        
+
         if(AXIS2_FALSE == engaged)
         {
             status = axis2_phase_resolver_engage_module_to_op(
-                phase_resolver, env, op_desc, module_desc);
+                        phase_resolver, env, op_desc, module_desc);
             if(AXIS2_SUCCESS != status)
             {
                 return status;
             }
-            
-            status = AXIS2_OP_ADD_TO_ENGAGE_MODULE_LIST(op_desc, env, 
-                module_desc);
+
+            status = AXIS2_OP_ADD_TO_ENGAGE_MODULE_LIST(op_desc, env,
+                    module_desc);
         }
 
     }
@@ -1544,92 +1564,92 @@
 
 axis2_status_t AXIS2_CALL
 axis2_phase_resolver_engage_module_to_op(
-        axis2_phase_resolver_t *phase_resolver,
-            const axis2_env_t *env,
-            axis2_op_t *axis_op,
-            axis2_module_desc_t *module_desc)
+    axis2_phase_resolver_t *phase_resolver,
+    const axis2_env_t *env,
+    axis2_op_t *axis_op,
+    axis2_module_desc_t *module_desc)
 {
     axis2_phase_resolver_impl_t *resolver_impl = NULL;
     int type = 0;
-    
+
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
     AXIS2_PARAM_CHECK(env->error, axis_op, AXIS2_FAILURE);
     AXIS2_PARAM_CHECK(env->error, module_desc, AXIS2_FAILURE);
     resolver_impl = AXIS2_INTF_TO_IMPL(phase_resolver);
-       
-    for (type = 1; type < 5; type++) 
+
+    for (type = 1; type < 5; type++)
     {
         axis2_flow_t *flow = NULL;
         axis2_array_list_t *phases = NULL;
-        
+
         if(resolver_impl->phase_holder)
         {
             AXIS2_PHASE_HOLDER_FREE(resolver_impl->phase_holder, env);
             resolver_impl->phase_holder = NULL;
         }
-        
-        switch (type) 
+
+        switch (type)
         {
-            case AXIS2_IN_FLOW:
-            {
-                phases = AXIS2_OP_GET_REMAINING_PHASES_IN_FLOW(axis_op, env);
-                break;
-            }
-            case AXIS2_OUT_FLOW:
-            {
-                phases = AXIS2_OP_GET_PHASES_OUT_FLOW(axis_op, env);
-                break;
-            }
-            case AXIS2_FAULT_IN_FLOW:
-            {
-                phases = AXIS2_OP_GET_PHASES_IN_FAULT_FLOW(axis_op, env);
-                break;
-            }
-            case AXIS2_FAULT_OUT_FLOW:
-            {
-                phases = AXIS2_OP_GET_PHASES_OUT_FAULT_FLOW(axis_op, env);
-                break;
-            }
+        case AXIS2_IN_FLOW:
+        {
+            phases = AXIS2_OP_GET_REMAINING_PHASES_IN_FLOW(axis_op, env);
+            break;
+        }
+        case AXIS2_OUT_FLOW:
+        {
+            phases = AXIS2_OP_GET_PHASES_OUT_FLOW(axis_op, env);
+            break;
+        }
+        case AXIS2_FAULT_IN_FLOW:
+        {
+            phases = AXIS2_OP_GET_PHASES_IN_FAULT_FLOW(axis_op, env);
+            break;
+        }
+        case AXIS2_FAULT_OUT_FLOW:
+        {
+            phases = AXIS2_OP_GET_PHASES_OUT_FAULT_FLOW(axis_op, env);
+            break;
+        }
         }
 
         if(phases)
         {
-            resolver_impl->phase_holder = 
+            resolver_impl->phase_holder =
                 axis2_phase_holder_create_with_phases(env, phases);
         }
 
-        
-        switch (type) 
+
+        switch (type)
         {
-            case AXIS2_IN_FLOW:
-            {
-                flow = AXIS2_MODULE_DESC_GET_IN_FLOW(module_desc, env);
-                break;
-            }
-            case AXIS2_OUT_FLOW:
-            {
-                flow = AXIS2_MODULE_DESC_GET_OUT_FLOW(module_desc, env);
-                break;
-            }
-            case AXIS2_FAULT_IN_FLOW:
-            {
-                flow = AXIS2_MODULE_DESC_GET_FAULT_IN_FLOW(module_desc, env);
-                break;
-            }
-            case AXIS2_FAULT_OUT_FLOW:
-            {
-                flow = AXIS2_MODULE_DESC_GET_FAULT_OUT_FLOW(module_desc, env);
-                break;
-            }
+        case AXIS2_IN_FLOW:
+        {
+            flow = AXIS2_MODULE_DESC_GET_IN_FLOW(module_desc, env);
+            break;
         }
-        
-        if (NULL != flow && NULL != resolver_impl->phase_holder) 
+        case AXIS2_OUT_FLOW:
+        {
+            flow = AXIS2_MODULE_DESC_GET_OUT_FLOW(module_desc, env);
+            break;
+        }
+        case AXIS2_FAULT_IN_FLOW:
+        {
+            flow = AXIS2_MODULE_DESC_GET_FAULT_IN_FLOW(module_desc, env);
+            break;
+        }
+        case AXIS2_FAULT_OUT_FLOW:
+        {
+            flow = AXIS2_MODULE_DESC_GET_FAULT_OUT_FLOW(module_desc, env);
+            break;
+        }
+        }
+
+        if (NULL != flow && NULL != resolver_impl->phase_holder)
         {
             int j = 0;
             int handler_count = 0;
 
             handler_count = AXIS2_FLOW_GET_HANDLER_COUNT(flow, env);
-            for (j = 0; j < handler_count; j++) 
+            for (j = 0; j < handler_count; j++)
             {
                 axis2_handler_desc_t *metadata = NULL;
                 axis2_char_t *phase_name = NULL;
@@ -1640,28 +1660,28 @@
                 phase_rule = AXIS2_HANDLER_DESC_GET_RULES(metadata, env);
                 phase_name = AXIS2_PHASE_RULE_GET_NAME(phase_rule, env);
                 if ((0 != AXIS2_STRCMP(AXIS2_PHASE_TRANSPORTIN, phase_name)) &&
-                    (0 != AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) &&
-                    (0 != AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) &&
-                    (0 != AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
+                        (0 != AXIS2_STRCMP(AXIS2_PHASE_DISPATCH, phase_name)) &&
+                        (0 != AXIS2_STRCMP(AXIS2_PHASE_POST_DISPATCH, phase_name)) &&
+                        (0 != AXIS2_STRCMP(AXIS2_PHASE_PRE_DISPATCH, phase_name)))
                 {
-                    status = AXIS2_PHASE_HOLDER_ADD_HANDLER(resolver_impl->phase_holder, 
-                        env, metadata);
+                    status = AXIS2_PHASE_HOLDER_ADD_HANDLER(resolver_impl->phase_holder,
+                            env, metadata);
                     if(AXIS2_SUCCESS != status)
                     {
-                        AXIS2_LOG_DEBUG(env->log, AXIS2_LOG_SI, 
-                            "Handler inclusion failed for %s phase", phase_name);
+                        AXIS2_LOG_DEBUG(env->log, AXIS2_LOG_SI,
+                                "Handler inclusion failed for %s phase", phase_name);
                         /*return status;*/
                     }
-           
-                } 
-                else 
+
+                }
+                else
                 {
                     AXIS2_LOG_DEBUG(env->log, AXIS2_LOG_SI, "This handler is\
-                        trying to added to system pre defined phases , but those\
-                        handlers are already added to global chain which run\
-                        irrespective of the service");
+                            trying to added to system pre defined phases , but those\
+                            handlers are already added to global chain which run\
+                            irrespective of the service");
                     /*return AXIS2_FAILURE;*/
-                    
+
                 }
             }
         }



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


Mime
View raw message