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 "David Kocher (JIRA)" <ax...@ws.apache.org> on 2005/07/01 15:53:57 UTC

[jira] Created: (AXIS-2099) Restriction on complex type not properly serialized

Restriction on complex type not properly serialized
---------------------------------------------------

         Key: AXIS-2099
         URL: http://issues.apache.org/jira/browse/AXIS-2099
     Project: Apache Axis
        Type: Bug
  Components: Basic Architecture  
    Versions: 1.2.1    
    Reporter: David Kocher
 Attachments: helloworld.tar.gz

Given a abstract complex type and a complex type with a restriction on this base type such as

    <xs:complexType name="BaseType" abstract="true" >
        <xs:sequence>
            <xs:element name="FirstName" type="xs:string" minOccurs="0" nillable="false"/>
            <xs:element name="LastName" type="xs:string"/>
        </xs:sequence>
    </xs:complexType>

    <xs:complexType name="RestrictionType">
        <xs:complexContent>
            <xs:restriction base="tns:BaseType">
                <xs:sequence>
                    <xs:element name="LastName" type="xs:string"/>
                </xs:sequence>
            </xs:restriction>
        </xs:complexContent>
    </xs:complexType>

This is serialized as 

              <Restriction>
                  <LastName>World</LastName>
                  <firstName xsi:nil="true"/>
               </Restriction>

which is not correct because only the last name is allowed in <Restriction> and the FirstName should be the first element and beginning with a capital anyway.

See the attached sample project.


-- 
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


[jira] Updated: (AXIS-2099) Restriction on complex type not properly serialized

Posted by "David Kocher (JIRA)" <ax...@ws.apache.org>.
     [ http://issues.apache.org/jira/browse/AXIS-2099?page=all ]

David Kocher updated AXIS-2099:
-------------------------------

    Attachment: helloworld.tar.gz

See the included build.xml to run the sample

> Restriction on complex type not properly serialized
> ---------------------------------------------------
>
>          Key: AXIS-2099
>          URL: http://issues.apache.org/jira/browse/AXIS-2099
>      Project: Apache Axis
>         Type: Bug
>   Components: Basic Architecture
>     Versions: 1.2.1
>     Reporter: David Kocher
>  Attachments: helloworld.tar.gz
>
> Given a abstract complex type and a complex type with a restriction on this base type such as
>     <xs:complexType name="BaseType" abstract="true" >
>         <xs:sequence>
>             <xs:element name="FirstName" type="xs:string" minOccurs="0" nillable="false"/>
>             <xs:element name="LastName" type="xs:string"/>
>         </xs:sequence>
>     </xs:complexType>
>     <xs:complexType name="RestrictionType">
>         <xs:complexContent>
>             <xs:restriction base="tns:BaseType">
>                 <xs:sequence>
>                     <xs:element name="LastName" type="xs:string"/>
>                 </xs:sequence>
>             </xs:restriction>
>         </xs:complexContent>
>     </xs:complexType>
> This is serialized as 
>               <Restriction>
>                   <LastName>World</LastName>
>                   <firstName xsi:nil="true"/>
>                </Restriction>
> which is not correct because only the last name is allowed in <Restriction> and the FirstName should be the first element and beginning with a capital anyway.
> See the attached sample project.

-- 
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