The XUpdate spec and DTD is looking good.

A few typos in the DTD:

"<!ELEMENT xupdate:insert-before (%instructions;)*>
 <!ATTLIST xupdate:insert
    select      CDATA   #REQUIRED
 >

 <!ELEMENT xupdate:insert-after (%instuctions;)*>
 <!ATTLIST xupdate:insert
    select      CDATA   #REQUIRED
 >

 <!ELEMENT xupdate:append (%instructions;)*>
 <!ATTLIST xupdate:insert
    select      CDATA   #REQUIRED
    child       CDATA   #IMPLIED
 >
"
 editorgen.xsl can be easily rewritten (when i have a moment) and renamed
updategen.xsl

  the one thing i would like to see is an

<xupdate:update-or-insert select="..">

  alternatively we can also include an

<xupdate:choose><xupdate:when ...>..<xupdate:otherwise..>

construct.

Basically I want to be able to:

<choose>
<when test="path">
        <update select="path">
                    new value
        </update>
</when>
<otherwise>
        <append select="path/parent::node()">
                    new value
        </append>
</otherwise>
</choose>

Also, the remainind construct in XEditor which I find useful is the
"path-prefix" attribute, the reason this exists is to allow the XUpdate
operation to take place on a specified subtree of the main document
specified by the path-prefix value which is prepended to the generated
XPaths (see http://www.openhealth.org/editor/editorgen.xsl for usage.

1) this attribute is optional
2) when the document to be updated does have a deep hierarchy it simplifies
the update list.
Think of it this way: suppose the entire world is in a huge XML document,
path-prefix allows the update operation to be carried out on a particular
well defined location within what is otherwise a morass.

Jonathan Borden
The Open Healthcare Group
http://www.openhealth.org

------------------------------------------------------------------
Post a message:          mailto:[EMAIL PROTECTED]
Unsubscribe:             mailto:[EMAIL PROTECTED]
Contact adminstrator:    mailto:[EMAIL PROTECTED]
Read archived messages:  http://www.xmldb.org/
------------------------------------------------------------------

Reply via email to