axis-c-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nabeel Yoosuf" <>
Subject [Axis2] Message Receiver - Suggestions
Date Mon, 05 Jun 2006 05:08:38 GMT
>From the point of view of writing custom message receivers, I see the
following modifications to msg_recv would be appropriate.

1. axis2_xml_in_out_msg_recv.h can be (and should be) made private.
This file has only one function - creating the the msg_recv struct. This is
used only by the axis2_get_instance function which is in the same file where
the create function is implemented. Hence, the header should be made

2. svc_skeleton struct related functions can be moved out of msg_recv. The
msg_recv does not need to know anything about svc_skeleton.
The following functions in msg_recv are used only by

/* These two functions are not required to be in the msg_recv ops */
axis2_svc_skeleton_t * AXIS2_CALL
axis2_msg_recv_make_new_svc_obj(axis2_msg_recv_t *msg_recv,
                                    const axis2_env_t *env,
                                    struct axis2_msg_ctx *msg_ctx);

axis2_svc_skeleton_t * AXIS2_CALL
axis2_msg_recv_get_impl_obj(axis2_msg_recv_t *msg_recv,
                            const axis2_env_t *env,
                            struct axis2_msg_ctx *msg_ctx);

3.For the following function, the function pointer can be defined in
msg_recv ops and the impl lives
inside the extended msg receiver code (default impl does nothing).
axis2_status_t AXIS2_CALL
axis2_msg_recv_delete_svc_obj(axis2_msg_recv_t *msg_recv,
                                    const axis2_env_t *env,
                                    axis2_msg_ctx_t *msg_ctx);

With the above changes, anyone who extends the msg_recv needs to override
only the following in their create function.

msg_recv->ops->delete_svc_obj (default impl does nothing)
msg_recv->ops->receive (default impl points to msg_recv->ops->receive_sync)


View raw message