You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by sa...@apache.org on 2005/10/13 12:19:07 UTC
svn commit: r320708 - in /webservices/axis2/trunk/c:
include/axis2_allocator.h include/axis2_om_namespace.h
include/axis2_string.h modules/util/src/axis2_allocator.c
modules/util/src/axis2_string.c
Author: samisa
Date: Thu Oct 13 03:18:52 2005
New Revision: 320708
URL: http://svn.apache.org/viewcvs?rev=320708&view=rev
Log:
Fixed the -O related macro naming problems
Modified:
webservices/axis2/trunk/c/include/axis2_allocator.h
webservices/axis2/trunk/c/include/axis2_om_namespace.h
webservices/axis2/trunk/c/include/axis2_string.h
webservices/axis2/trunk/c/modules/util/src/axis2_allocator.c
webservices/axis2/trunk/c/modules/util/src/axis2_string.c
Modified: webservices/axis2/trunk/c/include/axis2_allocator.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/axis2_allocator.h?rev=320708&r1=320707&r2=320708&view=diff
==============================================================================
--- webservices/axis2/trunk/c/include/axis2_allocator.h (original)
+++ webservices/axis2/trunk/c/include/axis2_allocator.h Thu Oct 13 03:18:52 2005
@@ -21,9 +21,9 @@
typedef struct axis2_allocator
{
- void *(*malloc)(size_t size);
- void *(*realloc)(void *ptr,size_t size);
- void (*free)(void *ptr);
+ void *(*axis2_allocator_malloc)(size_t size);
+ void *(*axis2_allocator_realloc)(void *ptr,size_t size);
+ void (*axis2_allocator_free)(void *ptr);
}axis2_allocator_t;
/**
@@ -36,8 +36,8 @@
axis2_allocator_t *
axis2_allocator_init(axis2_allocator_t *allocator);
-#define axis2_malloc(allocator, size) ((allocator)->malloc(size))
-#define axis2_realloc(allocator, ptr, size) ((allocator)->realloc(ptr, size))
-#define axis2_free(allocator, ptr) ((allocator)->free(ptr))
+#define axis2_malloc(allocator, size) ((allocator)->axis2_allocator_malloc(size))
+#define axis2_realloc(allocator, ptr, size) ((allocator)->axis2_allocator_realloc(ptr, size))
+#define axis2_free(allocator, ptr) ((allocator)->axis2_allocator_free(ptr))
#endif /* AXIS2_ALLOCATOR_H */
Modified: webservices/axis2/trunk/c/include/axis2_om_namespace.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/axis2_om_namespace.h?rev=320708&r1=320707&r2=320708&view=diff
==============================================================================
--- webservices/axis2/trunk/c/include/axis2_om_namespace.h (original)
+++ webservices/axis2/trunk/c/include/axis2_om_namespace.h Thu Oct 13 03:18:52 2005
@@ -22,6 +22,7 @@
* @brief defines axis2_om_namespace data structure, used for representing XML namespaces in OM
*/
+#include <axis2_defines.h>
#include <axis2_environment.h>
#include <axis2_om_output.h>
@@ -47,14 +48,14 @@
* @param om_namespace2 second namespace to be compared
* @return true if the two namespaces are equal, false otherwise
*/
- axis2_bool_t (*equals)(axis2_environment_t *environment, axis2_om_namespace_t *om_namespace1, axis2_om_namespace_t *om_namespace2);
+ axis2_bool_t (*equals)(axis2_environment_t *environment, struct axis2_om_namespace *om_namespace1, struct axis2_om_namespace *om_namespace2);
/**
* Serialize operation
* @param om_output OM output handler to be used in serializing
* @return Status code
*/
- axis2_status_t (*serialize)(axis2_environment_t *environment, axis2_om_namespace_t *om_namespace, axis2_om_output_t* om_output);
+ axis2_status_t (*serialize)(axis2_environment_t *environment, struct axis2_om_namespace *om_namespace, axis2_om_output_t* om_output);
} axis2_om_namespace_ops_t;
@@ -64,7 +65,17 @@
Handles the XML namespace in OM
*/
typedef struct axis2_om_namespace {
+ /**
+ * OM text related operations
+ */
+ axis2_om_namespace_ops_t* ops;
+ /**
+ * OM namespace URI
+ */
axis2_char_t *uri;
+ /**
+ * OM namespace prefix
+ */
axis2_char_t *prefix;
} axis2_om_namespace_t;
Modified: webservices/axis2/trunk/c/include/axis2_string.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/axis2_string.h?rev=320708&r1=320707&r2=320708&view=diff
==============================================================================
--- webservices/axis2/trunk/c/include/axis2_string.h (original)
+++ webservices/axis2/trunk/c/include/axis2_string.h Thu Oct 13 03:18:52 2005
@@ -22,8 +22,8 @@
typedef struct axis2_string
{
- void* (*strdup)(const void *ptr);
- int (*strcmp)(const axis2_char_t *s1, const axis2_char_t *s2);
+ void* (*axis2_string_strdup)(const void *ptr);
+ int (*axis2_string_strcmpa)(const axis2_char_t *s1, const axis2_char_t *s2);
}axis2_string_t;
/**
@@ -36,7 +36,7 @@
axis2_string_t *
axis2_string_create(axis2_allocator_t *allocator, axis2_string_t *string);
-#define axis2_strdup(string, ptr) ((string)->strdup(ptr))
-#define axis2_strcmp(string, s1, s2) ((string)->strcmp(s1, s2))
+#define axis2_strdup(string, ptr) ((string)->axis2_string_strdupa(ptr))
+#define axis2_strcmp(string, s1, s2) ((string)->axis2_string_strcmpa(s1, s2))
#endif /* AXIS2_STRING_H */
Modified: webservices/axis2/trunk/c/modules/util/src/axis2_allocator.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/util/src/axis2_allocator.c?rev=320708&r1=320707&r2=320708&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/util/src/axis2_allocator.c (original)
+++ webservices/axis2/trunk/c/modules/util/src/axis2_allocator.c Thu Oct 13 03:18:52 2005
@@ -29,9 +29,9 @@
allocator = (axis2_allocator_t*)malloc(sizeof(axis2_allocator_t));
if(allocator)
{
- allocator->malloc = malloc;
- allocator->realloc = realloc;
- allocator->free = free;
+ allocator->axis2_allocator_malloc = malloc;
+ allocator->axis2_allocator_realloc = realloc;
+ allocator->axis2_allocator_free = free;
return allocator;
}
}
Modified: webservices/axis2/trunk/c/modules/util/src/axis2_string.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/util/src/axis2_string.c?rev=320708&r1=320707&r2=320708&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/util/src/axis2_string.c (original)
+++ webservices/axis2/trunk/c/modules/util/src/axis2_string.c Thu Oct 13 03:18:52 2005
@@ -18,7 +18,7 @@
#include <stdlib.h>
#include <string.h>
-void* axis2_string_strdup(const void* ptr)
+void* axis2_string_ops_strdup(const void* ptr)
{
if (ptr)
return (void*)strdup(ptr);
@@ -26,7 +26,7 @@
return NULL;
}
-int axis2_string_strcmp(const axis2_char_t *s1, const axis2_char_t *s2)
+int axis2_string_ops_strcmp(const axis2_char_t *s1, const axis2_char_t *s2)
{
if (s1 && s2)
return strcmp(s1, s2);
@@ -48,8 +48,8 @@
string = (axis2_string_t*)axis2_malloc(allocator, sizeof(axis2_string_t));
if(string)
{
- string->strdup = axis2_string_strdup;
- string->strcmp = axis2_string_strcmp;
+ string->axis2_string_strdup = axis2_string_ops_strdup;
+ string->axis2_string_strcmp = axis2_string_ops_strcmp;
return string;
}
}