You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by sa...@apache.org on 2007/01/08 04:10:30 UTC

svn commit: r493920 [1/3] - in /webservices/axis2/trunk/c: modules/core/deployment/ samples/client/yahoo/ util/include/ util/src/

Author: samisa
Date: Sun Jan  7 19:10:29 2007
New Revision: 493920

URL: http://svn.apache.org/viewvc?view=rev&rev=493920
Log:
Dropped ops form util structs and fixed some logc as well. Fixed the formatting in most cases

Modified:
    webservices/axis2/trunk/c/modules/core/deployment/conf_builder.c
    webservices/axis2/trunk/c/modules/core/deployment/dep_engine.c
    webservices/axis2/trunk/c/modules/core/deployment/desc_builder.c
    webservices/axis2/trunk/c/modules/core/deployment/svc_builder.c
    webservices/axis2/trunk/c/samples/client/yahoo/yahoo_client.c
    webservices/axis2/trunk/c/util/include/axis2_env.h
    webservices/axis2/trunk/c/util/include/axis2_error.h
    webservices/axis2/trunk/c/util/include/axis2_file.h
    webservices/axis2/trunk/c/util/include/axis2_generic_obj.h
    webservices/axis2/trunk/c/util/include/axis2_hash.h
    webservices/axis2/trunk/c/util/include/axis2_linked_list.h
    webservices/axis2/trunk/c/util/include/axis2_log.h
    webservices/axis2/trunk/c/util/include/axis2_network_handler.h
    webservices/axis2/trunk/c/util/include/axis2_param.h
    webservices/axis2/trunk/c/util/include/axis2_param_container.h
    webservices/axis2/trunk/c/util/src/env.c
    webservices/axis2/trunk/c/util/src/error.c
    webservices/axis2/trunk/c/util/src/file.c
    webservices/axis2/trunk/c/util/src/generic_obj.c
    webservices/axis2/trunk/c/util/src/hash.c
    webservices/axis2/trunk/c/util/src/linked_list.c
    webservices/axis2/trunk/c/util/src/log.c
    webservices/axis2/trunk/c/util/src/param.c
    webservices/axis2/trunk/c/util/src/param_container.c

Modified: webservices/axis2/trunk/c/modules/core/deployment/conf_builder.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/deployment/conf_builder.c?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/modules/core/deployment/conf_builder.c (original)
+++ webservices/axis2/trunk/c/modules/core/deployment/conf_builder.c Sun Jan  7 19:10:29 2007
@@ -464,7 +464,8 @@
             return AXIS2_FAILURE;
         }
         AXIS2_PARAM_SET_VALUE(impl_info_param, env, dll_desc);
-        impl_info_param->ops->value_free = axis2_dll_desc_free_void_arg;
+        axis2_param_set_value_free(impl_info_param, env, 
+            axis2_dll_desc_free_void_arg);
         axis2_class_loader_init(env);
         disp_dll = (axis2_disp_t *) axis2_class_loader_create_dll(env,
                 impl_info_param);
@@ -776,7 +777,8 @@
             AXIS2_FREE(env->allocator, path_qualified_dll_name);
             AXIS2_DLL_DESC_SET_TYPE(dll_desc, env, AXIS2_TRANSPORT_SENDER_DLL);
             AXIS2_PARAM_SET_VALUE(impl_info_param, env, dll_desc);
-            impl_info_param->ops->value_free = axis2_dll_desc_free_void_arg;
+            axis2_param_set_value_free(impl_info_param, env, 
+                axis2_dll_desc_free_void_arg);
             axis2_class_loader_init(env);
             transport_sender = axis2_class_loader_create_dll(env, impl_info_param);
             AXIS2_TRANSPORT_OUT_DESC_ADD_PARAM(transport_out, env,
@@ -1002,7 +1004,8 @@
                 AXIS2_DLL_DESC_SET_TYPE(dll_desc, env, AXIS2_TRANSPORT_RECV_DLL);
 
                 AXIS2_PARAM_SET_VALUE(impl_info_param, env, dll_desc);
-                impl_info_param->ops->value_free = axis2_dll_desc_free_void_arg;
+                axis2_param_set_value_free(impl_info_param, env, 
+                    axis2_dll_desc_free_void_arg);
                 axis2_class_loader_init(env);
                 recv = (axis2_transport_receiver_t *)
                         axis2_class_loader_create_dll(env, impl_info_param);

Modified: webservices/axis2/trunk/c/modules/core/deployment/dep_engine.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/deployment/dep_engine.c?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/modules/core/deployment/dep_engine.c (original)
+++ webservices/axis2/trunk/c/modules/core/deployment/dep_engine.c Sun Jan  7 19:10:29 2007
@@ -1298,7 +1298,7 @@
     AXIS2_DLL_DESC_SET_TYPE(dll_desc, env, AXIS2_MODULE_DLL);
     impl_info_param = axis2_param_create(env, read_in_dll, NULL);
     AXIS2_PARAM_SET_VALUE(impl_info_param, env, dll_desc);
-    impl_info_param->ops->value_free = axis2_dll_desc_free_void_arg;
+    axis2_param_set_value_free(impl_info_param, env, axis2_dll_desc_free_void_arg);
     axis2_class_loader_init(env);
     module = (axis2_module_t *) axis2_class_loader_create_dll(env,
             impl_info_param);

Modified: webservices/axis2/trunk/c/modules/core/deployment/desc_builder.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/deployment/desc_builder.c?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/modules/core/deployment/desc_builder.c (original)
+++ webservices/axis2/trunk/c/modules/core/deployment/desc_builder.c Sun Jan  7 19:10:29 2007
@@ -1064,7 +1064,7 @@
         AXIS2_DLL_DESC_SET_TYPE(dll_desc, env, AXIS2_MSG_RECV_DLL);
         impl_info_param = axis2_param_create(env, class_name, NULL);
         AXIS2_PARAM_SET_VALUE(impl_info_param, env, dll_desc);
-        impl_info_param->ops->value_free = axis2_dll_desc_free_void_arg;
+        axis2_param_set_value_free(impl_info_param, env, axis2_dll_desc_free_void_arg);
         /* set the impl_info_param(which contain dll_desc as value) so that
          * loaded msg_recv loader lib can be re-used in future
          */

Modified: webservices/axis2/trunk/c/modules/core/deployment/svc_builder.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/deployment/svc_builder.c?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/modules/core/deployment/svc_builder.c (original)
+++ webservices/axis2/trunk/c/modules/core/deployment/svc_builder.c Sun Jan  7 19:10:29 2007
@@ -353,7 +353,8 @@
 
     AXIS2_DLL_DESC_SET_TYPE(dll_desc, env, AXIS2_SVC_DLL);
     status = AXIS2_PARAM_SET_VALUE(impl_info_param, env, dll_desc);
-    impl_info_param->ops->value_free = axis2_dll_desc_free_void_arg;
+    axis2_param_set_value_free(impl_info_param, env, 
+        axis2_dll_desc_free_void_arg);
     if (AXIS2_SUCCESS != status)
     {
         AXIS2_DLL_DESC_FREE(dll_desc, env);

Modified: webservices/axis2/trunk/c/samples/client/yahoo/yahoo_client.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/samples/client/yahoo/yahoo_client.c?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/samples/client/yahoo/yahoo_client.c (original)
+++ webservices/axis2/trunk/c/samples/client/yahoo/yahoo_client.c Sun Jan  7 19:10:29 2007
@@ -109,7 +109,7 @@
         AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Stub invoke FAILED: Error code:"
                 " %d :: %s", env->error->error_number,
                 AXIS2_ERROR_GET_MESSAGE(env->error));
-        printf("echo client invoke FAILED!\n");
+        printf("Yahoo REST client invoke FAILED!\n");
     }
 
     if (svc_client)

Modified: webservices/axis2/trunk/c/util/include/axis2_env.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axis2_env.h?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/util/include/axis2_env.h (original)
+++ webservices/axis2/trunk/c/util/include/axis2_env.h Sun Jan  7 19:10:29 2007
@@ -20,7 +20,7 @@
 
 /**
  * @file axis2_env.h
- * @brief Axis2 environment that acts as a container for error, log and memory 
+ * @brief Axis2 environment that acts as a container for error, log and memory
  *  allocator routines
  */
 
@@ -34,28 +34,28 @@
 {
 #endif
 
-/** @defgroup axis2_util utilities
-  * @ingroup axis2
-  * @{
-  * @}
-  */
+    /** @defgroup axis2_util utilities
+      * @ingroup axis2
+      * @{
+      * @}
+      */
 
 
     struct axis2_env;
     struct axis2_env_ops;
 
-/**
- * @defgroup axis2_env environment
- * @ingroup axis2_util 
- * @{
- */
+    /**
+     * @defgroup axis2_env environment
+     * @ingroup axis2_util
+     * @{
+     */
 
-  /** 
-    * \brief Axis2 Environment struct
-    *
-    * Environment acts as a container for error, log, memory allocator and other
-    * routines
-    */
+    /**
+      * \brief Axis2 Environment struct
+      *
+      * Environment acts as a container for error, log, memory allocator and other
+      * routines
+      */
     typedef struct axis2_env
     {
         /** Memory allocation routines */
@@ -64,11 +64,12 @@
         axis2_error_t *error;
         /** Logging routines */
         axis2_log_t *log;
-      /** This flag indicate whether logging is enabled or not */
-      axis2_bool_t log_enabled;
-      /** Thread pooling routines */
-      axis2_thread_pool_t *thread_pool;
-    } axis2_env_t;
+        /** This flag indicate whether logging is enabled or not */
+        axis2_bool_t log_enabled;
+        /** Thread pooling routines */
+        axis2_thread_pool_t *thread_pool;
+    }
+    axis2_env_t;
 
     /**
     * Creates an environment struct with all of its default parts,
@@ -77,71 +78,77 @@
     * @param log_level log level to be used
     * @return pointer to the newly created environment struct 
     */
-    AXIS2_EXTERN axis2_env_t * AXIS2_CALL axis2_env_create_all (const axis2_char_t *log_file, 
-        const axis2_log_levels_t log_level);                                                   
+    AXIS2_EXTERN axis2_env_t * AXIS2_CALL 
+    axis2_env_create_all(const axis2_char_t *log_file,
+        const axis2_log_levels_t log_level);
 
