You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by "Amila Chinthaka Suriarachchi (JIRA)" <ji...@apache.org> on 2007/11/13 11:57:50 UTC

[jira] Resolved: (AXIS2-3334) optional attributes are generated as required

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

Amila Chinthaka Suriarachchi resolved AXIS2-3334.
-------------------------------------------------

    Resolution: Fixed

now ADB does not use the getPullparser method. please have a look at with 
a nighly build

> optional attributes are generated as required
> ---------------------------------------------
>
>                 Key: AXIS2-3334
>                 URL: https://issues.apache.org/jira/browse/AXIS2-3334
>             Project: Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: adb
>    Affects Versions: 1.3
>         Environment: Windows XP, Java 1.4.2
>            Reporter: Antoni Alatalo
>            Assignee: Amila Chinthaka Suriarachchi
>
> Optional attributes are generated as requered in getPullParser method.
> For example:
> <attribute name="createdDate" type="dateTime">
> 			<annotation>
> 				<documentation>date of entity creation</documentation>
> 			</annotation>
> 		</attribute>
> Is generated (wsdl2java or XSD2java) as:
> attribList.add(new javax.xml.namespace.QName("", "createdDate"));
> 		attribList.add(org.apache.axis2.databinding.utils.ConverterUtil
> 				.convertToString(localCreatedDate));
> This is totally wrong. This causes NullPinterException at ConverUtil class row 107
> public static String convertToString(Calendar value) {
>         // lexical form of the calendar is '-'? yyyy '-' mm '-' dd 'T' hh ':' mm ':' ss ('.' s+)? (zzzzzz)?
>         SimpleDateFormat zulu = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'");
>         zulu.setTimeZone(TimeZone.getTimeZone("GMT"));
>         // Sun JDK bug http://developer.java.sun.com/developer/bugParade/bugs/4229798.html
> --> row 107        return zulu.format(value.getTime());
>     }
> There must be a code:
> if(attribute != null){
>     attribList.add(org.apache.axis2.databinding.utils.ConverterUtil
> 				.convertToString(localCreatedDate));
> }
> The same thing should be in all optional attributes!!!
> Regards
> Antoni

-- 
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-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org