I have some questions about the XML parser in ArgoUML used for the .argo and
the .todo files that I'm hoping some can help me with.

1. I can't find the revision history for SAXParserBase or XMLElement.
Anyone know where they lived before?

2. The content handler in SAXParser base is doing stuff that I don't
understand.  The code is

    public void characters(char[] ch, int start, int length)
        throws SAXException {
        for (int i = 0; i < nElements; i++) {
            XMLElement e = elements[i];
            String test = e.getText();
            if (test.length() > 0) {
                e.addText(RETURNSTRING); //<<< What is this trying to do?
            }
            e.addText(new String(ch, start, length));
        }
    }

This is doing two weird things (in addition to being hugely inefficient).
First, it adds the current content to *all* elements on the stack, so any
text contained in inner nested elements gets also added to its outer nesting
parents as well.  Second, it's adding a newline and six spaces (the
RETURNSTRING constant) any time it's called more than once (and the Saxon
parser is allowed to arbitrarily fragment the content so, as far as I know,
there's no significance to these call boundaries.

Anyone know what this behavior is for?  It looks like it was introduced
intentionally, but I'm not sure for what purpose.

3. The TodoParser class uses a proprietary character encoding (the methods
encode & decode) which makes it impossible for any standard XML processing
to handle the text.  Anyone know why a non-standard encoding is necessary?

Tom

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to