axis-c-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lilantha Darshana" <>
Subject RE: [Axis2] Suggestions to improve portability and pluggability
Date Mon, 10 Oct 2005 11:57:47 GMT
A way to go. 
Similar and a good reference can be found in JVM/JNI source code.

I'm wondering about why memory allocation functions need abstracting,
are there any known portability issues with them on any OS/Compiler
still does not support C89 std?


-----Original Message-----
From: Samisa Abeysinghe [] 
Sent: Sunday, October 09, 2005 6:46 PM
To: Apache AXIS C Developers List
Subject: Re: [Axis2] Suggestions to improve portability and pluggability

To detail the new approach a bit further, we would have an envioronment 
struct that would be passed around to all operations.
It looks like the following:
typedef struct axis2_environment {
    struct axis2_environment_ops *ops;
    axis2_allocator_t *allocator; // memory allocation routines
    axis2_error_t *error; // error handling
    axis2_stream_t *stream; // IO routines
    axis2_log_t *log; // logging routines
} axis2_environment_t;

The use of allocator and stream help us with abdtracting memory 
allocation and IO.

Log and error are used for handling the cross cutting issues of logging 
and error handling.


Samisa Abeysinghe wrote:

> Hi All,
>    We had the fortune of having a F2F chat with James Clark 
> ( last Friday, who suggested many improvements 
> in order to make the C code more portable and pluggable with other 
> libraries and platforms.
>    In line with suggestions by James, we came up with a design for 
> abstracting memory allocation, error handling and IO.
>    The initial code is in SVN (Please have a look at 
> modules/common/src/ and modules/common/test/)
> Thanks,
> Samisa...


This e-mail message is for the sole use of the intended recipient(s) and contains confidential
and/or privileged information belonging to Siebel Systems, Inc. or its customers or partners.
Any unauthorized review, use, copying, disclosure or distribution of this message is strictly
prohibited. If you are not an intended recipient of this message, please contact the sender
by reply e-mail and destroy all soft and hard copies of the message and any attachments. Thank
you for your cooperation.

View raw message