[ http://issues.apache.org/jira/browse/TUSCANY-755?page=all ]

Fuhwei Lwo updated TUSCANY-755:
-------------------------------

    Attachment: AnyTypeTest.java
                anytype.xsd

I think the problem is coming from 
DataObjectXMLStreamReader.populateProperties() method. The line suspicious to 
me is 244 - if (type.getBaseTypes().contains(modelType))

I don't think the checking is correct. If I changed to "if (type != modelType)" 
then it works. However, I am not familiar with this code enough so please 
review it.  Thanks.

> XMLStreamHelper.saveObject() does not serialize xsi:type correctly
> ------------------------------------------------------------------
>
>                 Key: TUSCANY-755
>                 URL: http://issues.apache.org/jira/browse/TUSCANY-755
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SDO Implementation
>    Affects Versions: Java-M2
>            Reporter: Fuhwei Lwo
>         Attachments: anytype.xsd, AnyTypeTest.java
>
>
> In XSD, I define an element of xsd:anyType. Then I create an instance of 
> complexType called Person and set its value to the xsd:anyType element and 
> serialize it using XMLStreamHelper.saveObject(). Then I use 
> XMLStreamHelper.load() to transform the stream back to data object tree.  
> What I get is an AnyTypeDataObjectImpl instead of DynamicDataObjectImpl 
> representing the Person instance.
> This bug prevents the SCA users from using xsd:anyType for their services 
> with SDO data bindings because the services won't be able to return correct 
> SDO.
> I will attach a test case to demonstrate this problem.

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

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to