You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by "Damitha Kumarage (JIRA)" <ji...@apache.org> on 2006/07/28 13:00:14 UTC
[jira] Resolved: (AXIS2C-204) Extending the Error structure
[ http://issues.apache.org/jira/browse/AXIS2C-204?page=all ]
Damitha Kumarage resolved AXIS2C-204.
-------------------------------------
Resolution: Fixed
Assignee: Damitha Kumarage
This implementation is done. Still need to be tested in an actual module. When RM
is get to working state this can be tested.
> Extending the Error structure
> -----------------------------
>
> Key: AXIS2C-204
> URL: http://issues.apache.org/jira/browse/AXIS2C-204
> Project: Axis2-C
> Issue Type: Improvement
> Components: util
> Reporter: Damitha Kumarage
> Assigned To: Damitha Kumarage
>
> I would like to propose the following plan of extending the axis2 error in axis2 sub projects.
> In the sub projects error struct we will override all the functions of error structure except the
> get_message. Instead we will override the get_extended_message(which will be newly added to
> axis2_error struct), And inside get_extended_message we will call the get_message to get
> axis2 range error messages.
> For example in Sandesha2 project We can have
> const axis2_char_t * AXIS2_CALL
> sandesha2_error_impl_get_message (
> const axis2_error_t *error)
> {
> if (error && error->error_number >= AXIS2_ERROR_NONE && error->error_number
> < AXIS2_ERROR_LAST)
> {
> return AXIS2_ERROR_GET_MESSAGE(error);
> }
> else if(error && error->error_number >= SANDESHA2_ERROR_NONE && error->
> error_number < SANDESHA2_ERROR_LAST)
> {
> return sandesha2_error_messages[error->error_number];
> }
> return "Invalid Error Number";
> }
> And in the constructor we have(Removing unnecessary details)
> error = axis2_error_create(env);
> error->ops->get_extended_message = sandesha2_error_impl_get_message;
> error->ops->set_error_number = sandesha2_error_impl_set_error_number;
> error->ops->set_status_code = sandesha2_error_impl_set_status_code;
> error->ops->get_status_code = sandesha2_error_impl_get_status_code;
> error->ops->free = sandesha2_error_impl_free;
> I'll implement this if no object is raised
> thanks
> Damitha
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org