You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Frank Budinsky (JIRA)" <tu...@ws.apache.org> on 2007/11/21 20:19:43 UTC
[jira] Resolved: (TUSCANY-1915) Invalid namespace defined when
using QName
[ https://issues.apache.org/jira/browse/TUSCANY-1915?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Frank Budinsky resolved TUSCANY-1915.
-------------------------------------
Resolution: Fixed
Fixed in revision 597183.
I think the problem in this example is that the value being set isn't really a valid URI (i.e., URI is the SDO type corresponding to xsd:qname). If you set the value to something valid like this:
person1.set("Name", "http://www.example.org/Person#James");
then it serializes/deserializes fine.
For the case where there's no namespace provided:
person1.set("Name", "James");
I fixed it to simply leave the value unchanged.
> Invalid namespace defined when using QName
> ------------------------------------------
>
> Key: TUSCANY-1915
> URL: https://issues.apache.org/jira/browse/TUSCANY-1915
> Project: Tuscany
> Issue Type: Bug
> Components: Java SDO Implementation
> Affects Versions: Java-SDO-1.0, Java-SDO-Next
> Environment: WinXP - IBM Java 1.4.2
> Reporter: Chris Mildebrandt
> Priority: Blocker
> Attachments: Person.xsd, QNameTest.java
>
>
> When my schema defines an element of type QName, I get a name space of _ created. The resulting XML looks like this:
> <?xml version="1.0" encoding="ASCII"?>
> <person:Person xmlns:_="" xmlns:person="http://www.example.org/Person">
> <person:Name>_:James</person:Name>
> <person:Age>30</person:Age>
> </person:Person>
> Notice the xmlns:_="" and the _:James as the value of Name. The Name element has a type of QName. I'll attach my schema and code to this bug.
> In the code, I'm creating the data object, saving it to a string, loading it as an XMLDocument, then saving it again to the output stream. The load seems to be the culprit in this case. If I save it straight after creating it, it works fine.
> Let me know if you need any more information.
> Thanks,
> -Chris
--
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: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org