-   /**
-    * Creates an environment struct. Users of axis2 should not use this function
-   * to create an environment. He should use the other two create functions.
-    * @param allocator pointer to an instance of allocator struct. Must be non-NULL    
-    * @return pointer to the newly created environment struct 
-    */
-    AXIS2_EXTERN axis2_env_t * AXIS2_CALL axis2_env_create (axis2_allocator_t
-                                                   *allocator);                                                   
-   
-  /**
-    * Creates an environment struct
-    * @param allocator pointer to an instance of allocator struct. Must be non-NULL
-    * @param error pointer to an instance of error struct. Must be non-NULL.
-    * it would be taken as a flag for no logging.    
-    * @return pointer to the newly created environment struct 
-    */
-    AXIS2_EXTERN axis2_env_t * AXIS2_CALL axis2_env_create_with_error 
-                                       (axis2_allocator_t *allocator
-                                                   , axis2_error_t *error);
-   
-   /**
-    * Creates an environment struct
-    * @param allocator pointer to an instance of allocator struct. Must be non-NULL
-    * @param error pointer to an instance of error struct. Must be non-NULL.
-    * @param log pointer to an instance of log struct. May be NULL. If NULL
-    * it would be taken as a flag for no logging.    
-    * @return pointer to the newly created environment struct 
-    */
-    AXIS2_EXTERN axis2_env_t * AXIS2_CALL axis2_env_create_with_error_log 
-                                       (axis2_allocator_t *allocator
-                                                   , axis2_error_t *error
-                                                   , axis2_log_t *log);
-                                       
-      /**
+    /**
+     * Creates an environment struct. Users of axis2 should not use this function
+    * to create an environment. He should use the other two create functions.
+     * @param allocator pointer to an instance of allocator struct. Must be non-NULL   
+     * @return pointer to the newly created environment struct 
+     */
+    AXIS2_EXTERN axis2_env_t * AXIS2_CALL 
+    axis2_env_create(axis2_allocator_t *allocator);
+
+    /**
+      * Creates an environment struct
+      * @param allocator pointer to an instance of allocator struct. Must be non-NULL
+      * @param error pointer to an instance of error struct. Must be non-NULL.
+      * it would be taken as a flag for no logging.  
+      * @return pointer to the newly created environment struct 
+      */
+    AXIS2_EXTERN axis2_env_t * AXIS2_CALL 
+    axis2_env_create_with_error(axis2_allocator_t *allocator, 
+        axis2_error_t *error);
+
+    /**
+     * Creates an environment struct
+     * @param allocator pointer to an instance of allocator struct. Must be non-NULL
+     * @param error pointer to an instance of error struct. Must be non-NULL.
+     * @param log pointer to an instance of log struct. May be NULL. If NULL
+     * it would be taken as a flag for no logging.   
+     * @return pointer to the newly created environment struct 
+     */
+    AXIS2_EXTERN axis2_env_t * AXIS2_CALL 
+    axis2_env_create_with_error_log(axis2_allocator_t *allocator, 
+        axis2_error_t *error, 
+        axis2_log_t *log);
+
+    /**
     * Creates an environment struct
     * @param allocator pointer to an instance of allocator struct. Must be non-NULL
     * @param error pointer to an instance of error struct. Must be non-NULL.
     * @param log pointer to an instance of log struct. May be NULL. If NULL
     * it would be taken as a flag for no logging.
-   * @param pool pointer to an instance of thread_pool. May be NULL. If NULL
+    * @param pool pointer to an instance of thread_pool. May be NULL. If NULL
     * @return pointer to the newly created environment struct 
     */
-    AXIS2_EXTERN axis2_env_t * AXIS2_CALL axis2_env_create_with_error_log_thread_pool 
-                                       (axis2_allocator_t *allocator
-                                                   , axis2_error_t *error
-                                                   , axis2_log_t *log
-                                       , axis2_thread_pool_t *pool);
+    AXIS2_EXTERN axis2_env_t * AXIS2_CALL 
+    axis2_env_create_with_error_log_thread_pool(axis2_allocator_t *allocator, 
+        axis2_error_t *error, 
+        axis2_log_t *log, 
+        axis2_thread_pool_t *pool);
 
-  /**
-    * Creates an environment struct
-    * @param allocator pointer to an instance of allocator struct. Mandatory, cannot be NULL
-    * @param error pointer to an instance of error struct. Optional, can be NULL. If NULL default error handler would be used.
-    * @param log pointer to an instance of log struct. Optional, can be NULL. If NULL default log handler would be used.
-    * @param string pointer to an instance of string struct. Optional, can be NULL. If NULL default string handler would be used.
-    * @return pointer to the newly created environment struct 
-    */
-    AXIS2_EXTERN axis2_status_t AXIS2_CALL axis2_env_free (axis2_env_t *env);
+    /**
+      * Creates an environment struct
+      * @param allocator pointer to an instance of allocator struct. 
+      * @param error pointer to an instance of error struct. 
+      * Optional, can be NULL. If NULL default error handler would be used.
+      * @param log pointer to an instance of log struct. Optional, can be NULL.
+      * If NULL default log handler would be used.
+      * @param string pointer to an instance of string struct. 
+      * Optional, can be NULL. If NULL default string handler would be used.
+      * @return pointer to the newly created environment struct 
+      */
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL 
+    axis2_env_free(axis2_env_t *env);
 
     /**
     * Frees the environment
     * @param env environment to be freed
-    * @param mask bit pattern to according to which the components of the env struct are freed
+    * @param mask bit pattern to according to which the components of the env 
+    * struct are freed
     *       0x1 - Frees the log
     *       0x2 - Frees the error
     *       0x4 - Frees the thread pool
@@ -149,35 +156,44 @@
     *       Eg : 0x3 frees both log and error
     * @return status of the operation
     */
-    AXIS2_EXTERN axis2_status_t AXIS2_CALL  axis2_env_free_masked(axis2_env_t *env, char mask); 
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL 
+    axis2_env_free_masked(axis2_env_t *env, 
+        char mask);
     /**
      * Enables logging
      */
-    AXIS2_EXTERN axis2_status_t AXIS2_CALL axis2_env_enable_log (axis2_env_t *env, axis2_bool_t enable);
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL 
+    axis2_env_enable_log(axis2_env_t *env, 
+        axis2_bool_t enable);
 
     /**
       * Checks the status code of environment
       */
-    AXIS2_EXTERN axis2_status_t AXIS2_CALL axis2_env_check_status (const axis2_env_t *env);
-    
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL 
+    axis2_env_check_status(const axis2_env_t *env);
+
     /**
       * Writes given message to the log
       */
-    AXIS2_EXTERN axis2_status_t AXIS2_CALL axis2_env_write_log (const axis2_env_t *env, const char* message, axis2_log_levels_t level);
-    #define AXIS2_LOG(env, message, level) axis2_env_write_log (env,message, level)
-
-
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL 
+    axis2_env_write_log(const axis2_env_t *env, 
+        const char* message, 
+        axis2_log_levels_t level);
+        
+#define AXIS2_LOG(env, message, level) axis2_env_write_log (env,message, level)
 
 #define AXIS2_ENV_CHECK(env, error_return) \
     if(!env) \
     { \
         return error_return; \
-    } 
+    }
 
-/** @} */
+    /** @} */
 
 #ifdef __cplusplus
 }
 #endif
 
 #endif                          /* AXIS2_ENV_H */
+
+

Modified: webservices/axis2/trunk/c/util/include/axis2_error.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axis2_error.h?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/util/include/axis2_error.h (original)
+++ webservices/axis2/trunk/c/util/include/axis2_error.h Sun Jan  7 19:10:29 2007
@@ -582,15 +582,15 @@
 		 * @return axis2_status_t status code
 		 */
 
-        axis2_status_t (AXIS2_CALL *free)(struct axis2_error *error);
+        axis2_status_t (AXIS2_CALL *
+        free)(struct axis2_error *error);
         
 		/**
 		 * get error message for the last error
 		 * @return error message for the last error. NULL on error.
 		 */
 		const axis2_char_t *(AXIS2_CALL *
-							 get_message)(
-								 const struct axis2_error *error);
+        get_message)(const struct axis2_error *error);
       
 		/**
 		 * This fucntion is supposed to be overridden in an extended error structure.
@@ -600,19 +600,22 @@
 		 * @return error message for the extended struct.
 		 */
 		const axis2_char_t *(AXIS2_CALL *
-							 get_extended_message)(
-								 const struct axis2_error *error);
+        get_extended_message)(const struct axis2_error *error);
       
-		axis2_status_t  (AXIS2_CALL *set_error_number) (struct axis2_error *error
-														,  axis2_error_codes_t error_number);
+		axis2_status_t (AXIS2_CALL *
+        set_error_number) (struct axis2_error *error,
+            axis2_error_codes_t error_number);
 		
-		axis2_status_t  (AXIS2_CALL *set_status_code) (struct axis2_error *error
-													   , axis2_status_codes_t status_code);
+		axis2_status_t (AXIS2_CALL *
+        set_status_code)(struct axis2_error *error, 
+            axis2_status_codes_t status_code);
       
-		axis2_status_t  (AXIS2_CALL *get_status_code) (struct axis2_error *error);
+		axis2_status_t (AXIS2_CALL *
+        get_status_code) (struct axis2_error *error);
 
-		axis2_status_t (AXIS2_CALL *set_error_message) (struct axis2_error *error
-														, axis2_char_t *message);
+		axis2_status_t (AXIS2_CALL *
+        set_error_message) (struct axis2_error *error,
+            axis2_char_t *message);
           
     } axis2_error_ops_t;
 
@@ -661,3 +664,4 @@
 
 
 #endif                          /* AXIS2_ERROR_H */
+

