Editing xml from RNG schema with fixed attrib of type QName
This should cover W3C XML Schema, Relax NG and DTD related problems.
-
- Posts: 82
- Joined: Sat Jan 13, 2007 5:39 pm
- Location: Belgium
Editing xml from RNG schema with fixed attrib of type QName
Post by PaulHermans »
I have following example schema
Starting a fresh document leads to following instance:
Is there something wrong with the schema or ?
Paul
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<grammar
xmlns="http://relaxng.org/ns/structure/1.0"
xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
xmlns:overheid="test"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<start>
<element name="test" >
<attribute name="scheme">
<value type="QName">overheid:Gemeente</value>
</attribute>
</element>
</start>
</grammar>
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<?oxygen RNGSchema="file:/Users/Paul/Desktop/test.rng" type="xml"?>
<test scheme="com.thaiopensource.datatype.xsd.QNameDatatype$QName@6e31ac62"
</test>
Paul
Paul
Re: Editing xml from RNG schema with fixed attrib of type QName
Hi Paul,
oXygen tries to insert also the value and it looks like we are using toString() to get a string representation to be inserted. The QName class does not implement toString and thus the default value that you get in the instance document.
Now, things are a little more complicated for inserting QName vales as they need to be resolved in the current namespace context. I will record this problem and we will investigate possible solutions. Of course a simple step is to offer no value when we have a QName, that fixes the wrong behavior at least.
Thanks,
George
oXygen tries to insert also the value and it looks like we are using toString() to get a string representation to be inserted. The QName class does not implement toString and thus the default value that you get in the instance document.
Now, things are a little more complicated for inserting QName vales as they need to be resolved in the current namespace context. I will record this problem and we will investigate possible solutions. Of course a simple step is to offer no value when we have a QName, that fixes the wrong behavior at least.
Thanks,
George
George Cristian Bina
Re: Editing xml from RNG schema with fixed attrib of type QName
Dear Paul,
We fixed QName insertion for RelaxNG to insert the value correctly by taking into account the available prefix in the current context for the QName namespace.
The fix will be available in 9.2 (probably in a couple of weeks).
Regards,
Radu
We fixed QName insertion for RelaxNG to insert the value correctly by taking into account the available prefix in the current context for the QName namespace.
The fix will be available in 9.2 (probably in a couple of weeks).
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 82
- Joined: Sat Jan 13, 2007 5:39 pm
- Location: Belgium
Re: Editing xml from RNG schema with fixed attrib of type QName
Post by PaulHermans »
Thanks.
Paul
Paul
Paul
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service