[jira] [Commented] (AXIS2-5978) provide better error message on error with trailing spaces

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Commented] (AXIS2-5978) provide better error message on error with trailing spaces

Adam Fordham (Jira)

    [ https://issues.apache.org/jira/browse/AXIS2-5978?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17013571#comment-17013571 ]

Robert Lazarski commented on AXIS2-5978:
----------------------------------------

I added the suggested fix in AXIS2-5575 , if you would like to see further work done here as suggested please consider submitting a patch.

> provide better error message on error with trailing spaces
> ----------------------------------------------------------
>
>                 Key: AXIS2-5978
>                 URL: https://issues.apache.org/jira/browse/AXIS2-5978
>             Project: Axis2
>          Issue Type: Improvement
>          Components: databinding
>    Affects Versions: 1.7.8
>            Reporter: Ralf Hauser
>            Priority: Major
>
> When there is a trailing space, a useless error message is given via AxisFault.
> Assume you should have entered "a" in a field and happend to give "a ", you see
>  
> IllegalArgumentException " data=[a ]"
>  
> suggestions:
> 1) subclass IllegalArgumentException with 2 extra fields:
> a) the calling class name (generated for the xsd field by wsdl2java), must be handed over to  org.apache.axis2.databinding.utils.ConverterUtil.convertToToken() as a optional 2nd argument
> b) a reference to the explanation as per [https://www.w3.org/TR/xmlschema-2/#token]
>  should be set in org.apache.axis2.databinding.types.setValue() when
>     !Token.isValid(stValue)
>   
> see also AXIS2-5575



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]