Modified: webservices/axis2/trunk/c/util/include/axis2_file.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axis2_file.h?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/util/include/axis2_file.h (original)
+++ webservices/axis2/trunk/c/util/include/axis2_file.h Sun Jan  7 19:10:29 2007
@@ -29,115 +29,90 @@
 extern "C"
 {
 #endif
-    
-typedef struct axis2_file axis2_file_t;
-typedef struct axis2_file_ops axis2_file_ops_t;
-    
-/**
- * @defgroup axis2_file file
- * @ingroup axis2_util 
- * @{
- */
-
-/** 
- * @brief Description Builder ops struct
- * Encapsulator struct for ops of axis2_desc_builder
- */
- struct axis2_file_ops
-{
-
-    axis2_status_t (AXIS2_CALL *
-    free) (axis2_file_t *file, 
-            const axis2_env_t *env);
-
-    axis2_status_t (AXIS2_CALL *
-    set_name)(axis2_file_t *file,
-                const axis2_env_t *env,
-                axis2_char_t *name);
-    
-    axis2_char_t *(AXIS2_CALL *
-    get_name)(axis2_file_t *file,
-                const axis2_env_t *env);
-    
-    axis2_status_t (AXIS2_CALL *
-    set_path)(axis2_file_t *file,
-                const axis2_env_t *env,
-                axis2_char_t *path);
-    
-    axis2_char_t *(AXIS2_CALL *
-    get_path)(axis2_file_t *file,
-                const axis2_env_t *env);
-    
-    axis2_status_t (AXIS2_CALL *
-    set_timestamp)(axis2_file_t *file,
-                    const axis2_env_t *env,
-                    AXIS2_TIME_T timestamp);
-    
-    AXIS2_TIME_T (AXIS2_CALL *
-    get_timestamp)(axis2_file_t *file,
-                    const axis2_env_t *env);    
+
+    typedef struct axis2_file axis2_file_t;
 
     /**
-     * create a newly allocated clone of the argument file
+     * @defgroup axis2_file file
+     * @ingroup axis2_util
+     * @{
      */
-    axis2_file_t *(AXIS2_CALL *
-    clone)(axis2_file_t *file,
-                      const axis2_env_t *env);
-};
-    
-     
-/** 
-     * @brief
-     * To store filename and timestamp of each module or service archive file
-     */ 
- struct axis2_file
-{
-   axis2_file_ops_t *ops;
-};
-
-/**
- * create new file
- * @return file newly created file
- */
-AXIS2_EXTERN axis2_file_t * AXIS2_CALL
-axis2_file_create(const axis2_env_t *env);
 
-/*************************** Function macros **********************************/
+    /**
+     * create new file
+     * @return file newly created file
+     */
+    AXIS2_EXTERN axis2_file_t * AXIS2_CALL
+    axis2_file_create(const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_file_free(axis2_file_t *file,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_file_set_name(axis2_file_t *file,
+        const axis2_env_t *env,
+        axis2_char_t *name);
+
+    AXIS2_EXTERN axis2_char_t * AXIS2_CALL
+    axis2_file_get_name(axis2_file_t *file,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_file_set_path(axis2_file_t *file,
+        const axis2_env_t *env,
+        axis2_char_t *path);
+
+    AXIS2_EXTERN axis2_char_t * AXIS2_CALL
+    axis2_file_get_path(axis2_file_t *file,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_file_set_timestamp(axis2_file_t *file,
+        const axis2_env_t *env,
+        AXIS2_TIME_T timestamp);
+
+    AXIS2_EXTERN AXIS2_TIME_T AXIS2_CALL
+    axis2_file_get_timestamp(axis2_file_t *file,
+        const axis2_env_t *env);
+
+    /**
+     * create a newly allocated clone of the argument file
+     */
+    AXIS2_EXTERN axis2_file_t * AXIS2_CALL
+    axis2_file_clone(axis2_file_t *file,
+        const axis2_env_t *env);
 
 #define AXIS2_FILE_FREE(file, env) \
-      ((file)->ops->free (file, env))
+      axis2_file_free (file, env)
 
 #define AXIS2_FILE_GET_NAME(file, env) \
-      ((file)->ops->get_name (file, env))  
+      axis2_file_get_name (file, env)
 
 #define AXIS2_FILE_SET_NAME(file, env, name) \
-      ((file)->ops->set_name (file, env, name)) 
+      axis2_file_set_name (file, env, name)
 
 #define AXIS2_FILE_GET_PATH(file, env) \
-      ((file)->ops->get_path (file, env))  
+      axis2_file_get_path (file, env)
 
 #define AXIS2_FILE_SET_PATH(file, env, path) \
-      ((file)->ops->set_path (file, env, path)) 
+      axis2_file_set_path (file, env, path)
 
 #define AXIS2_FILE_GET_TIMESTAMP(file, env) \
-      ((file)->ops->get_timestamp (file, env))  
+      axis2_file_get_timestamp (file, env)
 
 #define AXIS2_FILE_SET_TIMESTAMP(file, env, timestamp) \
-      ((file)->ops->set_timestamp (file, env, timestamp)) 
+      axis2_file_set_timestamp (file, env, timestamp)
 
 #define AXIS2_FILE_CLONE(file, env) \
-      ((file)->ops->clone (file, env))
-
-
-                                        
-/*************************** End of function macros ***************************/
+      axis2_file_clone (file, env)
 
+    /** @} */
 
-
-/** @} */
-    
 #ifdef __cplusplus
 }
 #endif
 
 #endif  /* AXIS2_FILE_H */
+
+

Modified: webservices/axis2/trunk/c/util/include/axis2_generic_obj.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axis2_generic_obj.h?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/util/include/axis2_generic_obj.h (original)
+++ webservices/axis2/trunk/c/util/include/axis2_generic_obj.h Sun Jan  7 19:10:29 2007
@@ -28,100 +28,74 @@
 extern "C"
 {
 #endif
-    
-typedef struct axis2_generic_obj axis2_generic_obj_t;
-typedef struct axis2_generic_obj_ops axis2_generic_obj_ops_t;
-    
-/**
- * @defgroup axis2_generic_obj generic object
- * @ingroup axis2_util 
- * @{
- */
-
-/** 
- * @brief Description Builder ops struct
- * Encapsulator struct for ops of axis2_desc_builder
- */
- struct axis2_generic_obj_ops
-{
-
-    axis2_status_t (AXIS2_CALL *
-    free) (
-            axis2_generic_obj_t *generic_obj, 
-            const axis2_env_t *env);
-
-    axis2_status_t (AXIS2_CALL *
-    set_free_func) (axis2_generic_obj_t *generic_obj,
-                    const axis2_env_t *env,
-                    AXIS2_FREE_VOID_ARG free_func);
-
-    axis2_status_t (AXIS2_CALL *
-    set_value) (axis2_generic_obj_t *generic_obj,
-                const axis2_env_t *env,
-                void *value);
-
-    void *(AXIS2_CALL *
-    get_value) (axis2_generic_obj_t *generic_obj,
-                            const axis2_env_t *env);
-
-    axis2_status_t (AXIS2_CALL *
-    set_type) (
-            axis2_generic_obj_t *generic_obj,
-            const axis2_env_t *env,
-            int type);
-
-    int (AXIS2_CALL *
-    get_type) (
-            axis2_generic_obj_t *generic_obj,
-            const axis2_env_t *env);
-
-
-};
-    
-     
-/** 
-     * @brief
-     */ 
- struct axis2_generic_obj
-{
-   axis2_generic_obj_ops_t *ops;
-};
-
-/**
- * create new generic_obj
- * @return generic_obj newly created generic_obj
- */
-AXIS2_EXTERN axis2_generic_obj_t * AXIS2_CALL
-axis2_generic_obj_create(const axis2_env_t *env);
 
-/*************************** Function macros **********************************/
+    typedef struct axis2_generic_obj axis2_generic_obj_t;
+
+    /**
+     * @defgroup axis2_generic_obj generic object
+     * @ingroup axis2_util
+     * @{
+     */
+
+    /**
+     * create new generic_obj
+     * @return generic_obj newly created generic_obj
+     */
+    AXIS2_EXTERN axis2_generic_obj_t * AXIS2_CALL
+    axis2_generic_obj_create(const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_generic_obj_free(axis2_generic_obj_t *generic_obj,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_generic_obj_set_free_func(axis2_generic_obj_t *generic_obj,
+        const axis2_env_t *env,
+        AXIS2_FREE_VOID_ARG free_func);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_generic_obj_set_value(axis2_generic_obj_t *generic_obj,
+        const axis2_env_t *env,
+        void *value);
+
+    AXIS2_EXTERN void * AXIS2_CALL
+    axis2_generic_obj_get_value(axis2_generic_obj_t *generic_obj,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_generic_obj_set_type(axis2_generic_obj_t *generic_obj,
+        const axis2_env_t *env,
+        int type);
+
+    AXIS2_EXTERN int AXIS2_CALL
+    axis2_generic_obj_get_type(axis2_generic_obj_t *generic_obj,
+        const axis2_env_t *env);
+
 
 #define AXIS2_GENERIC_OBJ_FREE(generic_obj, env) \
-      (((axis2_generic_obj_t *) generic_obj)->ops->free (generic_obj, env))
+      axis2_generic_obj_free (generic_obj, env)
 
 #define AXIS2_GENERIC_OBJ_SET_FREE_FUNC(generic_obj, env, free_func) \
-      ((generic_obj)->ops->set_free_func (generic_obj, env, free_func))  
+      axis2_generic_obj_set_free_func (generic_obj, env, free_func)
 
 #define AXIS2_GENERIC_OBJ_SET_VALUE(generic_obj, env, value) \
-      ((generic_obj)->ops->set_value (generic_obj, env, value))
+      axis2_generic_obj_set_value (generic_obj, env, value)
 
 #define AXIS2_GENERIC_OBJ_GET_VALUE(generic_obj, env) \
-        ((generic_obj)->ops->get_value(generic_obj, env))
- 
+        axis2_generic_obj_get_value(generic_obj, env)
+
 #define AXIS2_GENERIC_OBJ_SET_TYPE(generic_obj, env, type) \
-      ((generic_obj)->ops->set_type (generic_obj, env, type))
+      axis2_generic_obj_set_type (generic_obj, env, type)
 
 #define AXIS2_GENERIC_OBJ_GET_TYPE(generic_obj, env) \
-        ((generic_obj)->ops->get_type(generic_obj, env))
-                                                
-/*************************** End of function macros ***************************/
+        axis2_generic_obj_get_type(generic_obj, env)
 
+    /** @} */
 
-
-/** @} */
-    
 #ifdef __cplusplus
 }
 #endif
 
 #endif  /* AXIS2_GENERIC_OBJ_H */
+
+

Modified: webservices/axis2/trunk/c/util/include/axis2_hash.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axis2_hash.h?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/util/include/axis2_hash.h (original)
+++ webservices/axis2/trunk/c/util/include/axis2_hash.h Sun Jan  7 19:10:29 2007
@@ -31,222 +31,248 @@
 {
 #endif
 
-/**
- * @defgroup axis2_hash hash
- * @ingroup axis2_util 
- * @{
- */
-
-/**
- * When passing a key to axis2_hash_set or axis2_hash_get, this value can be
- * passed to indicate a string-valued key, and have axis2_hash compute the
- * length automatically.
- *
- * @remark axis2_hash will use strlen(key) for the length. The NUL terminator
- *         is not included in the hash value (why throw a constant in?).
- *         Since the hash table merely references the provided key (rather
- *         than copying it), axis2_hash_this() will return the NUL-term'd key.
- */
+    /**
+     * @defgroup axis2_hash hash
+     * @ingroup axis2_util
+     * @{
+     */
+
+    /**
+     * When passing a key to axis2_hash_set or axis2_hash_get, this value can be
+     * passed to indicate a string-valued key, and have axis2_hash compute the
+     * length automatically.
+     *
+     * @remark axis2_hash will use strlen(key) for the length. The NUL terminator
+     *         is not included in the hash value (why throw a constant in?).
+     *         Since the hash table merely references the provided key (rather
+     *         than copying it), axis2_hash_this() will return the NUL-term'd key.
+     */
 #define AXIS2_HASH_KEY_STRING     (-1)
 
-/**
- * Abstract type for hash tables.
- */
+    /**
+     * Abstract type for hash tables.
+     */
     typedef struct axis2_hash_t axis2_hash_t;
 
-/**
- * Abstract type for scanning hash tables.
- */
+    /**
+     * Abstract type for scanning hash tables.
+     */
     typedef struct axis2_hash_index_t axis2_hash_index_t;
 
-/**
- * Callback functions for calculating hash values.
- * @param key The key.
- * @param klen The length of the key, or AXIS2_HASH_KEY_STRING to use the string 
- *             length. If AXIS2_HASH_KEY_STRING then returns the actual key length.
- */
-    typedef unsigned int (*axis2_hashfunc_t) (const char *key, axis2_ssize_t *klen);
-
-/**
- * The default hash function.
- */
-    unsigned int axis2_hashfunc_default (const char *key, axis2_ssize_t *klen);
-
-/**
- * Create a hash table.
- * @param env The environment to allocate the hash table out of
- * @return The hash table just created
-  */
-  AXIS2_EXTERN axis2_hash_t* AXIS2_CALL axis2_hash_make (const axis2_env_t *env);
-
-/**
- * Create a hash table with a custom hash function
- * @param env The environment to allocate the hash table out of
- * @param hash_func A custom hash function.
- * @return The hash table just created
-  */
-   AXIS2_EXTERN axis2_hash_t* AXIS2_CALL axis2_hash_make_custom (const axis2_env_t *env
-            , axis2_hashfunc_t hash_func);
-
-/**
- * Make a copy of a hash table
- * @param ht The hash table to clone
- * @param env The environment from which to allocate the new hash table
- * @return The hash table just created
- * @remark Makes a shallow copy
- */
-  AXIS2_EXTERN axis2_hash_t* AXIS2_CALL axis2_hash_copy (const axis2_hash_t *ht
-           , const axis2_env_t *env);
-
-/**
- * Associate a value with a key in a hash table.
- * @param ht The hash table
- * @param key Pointer to the key
- * @param klen Length of the key. Can be AXIS2_HASH_KEY_STRING to use the string length.
- * @param val Value to associate with the key
- * @remark If the value is NULL the hash entry is deleted.
- */
-  AXIS2_EXTERN void AXIS2_CALL axis2_hash_set (axis2_hash_t *ht, const void *key
-           , axis2_ssize_t klen, const void *val);
-
-/**
- * Look up the value associated with a key in a hash table.
- * @param ht The hash table
- * @param key Pointer to the key
- * @param klen Length of the key. Can be AXIS2_HASH_KEY_STRING to use the string length.
- * @return Returns NULL if the key is not present.
- */
-   AXIS2_EXTERN void* AXIS2_CALL axis2_hash_get (axis2_hash_t *ht, const void *key
-            , axis2_ssize_t klen);
-
-/**
- * Start iterating over the entries in a hash table.
- * @param ht The hash table
- * @param p The environment to allocate the axis2_hash_index_t iterator. If this
- *          environment is NULL, then an internal, non-thread-safe iterator is used.
- * @remark  There is no restriction on adding or deleting hash entries during
- * an iteration (although the results may be unpredictable unless all you do
- * is delete the current entry) and multiple iterations can be in
- * progress at the same time.
-
- * @example
- */
-/**
- * <PRE>
- * 
- * int sum_values(const axis2_env_t *env, axis2_hash_t *ht)
- * {
- *     axis2_hash_index_t *hi;
- *     void *val;
- *     int sum = 0;
- *     for (hi = axis2_hash_first(p, ht); hi; hi = axis2_hash_next(p, hi)) {
- *         axis2_hash_this(hi, NULL, NULL, &val);
- *         sum += *(int *)val;
- *     }
- *     return sum;
- * }
- * </PRE>
- */
- AXIS2_EXTERN axis2_hash_index_t* AXIS2_CALL axis2_hash_first (axis2_hash_t *ht
-          ,const axis2_env_t *env);
-
-/**
- * Continue iterating over the entries in a hash table.
- * @param hi The iteration state
- * @return a pointer to the updated iteration state.  NULL if there are no more  
- *         entries.
- */
- AXIS2_EXTERN axis2_hash_index_t* AXIS2_CALL axis2_hash_next (const axis2_env_t *env
-          , axis2_hash_index_t *hi);
-
-/**
- * Get the current entry's details from the iteration state.
- * @param hi The iteration state
- * @param key Return pointer for the pointer to the key.
- * @param klen Return pointer for the key length.
- * @param val Return pointer for the associated value.
- * @remark The return pointers should point to a variable that will be set to the
- *         corresponding data, or they may be NULL if the data isn't interesting.
- */
- AXIS2_EXTERN void AXIS2_CALL axis2_hash_this (axis2_hash_index_t *hi, const void **key
-            , axis2_ssize_t *klen, void **val);
-
-/**
- * Get the number of key/value pairs in the hash table.
- * @param ht The hash table
- * @return The number of key/value pairs in the hash table.
- */
-  AXIS2_EXTERN  unsigned int AXIS2_CALL axis2_hash_count (axis2_hash_t *ht);
-
-/**
- * Merge two hash tables into one new hash table. The values of the overlay
- * hash override the values of the base if both have the same key.  Both
- * hash tables must use the same hash function.
- * @param overlay The table to add to the initial table
- * @param p The environment to use for the new hash table
- * @param base The table that represents the initial values of the new table
- * @return A new hash table containing all of the data from the two passed in
- */
-  AXIS2_EXTERN axis2_hash_t* AXIS2_CALL axis2_hash_overlay (const axis2_hash_t *overlay
-           ,const axis2_env_t *env, const axis2_hash_t *base);
-
-/**
- * Merge two hash tables into one new hash table. If the same key
- * is present in both tables, call the supplied merge function to
- * produce a merged value for the key in the new table.  Both
- * hash tables must use the same hash function.
- * @param h1 The first of the tables to merge
- * @param p The environment to use for the new hash table
- * @param h2 The second of the tables to merge
- * @param merger A callback function to merge values, or NULL to
- *  make values from h1 override values from h2 (same semantics as
- *  axis2_hash_overlay())
- * @param data Client data to pass to the merger function
- * @return A new hash table containing all of the data from the two passed in
- */
-  AXIS2_EXTERN axis2_hash_t* AXIS2_CALL axis2_hash_merge (const axis2_hash_t *h1
-           , const axis2_env_t *env, const axis2_hash_t *h2
-            , void *(*merger) (const axis2_env_t *env, const void *key
-            , axis2_ssize_t klen, const void *h1_val, const void *h2_val
-            , const void *data), const void *data);
-
-/**
- * Query whether the hash table provided as parameter contains the
- * key provided as parameter.
- *
- * @param ht hash table to be queried for key
- * @return return whether hash table contains key
- */
-AXIS2_EXTERN axis2_bool_t AXIS2_CALL
-axis2_hash_contains_key (
-        axis2_hash_t *ht, 
+    /**
+     * Callback functions for calculating hash values.
+     * @param key The key.
+     * @param klen The length of the key, or AXIS2_HASH_KEY_STRING to use the string
+     *             length. If AXIS2_HASH_KEY_STRING then returns the actual key length.
+     */
+    typedef unsigned int(*axis2_hashfunc_t)(const char *key, axis2_ssize_t *klen);
+
+    /**
+     * The default hash function.
+     */
+    unsigned int axis2_hashfunc_default(const char *key, 
+        axis2_ssize_t *klen);
+
+    /**
+     * Create a hash table.
+     * @param env The environment to allocate the hash table out of
+     * @return The hash table just created
+      */
+    AXIS2_EXTERN axis2_hash_t* AXIS2_CALL 
+    axis2_hash_make(const axis2_env_t *env);
+
+    /**
+     * Create a hash table with a custom hash function
+     * @param env The environment to allocate the hash table out of
+     * @param hash_func A custom hash function.
+     * @return The hash table just created
+      */
+    AXIS2_EXTERN axis2_hash_t* AXIS2_CALL 
+    axis2_hash_make_custom(const axis2_env_t *env,
+        axis2_hashfunc_t hash_func);
+
+    /**
+     * Make a copy of a hash table
+     * @param ht The hash table to clone
+     * @param env The environment from which to allocate the new hash table
+     * @return The hash table just created
+     * @remark Makes a shallow copy
+     */
+    AXIS2_EXTERN axis2_hash_t* AXIS2_CALL 
+    axis2_hash_copy(const axis2_hash_t *ht,
+        const axis2_env_t *env);
+
+    /**
+     * Associate a value with a key in a hash table.
+     * @param ht The hash table
+     * @param key Pointer to the key
+     * @param klen Length of the key. Can be AXIS2_HASH_KEY_STRING to use the string length.
+     * @param val Value to associate with the key
+     * @remark If the value is NULL the hash entry is deleted.
+     */
+    AXIS2_EXTERN void AXIS2_CALL 
+    axis2_hash_set(axis2_hash_t *ht, 
+        const void *key,
+        axis2_ssize_t klen, 
+        const void *val);
+
+    /**
+     * Look up the value associated with a key in a hash table.
+     * @param ht The hash table
+     * @param key Pointer to the key
+     * @param klen Length of the key. Can be AXIS2_HASH_KEY_STRING to use the string length.
+     * @return Returns NULL if the key is not present.
+     */
+    AXIS2_EXTERN void* AXIS2_CALL 
+    axis2_hash_get(axis2_hash_t *ht, 
+        const void *key,
+        axis2_ssize_t klen);
+
+    /**
+     * Start iterating over the entries in a hash table.
+     * @param ht The hash table
+     * @param p The environment to allocate the axis2_hash_index_t iterator. If this
+     *          environment is NULL, then an internal, non-thread-safe iterator is used.
+     * @remark  There is no restriction on adding or deleting hash entries during
+     * an iteration (although the results may be unpredictable unless all you do
+     * is delete the current entry) and multiple iterations can be in
+     * progress at the same time.
+
+     * @example
+     */
+    /**
+     * <PRE>
+     *
+     * int sum_values(const axis2_env_t *env, axis2_hash_t *ht)
+     * {
+     *     axis2_hash_index_t *hi;
+     *     void *val;
+     *     int sum = 0;
+     *     for (hi = axis2_hash_first(p, ht); hi; hi = axis2_hash_next(p, hi)) {
+     *         axis2_hash_this(hi, NULL, NULL, &val);
+     *         sum += *(int *)val;
+     *     }
+     *     return sum;
+     * }
+     * </PRE>
+     */
+    AXIS2_EXTERN axis2_hash_index_t* AXIS2_CALL 
+    axis2_hash_first(axis2_hash_t *ht,
+        const axis2_env_t *env);
+
+    /**
+     * Continue iterating over the entries in a hash table.
+     * @param hi The iteration state
+     * @return a pointer to the updated iteration state.  NULL if there are no more
+     *         entries.
+     */
+    AXIS2_EXTERN axis2_hash_index_t* AXIS2_CALL 
+    axis2_hash_next(const axis2_env_t *env,
+        axis2_hash_index_t *hi);
+
+    /**
+     * Get the current entry's details from the iteration state.
+     * @param hi The iteration state
+     * @param key Return pointer for the pointer to the key.
+     * @param klen Return pointer for the key length.
+     * @param val Return pointer for the associated value.
+     * @remark The return pointers should point to a variable that will be set to the
+     *         corresponding data, or they may be NULL if the data isn't interesting.
+     */
+    AXIS2_EXTERN void AXIS2_CALL 
+    axis2_hash_this(axis2_hash_index_t *hi, 
+        const void **key,
+        axis2_ssize_t *klen, 
+        void **val);
+
+    /**
+     * Get the number of key/value pairs in the hash table.
+     * @param ht The hash table
+     * @return The number of key/value pairs in the hash table.
+     */
+    AXIS2_EXTERN  unsigned int AXIS2_CALL 
+    axis2_hash_count(axis2_hash_t *ht);
+
+    /**
+     * Merge two hash tables into one new hash table. The values of the overlay
+     * hash override the values of the base if both have the same key.  Both
+     * hash tables must use the same hash function.
+     * @param overlay The table to add to the initial table
+     * @param p The environment to use for the new hash table
+     * @param base The table that represents the initial values of the new table
+     * @return A new hash table containing all of the data from the two passed in
+     */
+    AXIS2_EXTERN axis2_hash_t* AXIS2_CALL 
+    axis2_hash_overlay(const axis2_hash_t *overlay,
+        const axis2_env_t *env, 
+        const axis2_hash_t *base);
+
+    /**
+     * Merge two hash tables into one new hash table. If the same key
+     * is present in both tables, call the supplied merge function to
+     * produce a merged value for the key in the new table.  Both
+     * hash tables must use the same hash function.
+     * @param h1 The first of the tables to merge
+     * @param p The environment to use for the new hash table
+     * @param h2 The second of the tables to merge
+     * @param merger A callback function to merge values, or NULL to
+     *  make values from h1 override values from h2 (same semantics as
+     *  axis2_hash_overlay())
+     * @param data Client data to pass to the merger function
+     * @return A new hash table containing all of the data from the two passed in
+     */
+    AXIS2_EXTERN axis2_hash_t* AXIS2_CALL 
+    axis2_hash_merge(const axis2_hash_t *h1,
+        const axis2_env_t *env, 
+        const axis2_hash_t *h2,
+        void *(*merger)(const axis2_env_t *env, 
+            const void *key,
+            axis2_ssize_t klen, 
+            const void *h1_val, 
+            const void *h2_val,
+            const void *data), 
+        const void *data);
+
+    /**
+     * Query whether the hash table provided as parameter contains the
+     * key provided as parameter.
+     *
+     * @param ht hash table to be queried for key
+     * @return return whether hash table contains key
+     */
+    AXIS2_EXTERN axis2_bool_t AXIS2_CALL
+    axis2_hash_contains_key(axis2_hash_t *ht,
         const axis2_env_t *env,
         const axis2_char_t *key);
-                           
-/**
- * @param ht hash table to be freed
- * @param env The environment to use for hash table
- * @return return status code 
- *
- */
-                           
-AXIS2_EXTERN axis2_status_t AXIS2_CALL axis2_hash_free(axis2_hash_t *ht
-      , const axis2_env_t *env);
-                           
-/**
- * Free a hash table with hash table given as void
- * @param ht hash table to be freed as a void *
- * @param env The environment to use for hash table
- * @return return status code
- */
 
-AXIS2_EXTERN axis2_status_t AXIS2_CALL
-axis2_hash_free_void_arg (void *ht_void, const axis2_env_t* env);
+    /**
+     * @param ht hash table to be freed
+     * @param env The environment to use for hash table
+     * @return return status code
+     *
+     */
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL 
+    axis2_hash_free(axis2_hash_t *ht,
+        const axis2_env_t *env);
+
+    /**
+     * Free a hash table with hash table given as void
+     * @param ht hash table to be freed as a void *
+     * @param env The environment to use for hash table
+     * @return return status code
+     */
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_hash_free_void_arg(void *ht_void, 
+        const axis2_env_t* env);
 
-/** @} */
+    /** @} */
 
 #ifdef __cplusplus
 }
 #endif
 
 #endif                          /* !AXIS2_HASH_H */
+
+

Modified: webservices/axis2/trunk/c/util/include/axis2_linked_list.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axis2_linked_list.h?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/util/include/axis2_linked_list.h (original)
+++ webservices/axis2/trunk/c/util/include/axis2_linked_list.h Sun Jan  7 19:10:29 2007
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
- 
+
 #ifndef AXIS2_LINKED_LIST_H
 #define AXIS2_LINKED_LIST_H
 
@@ -31,41 +31,41 @@
 {
 #endif
 
-typedef struct axis2_linked_list_s axis2_linked_list_t;
-typedef struct axis2_linked_list_ops_s axis2_linked_list_ops_t;
-    
-/**
- * @defgroup axis2_linked_list linked list
- * @ingroup axis2_util
- * @{
- */
+    typedef struct axis2_linked_list axis2_linked_list_t;
 
-/**
- * Struct to represent an entry in the list. Holds a single element.
- */
- typedef struct entry_s
-{
-    /** The element in the list. */
-    void *data;
-    
-    /** The next list entry, null if this is last. */
-    struct entry_s *next;
-    
-    /** The previous list entry, null if this is first. */
-    struct entry_s *previous;
-    
-} entry_t; /* struct entry */
+    /**
+     * @defgroup axis2_linked_list linked list
+     * @ingroup axis2_util
+     * @{
+     */
+
+    /**
+     * Struct to represent an entry in the list. Holds a single element.
+     */
+    typedef struct entry_s
+    {
+        /** The element in the list. */
+        void *data;
+
+        /** The next list entry, null if this is last. */
+        struct entry_s *next;
+
+        /** The previous list entry, null if this is first. */
+        struct entry_s *previous;
+
+    }
+    entry_t; /* struct entry */
+
+    /**
+    * Create an empty linked list.
+    */
+    AXIS2_EXTERN axis2_linked_list_t* AXIS2_CALL 
+    axis2_linked_list_create(const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_linked_list_free(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env);
 
-/**
-*   \brief Linked List ops struct
-*/
- struct axis2_linked_list_ops_s
-{
-    
-    axis2_status_t (AXIS2_CALL *
-    free) (axis2_linked_list_t *linked_list, 
-            const axis2_env_t *env);
-    
     /**
     * Obtain the Entry at a given position in a list. This method of course
     * takes linear time, but it is intelligent enough to take the shorter of the
@@ -78,99 +78,99 @@
     * @param n the number of the entry to get
     * @return the entry at position n
     */
-    entry_t * (AXIS2_CALL *
-    get_entry)(axis2_linked_list_t *linked_list, 
-                                const axis2_env_t *env, 
-                                int n);
-                                            
+    AXIS2_EXTERN entry_t * AXIS2_CALL
+    axis2_linked_list_get_entry(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        int n);
+
     /**
      * Remove an entry from the list. This will adjust size and deal with
      *  `first' and  `last' appropriatly.
      *
      * @param e the entry to remove
      */
-    axis2_status_t (AXIS2_CALL *
-    remove_entry)(axis2_linked_list_t *linked_list, 
-                                    const axis2_env_t *env, 
-                                    entry_t *e);
-            
-    
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_linked_list_remove_entry(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        entry_t *e);
+
+
     /**
      * Checks that the index is in the range of possible elements (inclusive).
      *
      * @param index the index to check
      */
-    axis2_bool_t (AXIS2_CALL *
-    check_bounds_inclusive)(axis2_linked_list_t *linked_list, 
-                                                const axis2_env_t *env, 
-                                                int index);
-    
+    AXIS2_EXTERN axis2_bool_t AXIS2_CALL
+    axis2_linked_list_check_bounds_inclusive(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        int index);
+
     /**
     * Checks that the index is in the range of existing elements (exclusive).
     *
     * @param index the index to check
     */
-    axis2_bool_t (AXIS2_CALL *
-    check_bounds_exclusive)(axis2_linked_list_t *linked_list,
-                                                const axis2_env_t *env,
-                                                int index);
-    
+    AXIS2_EXTERN axis2_bool_t AXIS2_CALL
+    axis2_linked_list_check_bounds_exclusive(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        int index);
+
     /**
     * Returns the first element in the list.
     *
     * @return the first list element
     */
-    void * (AXIS2_CALL *
-    get_first)(axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env);
-                                
+    AXIS2_EXTERN void * AXIS2_CALL
+    axis2_linked_list_get_first(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env);
+
     /**
     * Returns the last element in the list.
     *
     * @return the last list element
     */
-    void * (AXIS2_CALL *
-    get_last)(axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env);
-    
+    AXIS2_EXTERN void * AXIS2_CALL
+    axis2_linked_list_get_last(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env);
+
     /**
     * Remove and return the first element in the list.
     *
     * @return the former first element in the list
     */
-    void * (AXIS2_CALL *
-    remove_first)(axis2_linked_list_t *linked_list,
-                                    const axis2_env_t *env);
-                                    
+    AXIS2_EXTERN void * AXIS2_CALL
+    axis2_linked_list_remove_first(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env);
+
     /**
     * Remove and return the last element in the list.
     *
     * @return the former last element in the list
     */
-    void * (AXIS2_CALL *
-    remove_last)(axis2_linked_list_t *linked_list,
-                                    const axis2_env_t *env);
-    
+    AXIS2_EXTERN void * AXIS2_CALL
+    axis2_linked_list_remove_last(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env);
+
     /**
     * Insert an element at the first of the list.
     *
     * @param o the element to insert
     */
-    axis2_status_t (AXIS2_CALL *
-    add_first) (axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env,
-                                void *o);
-                                
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_linked_list_add_first(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        void *o);
+
     /**
     * Insert an element at the last of the list.
     *
     * @param o the element to insert
     */
-    axis2_status_t (AXIS2_CALL *
-    add_last) (axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env,
-                                void *o);
-                    
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_linked_list_add_last(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        void *o);
+
     /**
     * Returns true if the list contains the given object. Comparison is done by
     * <code>o == null ? e = null : o.equals(e)</code>.
@@ -178,31 +178,31 @@
     * @param o the element to look for
     * @return true if it is found
     */
-    axis2_bool_t (AXIS2_CALL *
-    contains) (axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env,
-                                void *o);
-    
+    AXIS2_EXTERN axis2_bool_t AXIS2_CALL
+    axis2_linked_list_contains(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        void *o);
+
     /**
     * Returns the size of the list.
     *
     * @return the list size
     */
-    int (AXIS2_CALL *
-    size) (axis2_linked_list_t *linked_list,
-                            const axis2_env_t *env);
-                            
+    AXIS2_EXTERN int AXIS2_CALL
+    axis2_linked_list_size(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env);
+
     /**
     * Adds an element to the end of the list.
     *
     * @param e the entry to add
     * @return true, as it always succeeds
     */
-    axis2_bool_t (AXIS2_CALL *
-    add) (axis2_linked_list_t *linked_list, 
-                            const axis2_env_t *env,
-                            void *o);
-    
+    AXIS2_EXTERN axis2_bool_t AXIS2_CALL
+    axis2_linked_list_add(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        void *o);
+
     /**
     * Removes the entry at the lowest index in the list that matches the given
     * object, comparing by <code>o == null ? e = null : o.equals(e)</code>.
@@ -210,29 +210,29 @@
     * @param o the object to remove
     * @return true if an instance of the object was removed
     */
-    axis2_bool_t (AXIS2_CALL *
-    remove) (axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env,
-                                void *o);
-                                
+    AXIS2_EXTERN axis2_bool_t AXIS2_CALL
+    axis2_linked_list_remove(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        void *o);
+
     /**
     * Remove all elements from this list.
     */
-    axis2_status_t (AXIS2_CALL *
-    clear) (axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env);
-    
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_linked_list_clear(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env);
+
     /**
     * Return the element at index.
     *
     * @param index the place to look
     * @return the element at index
     */
-    void * (AXIS2_CALL *
-    get) (axis2_linked_list_t *linked_list,
-                            const axis2_env_t *env,
-                            int index);
-                            
+    AXIS2_EXTERN void * AXIS2_CALL
+    axis2_linked_list_get(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        int index);
+
     /**
     * Replace the element at the given location in the list.
     *
@@ -240,153 +240,138 @@
     * @param o the new element
     * @return the prior element
     */
-    void * (AXIS2_CALL *
-    set) (axis2_linked_list_t *linked_list,
-                            const axis2_env_t *env,
-                            int index, void *o);
-    
+    AXIS2_EXTERN void * AXIS2_CALL
+    axis2_linked_list_set(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        int index, 
+        void *o);
+
     /**
     * Inserts an element in the given position in the list.
     *
     * @param index where to insert the element
     * @param o the element to insert
     */
-    axis2_status_t (AXIS2_CALL *
-    add_at_index) (axis2_linked_list_t *linked_list,
-                            const axis2_env_t *env,
-                            int index, 
-                            void *o);
-                            
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_linked_list_add_at_index(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        int index,
+        void *o);
+
     /**
     * Removes the element at the given position from the list.
     *
     * @param index the location of the element to remove
     * @return the removed element
     */
-    void * (AXIS2_CALL *
-    remove_at_index) (axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env,
-                                int index);
-    
+    AXIS2_EXTERN void * AXIS2_CALL
+    axis2_linked_list_remove_at_index(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        int index);
+
     /**
     * Returns the first index where the element is located in the list, or -1.
     *
     * @param o the element to look for
     * @return its position, or -1 if not found
     */
-    int (AXIS2_CALL *
-    index_of)(axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env,
-                                void *o);
-                                
+    AXIS2_EXTERN int AXIS2_CALL
+    axis2_linked_list_index_of(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        void *o);
+
     /**
     * Returns the last index where the element is located in the list, or -1.
     *
     * @param o the element to look for
     * @return its position, or -1 if not found
     */
-    int (AXIS2_CALL *
-    last_index_of) (axis2_linked_list_t *linked_list,
-                                    const axis2_env_t *env,
-                                    void *o);
-    
+    AXIS2_EXTERN int AXIS2_CALL
+    axis2_linked_list_last_index_of(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env,
+        void *o);
+
     /**
     * Returns an array which contains the elements of the list in order.
     *
     * @return an array containing the list elements
     */
-    void ** (AXIS2_CALL *
-    to_array) (axis2_linked_list_t *linked_list,
-                                const axis2_env_t *env);
-
-};
-
-/** 
-* @brief Linked List struct
-*/
- 
-struct axis2_linked_list_s
-{
-    /** Linked List related ops */
-    axis2_linked_list_ops_t *ops;
-};
+    AXIS2_EXTERN void ** AXIS2_CALL
+    axis2_linked_list_to_array(axis2_linked_list_t *linked_list,
+        const axis2_env_t *env);
+
 
-/**
-* Create an empty linked list.
-*/
-AXIS2_EXTERN axis2_linked_list_t* AXIS2_CALL axis2_linked_list_create(const axis2_env_t *env);    
-    
 #define AXIS2_LINKED_LIST_FREE(linked_list, env) \
-        ((linked_list)->ops->free(linked_list, env))
+        axis2_linked_list_free(linked_list, env)
 
 #define AXIS2_LINKED_LIST_GET_ENTRY(linked_list, env, n) \
-        ((linked_list)->ops->get_entry(linked_list, env, n))
+        axis2_linked_list_get_entry(linked_list, env, n)
 
 #define AXIS2_LINKED_LIST_REMOVE_ENTRY(linked_list, env, e) \
-        ((linked_list)->ops->remove_entry(linked_list, env, e))
+        axis2_linked_list_remove_entry(linked_list, env, e)
 
 #define AXIS2_LINKED_LIST_CHECK_BOUNDS_INCLUSIVE(linked_list, env, index) \
-        ((linked_list)->ops->check_bounds_inclusive(linked_list, env, index))
+        axis2_linked_list_check_bounds_inclusive(linked_list, env, index)
 
 #define AXIS2_LINKED_LIST_CHECK_BOUNDS_EXCLUSIVE(linked_list, env, index) \
-        ((linked_list)->ops->check_bounds_exclusive(linked_list, env, index))
+        axis2_linked_list_check_bounds_exclusive(linked_list, env, index)
 
 #define AXIS2_LINKED_LIST_GET_FIRST(linked_list, env) \
-        ((linked_list)->ops->get_first(linked_list, env))    
-        
+        axis2_linked_list_get_first(linked_list, env)
+
 #define AXIS2_LINKED_LIST_GET_LAST(linked_list, env) \
-        ((linked_list)->ops->get_last(linked_list, env))
-        
+        axis2_linked_list_get_last(linked_list, env)
+
 #define AXIS2_LINKED_LIST_REMOVE_FIRST(linked_list, env) \
-        ((linked_list)->ops->remove_first(linked_list, env))
-        
+        axis2_linked_list_remove_first(linked_list, env)
+
 #define AXIS2_LINKED_LIST_REMOVE_LAST(linked_list, env) \
-        ((linked_list)->ops->remove_last(linked_list, env))
+        axis2_linked_list_remove_last(linked_list, env)
 
 #define AXIS2_LINKED_LIST_ADD_FIRST(linked_list, env, o) \
-        ((linked_list)->ops->add_first(linked_list, env, o))
+        axis2_linked_list_add_first(linked_list, env, o)
 
 #define AXIS2_LINKED_LIST_ADD_LAST(linked_list, env, o) \
-        ((linked_list)->ops->add_last(linked_list, env, o))
+        axis2_linked_list_add_last(linked_list, env, o)
 
 #define AXIS2_LINKED_LIST_CONTAINS(linked_list, env, o) \
-        ((linked_list)->ops->contains(linked_list, env, o))
+        axis2_linked_list_contains(linked_list, env, o)
 
 #define AXIS2_LINKED_LIST_SIZE(linked_list, env) \
-        ((linked_list)->ops->size(linked_list, env))
+        axis2_linked_list_size(linked_list, env)
 
 #define AXIS2_LINKED_LIST_ADD(linked_list, env, o) \
-        ((linked_list)->ops->add(linked_list, env, o))
+        axis2_linked_list_add(linked_list, env, o)
 
 #define AXIS2_LINKED_LIST_REMOVE(linked_list, env, o) \
-        ((linked_list)->ops->remove(linked_list, env, o))
+        axis2_linked_list_remove(linked_list, env, o)
 
 #define AXIS2_LINKED_LIST_CLEAR(linked_list, env) \
-        ((linked_list)->ops->clear(linked_list, env, index))
+        axis2_linked_list_clear(linked_list, env, index)
 
 #define AXIS2_LINKED_LIST_GET(linked_list, env, index) \
-        ((linked_list)->ops->get(linked_list, env, index))
+        axis2_linked_list_get(linked_list, env, index)
 
 #define AXIS2_LINKED_LIST_SET(linked_list, env, index, o) \
-        ((linked_list)->ops->set(linked_list, env, index, o))
+        axis2_linked_list_set(linked_list, env, index, o)
 
 #define AXIS2_LINKED_LIST_ADD_AT_INDEX(linked_list, env, index, o) \
-        ((linked_list)->ops->add_at_index(linked_list, env, index, o))
+        axis2_linked_list_add_at_index(linked_list, env, index, o)
 
 #define AXIS2_LINKED_LIST_REMOVE_AT_INDEX(linked_list, env, index) \
-        ((linked_list)->ops->remove_at_index(linked_list, env, index))
+        axis2_linked_list_remove_at_index(linked_list, env, index)
 
 #define AXIS2_LINKED_LIST_INDEX_OF(linked_list, env, o) \
-        ((linked_list)->ops->index_of(linked_list, env, o))
+        axis2_linked_list_index_of(linked_list, env, o)
 
 #define AXIS2_LINKED_LIST_LAST_INDEX_OF(linked_list, env, o) \
-        ((linked_list)->ops->last_index_of(linked_list, env, o))
+        axis2_linked_list_last_index_of(linked_list, env, o)
 
 #define AXIS2_LINKED_LIST_TO_ARRAY(linked_list, env) \
-        ((linked_list)->ops->to_array(linked_list, env))
+        axis2_linked_list_to_array(linked_list, env)
+
+    /** @} */
 
-/** @} */
-    
 #ifdef __cplusplus
 }
 #endif

Modified: webservices/axis2/trunk/c/util/include/axis2_log.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axis2_log.h?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/util/include/axis2_log.h (original)
+++ webservices/axis2/trunk/c/util/include/axis2_log.h Sun Jan  7 19:10:29 2007
@@ -26,34 +26,32 @@
 #endif
 
     typedef struct axis2_log_ops axis2_log_ops_t;
-	 typedef struct axis2_log axis2_log_t;
+    typedef struct axis2_log axis2_log_t;
 
 
 #define AXIS2_LOG_SI __FILE__,__LINE__
 
-/**
- * @defgroup axis2_log log
- * @ingroup axis2_util 
- * @{
- */
-
-/*TODO:log_xml*/
-
-   /**
-     *Examples
-     *To write debug information to log
-     *AXIS2_LOG_DEBUG(log,AXIS2_LOG_SI,"log this %s %d","test",123);
-     *This would log
-     *"log this test 123" into the log file
-     *
-     *similar macros are defined for different log levels: CRITICAL,ERROR,WARNING and INFO
-     *
-     *CRITICAL and ERROR logs are always written to file and other logs are written 
-     *depending on the log level set (log->level)
+    /**
+     * @defgroup axis2_log log
+     * @ingroup axis2_util
+     * @{
      */
-/** 
-  * \brief Axis2 log levels
-  */
+
+    /**
+      *Examples
+      *To write debug information to log
+      *AXIS2_LOG_DEBUG(log,AXIS2_LOG_SI,"log this %s %d","test",123);
+      *This would log
+      *"log this test 123" into the log file
+      *
+      *similar macros are defined for different log levels: CRITICAL,ERROR,WARNING and INFO
+      *
+      *CRITICAL and ERROR logs are always written to file and other logs are written 
+      *depending on the log level set (log->level)
+      */
+    /**
+      * \brief Axis2 log levels
+      */
     typedef enum axis2_log_levels
     {
         /** Critical level, logs only critical errors */
@@ -70,52 +68,46 @@
         AXIS2_LOG_LEVEL_TRACE
     } axis2_log_levels_t;
 
-
-
-
-
-
-
-  /** 
-    * \brief Axis2 log ops struct
-    *
-    * Encapsulator struct for ops of axis2_log
-    */
+    /**
+      * \brief Axis2 log ops struct
+      *
+      * Encapsulator struct for ops of axis2_log
+      */
     struct axis2_log_ops
     {
-    
-      /**
-       * deletes the log
-       * @return axis2_status_t AXIS2_SUCCESS on success else AXIS2_FAILURE
-       */
 
-       void (AXIS2_CALL *
-      free) (axis2_allocator_t *allocator, 
+        /**
+         * deletes the log
+         * @return axis2_status_t AXIS2_SUCCESS on success else AXIS2_FAILURE
+         */
+
+        void(AXIS2_CALL *
+        free)(axis2_allocator_t *allocator,
             struct axis2_log *log);
 
-      /**
-        * writes to the log
-        * @param buffer buffer to be written to log
-        * @param size size of the buffer to be written to log
-        * @return satus of the op. AXIS2_SUCCESS on success else AXIS2_FAILURE
-        */
-        void (AXIS2_CALL *
-       write) (axis2_log_t *log, 
-             const axis2_char_t *buffer, 
-             axis2_log_levels_t level,
-             const axis2_char_t *file,
-             const int line);
+        /**
+          * writes to the log
+          * @param buffer buffer to be written to log
+          * @param size size of the buffer to be written to log
+          * @return satus of the op. AXIS2_SUCCESS on success else AXIS2_FAILURE
+          */
+        void(AXIS2_CALL *
+        write)(axis2_log_t *log,
+            const axis2_char_t *buffer,
+            axis2_log_levels_t level,
+            const axis2_char_t *file,
+            const int line);
     };
 
-  /** 
-    * \brief Axis2 Log struct
-    *
-    * Log is the encapsulating struct for all log related data and ops
-    */
+    /**
+      * \brief Axis2 Log struct
+      *
+      * Log is the encapsulating struct for all log related data and ops
+      */
     struct axis2_log
     {
         /** Log related ops */
-        struct axis2_log_ops *ops;
+        const axis2_log_ops_t *ops;
         /** Log level */
         axis2_log_levels_t level;
         /** Is logging enabled? */
@@ -123,39 +115,39 @@
 
     };
 
-AXIS2_EXTERN void AXIS2_CALL 
-axis2_log_impl_log_critical(axis2_log_t *log, 
-                      const axis2_char_t *filename, 
-                     const int linenumber,
-                     const axis2_char_t *format,...);
-
-AXIS2_EXTERN void AXIS2_CALL 
-axis2_log_impl_log_error(axis2_log_t *log,
-                   const axis2_char_t *filename,
-                   const int linenumber,
-                   const axis2_char_t *format,...);
-
-AXIS2_EXTERN void AXIS2_CALL 
-axis2_log_impl_log_warning(axis2_log_t *log,
-                     const axis2_char_t *filename,
-                          const int linenumber,
-                          const axis2_char_t *format,...);
-
-AXIS2_EXTERN void AXIS2_CALL 
-axis2_log_impl_log_info(axis2_log_t *log, 
-                  const axis2_char_t *format,...);
-
-AXIS2_EXTERN void AXIS2_CALL 
-axis2_log_impl_log_debug(axis2_log_t *log,
-                   const axis2_char_t *filename,
-                   const int linenumber,
-                   const axis2_char_t *format,...);
-
-AXIS2_EXTERN void AXIS2_CALL 
-axis2_log_impl_log_trace(axis2_log_t *log,
-                         const axis2_char_t *filename,
-                   const int linenumber,
-                   const axis2_char_t *format,...);
+    AXIS2_EXTERN void AXIS2_CALL
+    axis2_log_impl_log_critical(axis2_log_t *log,
+            const axis2_char_t *filename,
+            const int linenumber,
+            const axis2_char_t *format, ...);
+
+    AXIS2_EXTERN void AXIS2_CALL
+    axis2_log_impl_log_error(axis2_log_t *log,
+            const axis2_char_t *filename,
+            const int linenumber,
+            const axis2_char_t *format, ...);
+
+    AXIS2_EXTERN void AXIS2_CALL
+    axis2_log_impl_log_warning(axis2_log_t *log,
+            const axis2_char_t *filename,
+            const int linenumber,
+            const axis2_char_t *format, ...);
+
+    AXIS2_EXTERN void AXIS2_CALL
+    axis2_log_impl_log_info(axis2_log_t *log,
+            const axis2_char_t *format, ...);
+
+    AXIS2_EXTERN void AXIS2_CALL
+    axis2_log_impl_log_debug(axis2_log_t *log,
+            const axis2_char_t *filename,
+            const int linenumber,
+            const axis2_char_t *format, ...);
+
+    AXIS2_EXTERN void AXIS2_CALL
+    axis2_log_impl_log_trace(axis2_log_t *log,
+            const axis2_char_t *filename,
+            const int linenumber,
+            const axis2_char_t *format, ...);
 
 #define AXIS2_LOG_FREE(allocator, log) \
       ((log->ops)->free(allocator, log))
@@ -163,11 +155,11 @@
 #define AXIS2_LOG_WRITE(log, buffer, level) \
       ((log)->ops->write(log, buffer, level,AXIS2_LOG_SI))
 
-#define AXIS2_LOG_DEBUG axis2_log_impl_log_debug 
-#define AXIS2_LOG_INFO axis2_log_impl_log_info 
-#define AXIS2_LOG_WARNING axis2_log_impl_log_warning 
-#define AXIS2_LOG_ERROR axis2_log_impl_log_error 
-#define AXIS2_LOG_CRITICAL axis2_log_impl_log_critical 
+#define AXIS2_LOG_DEBUG axis2_log_impl_log_debug
+#define AXIS2_LOG_INFO axis2_log_impl_log_info
+#define AXIS2_LOG_WARNING axis2_log_impl_log_warning
+#define AXIS2_LOG_ERROR axis2_log_impl_log_error
+#define AXIS2_LOG_CRITICAL axis2_log_impl_log_critical
 
 #ifdef AXIS2_TRACE
 #define AXIS2_LOG_TRACE axis2_log_impl_log_trace
@@ -185,8 +177,8 @@
 # endif
 #endif
 
-/** @} */
-    
+    /** @} */
+
 #ifdef __cplusplus
 }
 #endif

Modified: webservices/axis2/trunk/c/util/include/axis2_network_handler.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axis2_network_handler.h?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/util/include/axis2_network_handler.h (original)
+++ webservices/axis2/trunk/c/util/include/axis2_network_handler.h Sun Jan  7 19:10:29 2007
@@ -31,72 +31,72 @@
 #endif
 
 
-/**
- * @defgroup axis2_network_handler network handler
- * @ingroup axis2_util 
- * @{
- */
-
-/**
- * open a socket for a given server
- * @param server ip address or the fqn of the server
- * @param port port of the service
- * @return opened socket
- */ 
-AXIS2_EXTERN axis2_socket_t AXIS2_CALL 
-axis2_network_handler_open_socket(const axis2_env_t *env, 
-                          char *server, 
-                          int port);
-
-/**
- * creates a server socket for a given port
- * @param port port of the socket to be bound
- * @return creates server socket
- */ 
-AXIS2_EXTERN axis2_socket_t AXIS2_CALL 
-axis2_network_handler_create_server_socket(const axis2_env_t *env, 
-                                 int port);
-
-/**
- * closes a socket
- * @param opened socket that need to be closed
- * @return status code
- */
-AXIS2_EXTERN axis2_status_t AXIS2_CALL 
-axis2_network_handler_close_socket (const axis2_env_t *env, 
-                           axis2_socket_t socket);
-
-/**
- * used to set up socket options such as timeouts, non-blocking ..etc
- * @param socket valid socket (obtained by socket() or similar call)
- * @param option the name of the option
- * @param value Value to be set
- * @return status of the operations as axis2_status_t
- */
-AXIS2_EXTERN axis2_status_t AXIS2_CALL
-axis2_network_handler_set_sock_option(const axis2_env_t *env, 
-                             axis2_socket_t socket, 
-                             int option,
-                                int value);
-/**
- * Accepts remote connections for a server socket
- * @param socket valid server socket (obtained by socket() or similar call)
- * @return created socket to handle the incoming client connection
- */                  
-AXIS2_EXTERN axis2_socket_t AXIS2_CALL                  
-axis2_network_handler_svr_socket_accept(const axis2_env_t *env, 
-                              axis2_socket_t socket);
-
-/**
- * Returns the ip address of the server associated with the socket
- * @param socket valid socket (obtained by accept() or similar call)
- * @return ip address asoociated with the socket or NULL
- */
-AXIS2_EXTERN axis2_char_t * AXIS2_CALL
-axis2_network_handler_get_svr_ip(const axis2_env_t *env, 
-                         axis2_socket_t socket);
-/** @} */
-    
+    /**
+     * @defgroup axis2_network_handler network handler
+     * @ingroup axis2_util
+     * @{
+     */
+
+    /**
+     * open a socket for a given server
+     * @param server ip address or the fqn of the server
+     * @param port port of the service
+     * @return opened socket
+     */
+    AXIS2_EXTERN axis2_socket_t AXIS2_CALL
+    axis2_network_handler_open_socket(const axis2_env_t *env,
+            char *server,
+            int port);
+
+    /**
+     * creates a server socket for a given port
+     * @param port port of the socket to be bound
+     * @return creates server socket
+     */
+    AXIS2_EXTERN axis2_socket_t AXIS2_CALL
+    axis2_network_handler_create_server_socket(const axis2_env_t *env,
+            int port);
+
+    /**
+     * closes a socket
+     * @param opened socket that need to be closed
+     * @return status code
+     */
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_network_handler_close_socket(const axis2_env_t *env,
+            axis2_socket_t socket);
+
+    /**
+     * used to set up socket options such as timeouts, non-blocking ..etc
+     * @param socket valid socket (obtained by socket() or similar call)
+     * @param option the name of the option
+     * @param value Value to be set
+     * @return status of the operations as axis2_status_t
+     */
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_network_handler_set_sock_option(const axis2_env_t *env,
+            axis2_socket_t socket,
+            int option,
+            int value);
+    /**
+     * Accepts remote connections for a server socket
+     * @param socket valid server socket (obtained by socket() or similar call)
+     * @return created socket to handle the incoming client connection
+     */
+    AXIS2_EXTERN axis2_socket_t AXIS2_CALL
+    axis2_network_handler_svr_socket_accept(const axis2_env_t *env,
+            axis2_socket_t socket);
+
+    /**
+     * Returns the ip address of the server associated with the socket
+     * @param socket valid socket (obtained by accept() or similar call)
+     * @return ip address asoociated with the socket or NULL
+     */
+    AXIS2_EXTERN axis2_char_t * AXIS2_CALL
+    axis2_network_handler_get_svr_ip(const axis2_env_t *env,
+            axis2_socket_t socket);
+    /** @} */
+
 #ifdef __cplusplus
 }
 #endif

Modified: webservices/axis2/trunk/c/util/include/axis2_param.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axis2_param.h?view=diff&rev=493920&r1=493919&r2=493920
==============================================================================
--- webservices/axis2/trunk/c/util/include/axis2_param.h (original)
+++ webservices/axis2/trunk/c/util/include/axis2_param.h Sun Jan  7 19:10:29 2007
@@ -33,188 +33,174 @@
 {
 #endif
 
-struct axis2_param;
-struct axis2_param_ops;
 
-/**
- * @defgroup axis2_param parameter
- * @ingroup axis2_util
- * @{
- */
-    
-/**
-  * TEXT PARAM
-  */
-  static const int AXIS2_TEXT_PARAM = 0;
-
-/**
- * Field DOM_PARAM
- */
-  static const int AXIS2_DOM_PARAM = 1;
-       
-/**
- *   \brief param ops struct
- */
- typedef struct axis2_param_ops
-    {
-    
+    /**
+     * @defgroup axis2_param parameter
+     * @ingroup axis2_util
+     * @{
+     */
+
+    /**
+      * TEXT PARAM
+      */
+    static const int AXIS2_TEXT_PARAM = 0;
+
+    /**
+     * Field DOM_PARAM
+     */
+    static const int AXIS2_DOM_PARAM = 1;
+
+    typedef struct axis2_param axis2_param_t;
+
+    /**
+     * creates param struct
+     */
+    AXIS2_EXTERN axis2_param_t* AXIS2_CALL
+    axis2_param_create(const axis2_env_t *env,
+        axis2_char_t *name,
+        void *value);
+
     /**
      * Parameter name accessor
      * @return name of the param
      */
-    axis2_char_t* (AXIS2_CALL *
-   get_name)(struct axis2_param *param, 
-           const axis2_env_t *env);
+    AXIS2_EXTERN axis2_char_t* AXIS2_CALL
+    axis2_param_get_name(struct axis2_param *param,
+        const axis2_env_t *env);
 
     /**
      * Parameter value accessor
      * @return Object
      */
-    void* (AXIS2_CALL *
-   get_value)(struct axis2_param *param, 
-             const axis2_env_t *env);
+    AXIS2_EXTERN void* AXIS2_CALL
+    axis2_param_get_value(struct axis2_param *param,
+        const axis2_env_t *env);
 
     /**
      * param name mutator
      * @param name
      */
-     axis2_status_t (AXIS2_CALL *
-    set_name)(struct axis2_param *param, 
-             const axis2_env_t *env, 
-              const axis2_char_t *name);
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_param_set_name(struct axis2_param *param,
+        const axis2_env_t *env,
+        const axis2_char_t *name);
 
     /**
      * Method setValue
      *
      * @param value
      */
-     axis2_status_t (AXIS2_CALL *
-    set_value)(struct axis2_param *param, 
-             const axis2_env_t *env, 
-             const void *value);
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_param_set_value(struct axis2_param *param,
+        const axis2_env_t *env,
+        const void *value);
 
     /**
      * Method isLocked
      *
      * @return boolean
      */
-     axis2_bool_t (AXIS2_CALL *
-    is_locked)(struct axis2_param *param,
-              const axis2_env_t *env);
+    AXIS2_EXTERN axis2_bool_t AXIS2_CALL
+    axis2_param_is_locked(struct axis2_param *param,
+        const axis2_env_t *env);
 
     /**
      * Method setLocked
      *
      * @param value
      */
-     axis2_status_t (AXIS2_CALL *
-    set_locked)(struct axis2_param *param,
-             const axis2_env_t *env,
-             axis2_bool_t value);
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_param_set_locked(struct axis2_param *param,
+        const axis2_env_t *env,
+        axis2_bool_t value);
 
     /**
      * Method getParameterType
      *
      * @return int
      */
-     int (AXIS2_CALL *
-    get_param_type)(struct axis2_param *param, 
-                 const axis2_env_t *env);
-
-     axis2_status_t (AXIS2_CALL *
-    set_param_type)(struct axis2_param *param, 
-                 const axis2_env_t *env,
-                int type);
-
-     axis2_status_t (AXIS2_CALL *
-    free)(struct axis2_param *param, 
-          const axis2_env_t *env);
-
-    axis2_status_t (AXIS2_CALL *
-    set_attributes) (
-            struct axis2_param *param,
-            const axis2_env_t *env,
-            axis2_hash_t *attrs);
-
-    axis2_hash_t* (AXIS2_CALL *
-    get_attributes) (
-            struct axis2_param *param,
-            const axis2_env_t *env);
-         
-    axis2_status_t (AXIS2_CALL *
-    set_value_list) (
-            struct axis2_param *param,
-            const axis2_env_t *env,
-            axis2_array_list_t *value_list);
-
-    axis2_array_list_t* (AXIS2_CALL *
-    get_value_list) (
-            struct axis2_param *param,
-            const axis2_env_t *env);
-
-    axis2_status_t (AXIS2_CALL *
-    value_free) (void *param_value, 
-                 const axis2_env_t *env);
-}axis2_param_ops_t;
- 
-/** 
- * \brief Parameter struct
- */
-typedef struct axis2_param
-{
-   /** Parameter related ops */
-   axis2_param_ops_t *ops;
-}axis2_param_t;
-
-/**
- * creates param struct
- */
-AXIS2_EXTERN axis2_param_t* AXIS2_CALL 
-axis2_param_create(const axis2_env_t *env, 
-                  axis2_char_t *name, 
-                  void *value);
+    AXIS2_EXTERN int AXIS2_CALL
+    axis2_param_get_param_type(struct axis2_param *param,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_param_set_param_type(struct axis2_param *param,
+        const axis2_env_t *env,
+        int type);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_param_free(struct axis2_param *param,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_param_set_attributes(struct axis2_param *param,
+        const axis2_env_t *env,
+        axis2_hash_t *attrs);
+
+    AXIS2_EXTERN axis2_hash_t* AXIS2_CALL
+    axis2_param_get_attributes(struct axis2_param *param,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_param_set_value_list(struct axis2_param *param,
+        const axis2_env_t *env,
+        axis2_array_list_t *value_list);
+
+    AXIS2_EXTERN axis2_array_list_t* AXIS2_CALL
+    axis2_param_get_value_list(struct axis2_param *param,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_param_value_free(void *param_value,
+        const axis2_env_t *env);
+
+    AXIS2_EXTERN axis2_status_t AXIS2_CALL
+    axis2_param_set_value_free(struct axis2_param *param,
+        const axis2_env_t *env,
+        void *free_fn);
+
 
 #define AXIS2_PARAM_FREE(param, env) \
-    ((param)->ops->free (param, env))
+    axis2_param_free (param, env)
 
 #define AXIS2_PARAM_SET_NAME(param, env, name) \
-    ((param)->ops->set_name (param, env, name))
+    axis2_param_set_name (param, env, name)
 
 #define AXIS2_PARAM_GET_NAME(param, env) \
-    ((param)->ops->get_name (param, env))
+    axis2_param_get_name (param, env)
 
 #define AXIS2_PARAM_SET_VALUE(param, env, value) \
-    ((param)->ops->set_value (param , env, value))
+    axis2_param_set_value (param , env, value)
 
 #define AXIS2_PARAM_GET_VALUE(param, env) \
-    ((param)->ops->get_value (param, env))
+    axis2_param_get_value (param, env)
 
 #define AXIS2_PARAM_IS_LOCKED(param, env) \
-    ((param)->ops->is_locked (param, env))
+    axis2_param_is_locked (param, env)
 
 #define AXIS2_PARAM_SET_LOCKED(param, env, locked) \
-    ((param)->ops->set_locked (param, env, locked))
+    axis2_param_set_locked (param, env, locked)
 
 #define AXIS2_PARAM_SET_PARAM_TYPE(param, env, type) \
-    ((param)->ops->set_param_type (param, env, type))
- 
+    axis2_param_set_param_type (param, env, type)
+
 #define AXIS2_PARAM_GET_PARAM_TYPE(param, env) \
-    ((param)->ops->get_param_type (param, env))
-    
+    axis2_param_get_param_type (param, env)
+
 #define AXIS2_PARAM_SET_ATTRIBUTES(param, env, attrs) \
-    ((param)->ops->set_attributes (param , env, attrs))
+    axis2_param_set_attributes (param , env, attrs)
 
 #define AXIS2_PARAM_GET_ATTRIBUTES(param, env) \
-    ((param)->ops->get_attributes (param, env))
-       
+    axis2_param_get_attributes (param, env)
+
 #define AXIS2_PARAM_SET_VALUE_LIST(param, env, value_list) \
-    ((param)->ops->set_value_list (param , env, value_list))
+    axis2_param_set_value_list (param , env, value_list)
 
 #define AXIS2_PARAM_GET_VALUE_LIST(param, env) \
-    ((param)->ops->get_value_list (param, env))
-   
-/** @} */
-    
+    axis2_param_get_value_list (param, env)
+
+    /** @} */
+
 #ifdef __cplusplus
 }
 #endif



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