On 04/30/2013 10:36 PM, Fabián Mandelbaum wrote:

I've written a custom XXE command in Java that adds an automatic ID to
an element (DocBook5+).

Which check should I add in the command's prepare() method to fail if
the element selected is part of XIncluded content?

It's very simple. Add something like this to your prepare() method:

if (!elementToBeModified.isEditable()) {
    return false;
}

See http://www.xmlmind.com/xmleditor/_distrib/doc/api/com/xmlmind/xml/doc/Node.html#isEditable()



The breadcrumbs correctly show the element in blue, so I'm sure there's
some check performed there...



--
XMLmind XML Editor Support List
[email protected]
http://www.xmlmind.com/mailman/listinfo/xmleditor-support

Reply via email to