[dsdl-discuss] Comparison of "prune", "cover", "dummy", and "delve"

From: MURATA Makoto <murata@hokkaido.email.ne.jp>
Date: Sat Apr 26 2003 - 15:43:51 UTC

This mail is an attempt to clarify some of the semantics of the CD of
DSDL Part 4, MNS, and Namespace Switchboard.

As an example, consider a document as below:

<foo:a>
  <bar:b>
    <bar:c/>
    <foo:d/>
    <bar:e>
      <foo:f>
      </foo:f>
    </bar:e>
  </bar:b>
  <bar:f/>
</foo:a>

From this document, we can create a different number of validation
candidates by specifying different schemas in the CD, MNS or Namespace
Switchboard. Let us consider first validation candidate. It is
certainly rooted by <foo:a>. But what is the content of this element?
I see three options.

Option 1: As is

<foo:a>
  <bar:b>
    <bar:c/>
    <foo:d/>
    <bar:e>
      <foo:f>
      </foo:f>
    </bar:e>
  </bar:b>
  <bar:f/>
</foo:a>

Note: This is the semantics of MNS, when we do not prune the <bar:b>
or <bar:f> elements or we specify "bar" as a covered namespace. This
option is not possible in the Part 4 CD.

Option 2: Replace foreign elements by <foreign/>

By replacing the elements rooted by <bar:b> <bar:f> with dummy
elements, we obtain

<foo:a>
  <dummy namespaceName="http://www.example.com/foo"
         xmlns="http://www.xml.gr.jp/xmlns/dummy"/>
  <dummy namespaceName="http://www.example.com/foo"
         xmlns="http://www.xml.gr.jp/xmlns/dummy"/>
</foo:a>

Note: this is the semantics of the Part 4 CD.

Option 3: Remove foreign elements (as well as their attributes and
          contents)

By removing the elements rooted by <bar:b> and <bar:f>,
we obtain

<foo:a>
</foo:a>

This option is particularly useful, when there is a closed schema and
we cannot change it.

Note: This is the semantics of MNS, when we prune the <bar:b> and
<bar:f> elements. This option is not possible in the Part 4 CD.

Option 4: Recursively remove tags of foreign namespaces

By removing <bar:b>, </bar:b>, <bar:c/>, <bar:e>, </bar:e>, and
<bar:f/>, we obtain

<foo:a>
    <foo:d/>
      <foo:f>
      </foo:f>
</foo:a>

This option is particularly useful, when we handle XForms or XSLT.

Note: In my understanding, this is the semantics of "Namespace
Switchboard" when traversal='delve'.

-- 
MURATA Makoto <murata@hokkaido.email.ne.jp>
--
DSDL members discussion list
To unsubscribe, please send a message with the
command  "unsubscribe" to dsdl-discuss-request@dsdl.org
(mailto:dsdl-discuss-request@dsdl.org?Subject=unsubscribe)
Received on Sat Apr 26 17:44:34 2003

This archive was generated by hypermail 2.1.8 : Fri Dec 03 2004 - 14:00:27 UTC