[ 
https://issues.apache.org/jira/browse/AXIS2-4447?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Amila Chinthaka Suriarachchi resolved AXIS2-4447.
-------------------------------------------------

    Resolution: Invalid

xsd:date has a defined string pattern so you can not change it. 

> Axis2 - ADB - xs:date tag conversion in stub throws RuntimeException - 
> ConverterUtil.convertToString() problem
> --------------------------------------------------------------------------------------------------------------
>
>                 Key: AXIS2-4447
>                 URL: https://issues.apache.org/jira/browse/AXIS2-4447
>             Project: Axis2
>          Issue Type: Bug
>          Components: adb
>    Affects Versions: 1.4.1
>         Environment: Windows XP - Workshop 10.3 - Axis2 1.4.1 - ADB Data 
> Binding 
>            Reporter: Andrea Pacini
>
> In a schema I have the following type:
> <xs:simpleType name="dateType">
>       <xs:restriction base="xs:date">
>               <xs:pattern value="\d{4}-\d{2}-\d{2}"/>
>       </xs:restriction>
> </xs:simpleType>
> When I generate the STUB (using Oracle Workshop 10.3 which points to an Axis2 
> 1.4.1 external installation), the generated stub (ADB Data Binding) has the 
> following source code :
> [...]
> public void setDateType(java.util.Date param){
>                             
>                                             if 
> (org.apache.axis2.databinding.utils.ConverterUtil.convertToString(param).matches("\\d{4}-\\d{2}-\\d{2}"))
>  {
>                                                 this.localDateType=param;
>                                             }
>                                             else {
>                                                 throw new 
> java.lang.RuntimeException();
>                                             }
>  }
> [...]
> This method always throws RuntimeException because the 
> ConverterUtil.convertToString() method returns a String in a different format 
> than "yyyy-mm-dd".

-- 
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: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to