This is the way an early version of SAXON worked. I found with experience
that it was simpler to define the association between an element-type and an
element-handler class using a setElementHandler(tag, class) interface,
rather than defining it in the element handler for the parent class. For
example, it works far better when the processing for a <A> tag is identical
regardless whether it appears within an <X>, a <Y> or a <Z>. (If different
behaviour is required, SAXON also allows different element handlers to be
used for <A> depending on whether it appears within an <X>, a <Y> or a <Z>.)
A compromise suggested by XSL, and which has been requested by users as a
SAXON enhancement, is for the parent element to say whether or not the
children are to be processed, while retaining document-level rules that
define how they should be processed.
Mike Kay