- From: Dennis E. Hamilton <dennis.hamilton@acm.org>
- Date: Fri, 15 Mar 2013 10:40:48 -0700
- To: <public-change@w3.org>
- Cc: "'Claudius Teodorescu'" <claudius.teodorescu@gmail.com>
Claudius asked me an interesting question in an off-list note today.
With his permission I am reporting his question and my response to
the list.
Also, since this happened, a big coin dropped on my head. I think I
have a way to express a model that has eluded me for at least four
years. I will report on that separately.
THE SUGGESTION FROM CLAUDIUS
I am thinking of an EXPath String Module, containing useful
functions for string manipulation, of which I guess the
following could help:
- string:remove-substring($index, $length);
- string:insert-substring($index, $substring).
What do you think?
MY INITIAL THINKING (very off the top of my head)
I am not clear that it is a good thing to have manipulation of
the DOM directly in EXPath.
I have not looked more closely into your ExPath work,
<http://extxsltforms.sourceforge.net/expath-specs/index.html>.
I should do so.
My first thought was there needed to be a way to use [E]XPath
extension to set a cursor into a text node or an attribute node.
(I suppose comment nodes qualify also, as long as we're generalizing.)
I don't know how that should work, since it is not part of the
InfoSet model.
The reason for setting cursors for start and end points is the need to
specify exactly where a tear is made for deletion or replacement in
applying a change. Some of these are not so helpful if they need
to be broken down into small atomic operations.
An after-thought. It might be that, if one wanted to stay "pure,"
it is desirable to have an ExPath and an ExSLT. Even though
implementations might have specialized cases and other ways of
coding the data, being able to do that would be an interesting
confirmation of the concept [and a model] as well as a way to do
it for custom manipulation of XML documents.
Received on Friday, 15 March 2013 17:41:18 UTC