XML.orgXML.org
FOCUS AREAS |XML-DEV |XML.org DAILY NEWSLINK |REGISTRY |RESOURCES |ABOUT
OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
When you create a markup language, what do your parent elementsmean? What do your children elements mean?

Hi Folks,

How do you define a parent element and its children?

The Geography Markup Language (GML) defines a parent element as corresponding to a real-world object and its children as properties of the real-world object. Thus, parent-child means object-property. For example, a Bridge is a real-world object and thus is the name of the parent element. Total-length, width, and crosses are properties of Bridge and thus are the names of its children:

<?xml version="1.0" encoding="UTF-8"?>
<Bridge>
    <total-length>_____</total-length>
    <width>_____</width>
    <crosses>_____</crosses>
</Bridge>

All GML applications treat a parent element as an object and its children as properties of the object.

GML takes an Object-Oriented perspective on the meaning of markup.

(The following discussion on XSLT may be stated better and/or more accurately; I invite your revision) 

XSLT takes a different perspective. XSLT takes the perspective that markup is a definition. For example, the following XSLT makes this definition: "For each cost element, c, c is greater than 0":

<xsl:for-each select="//cost">
    <xsl:variable name="c" select="xs:integer(.)" />
    <xsl:value-of select="c &gt; 0" />
</xsl:for-each> 

Each XSLT processor treats the for-each parent element as an expression of a truth (specified by its children) over the range of values indicated in the select attribute.

XSLT takes a Functional perspective on the meaning of markup.

Recap: here are two ways of defining the meaning of markup:

1. Object-property
2. Functional definition

What other ways are there? 

When you create a markup language, what do your parent elements mean? What do your children elements mean?

/Roger


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS