[XML-DEV Mailing List Archive Home]
[Reply To This Message]
- From: James Clark <email@example.com>
- To: Andrew Welch <firstname.lastname@example.org>
- Date: Mon, 13 Dec 2010 17:29:14 +0700
I can definitely see advantages in this option. I would summarise it as:
- no colons in element or attribute names,
- except that attribute names can start with "xml:";
- there's nothing to stop you having an attribute called "xmlns", but MicroXML will treat it just like any other attribute
Big upside: guaranteed to be namespace well-formed; simpler.
Big downside: some XML infosets cannot be expressed.
I would be interested to know whether others also find this option preferable.
On Mon, Dec 13, 2010 at 5:12 PM, Andrew Welch <email@example.com>
...I think everyone takes "XML" to mean "XML 1.0 + XML Namespaces" so
On 13 December 2010 09:42, James Clark <firstname.lastname@example.org
> On Mon, Dec 13, 2010 at 4:33 PM, Andrew Welch <email@example.com
>> On 13 December 2010 09:01, James Clark <firstname.lastname@example.org
>> > I wrote a post describing a fairly minimal subset of XML:
>> > http://blog.jclark.com/2010/12/microxml.html
>> Looks great - apart from the xmlns requirement if prefixes are used...
>> doesn't that make it no longer a subset?
> It's designed to be a subset of XML 1.0 but not of XML 1.0 + XML Namespaces.
to say something is a "subset of XML" but not mean namespaces you
might get done for false advertising :)
If you didn't have to compromise, what would you do? I would say in
> However, it does allow you to make your documents be namespace well-formed
> if you want. This is a tough problem: full XML Namespaces seems like too
> much complexity, so I've tried to find a compromise.
situations where namespace-like features are needed, use XML 1.0.
Is that an issue...? If so, use xml 1.0.
>> b) use an underscore or dot, eg <mycomp.foo>
> You could just disallow colons in element and attribute names, but then you
> lose the ability to work with XML vocabularies that require the use of the
> non-default namespace (eg xlink:*, xml:*).
The kind of use-case for MicroXML that I see is where someone is given
the task of creating some XML for the first time and they need some
guidance on what to do... a quick google reveals "MicroXML" to be the
best easiest format for simple XML, and they follow the rules "no
namespaces", "no DTDs", "no CDATA sections" etc and create some good
clean XML that's then easy to work with.
At the moment, the inclination seems to be to use a default namespace
just because that seems like the right thing to do, they leave off the
prolog but save the file in Windows-1252, wrap all text in CDATA
sections and/or run the XML through some custom escaping code... an
ultra-simple alternative would solve all of that.
| [Thread Prev]
| [Thread Next]
| [Date Next]
| [Thread Index]
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format
Stylus Studio has published XML-DEV in RSS and ATOM formats,
enabling users to easily subcribe to the list from their preferred news reader application.
Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website.
they were not included by the author in the initial post. To view the content without the Sponsor Links please