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 "Michael Mole (JIRA)" <ji...@apache.org> on 2007/11/20 16:25:43 UTC
[jira] Commented: (AXIS2C-730) using wsdl2c with -d adb option,
and element with minOccurs=0 results in lost nodes in the deserialize
method
[ https://issues.apache.org/jira/browse/AXIS2C-730?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12543919 ]
Michael Mole commented on AXIS2C-730:
-------------------------------------
I'm hitting the same problem also. Antonio, were you able to post your patch yet?
> using wsdl2c with -d adb option, and element with minOccurs=0 results in lost nodes in the deserialize method
> --------------------------------------------------------------------------------------------------------------
>
> Key: AXIS2C-730
> URL: https://issues.apache.org/jira/browse/AXIS2C-730
> Project: Axis2-C
> Issue Type: Bug
> Components: code generation
> Affects Versions: 1.1.0
> Environment: Windows
> Reporter: José Manuel Rubio
>
> I created stub using wsdl2c with -d adb option.
> Generated code does not take into account the fact that a node could be missing from the input. For example the following code is being generated:
> axis2_status_t AXIS2_CALL
> adb_ship_deserialize(
> adb_ship_t* _ship,
> const axutil_env_t *env,
> axiom_node_t* parent)
> {
> .
> .
> .
> if (current_node && axiom_node_get_data_element( current_node, env) && !axutil_strcmp("actualDraught",
> axiom_element_get_localname((axiom_element_t *)axiom_node_get_data_element( current_node, env), env))
> )
> {
> current_element = (axiom_element_t *)axiom_node_get_data_element( current_node, env);
> text_value = axiom_element_get_text(current_element, env, current_node );
>
> status = adb_ship_set_actualDraught( _ship, env,
> atof( text_value));
>
> if( AXIS2_FAILURE == status)
> {
> AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for actualDraught "
> " %d :: %s", env->error->error_number,
> AXIS2_ERROR_GET_MESSAGE(env->error));
> return AXIS2_FAILURE;
> }
> }
> if(current_node != NULL)
> {
> //Here it is asking for the next node even when the code above has not processed the current_node
> current_node = axiom_node_get_next_sibling( current_node, env);
> }
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org