// Inherit Javadoc.
public void emptyElement(DissectableElement element)
throws DissectionException {
WBDOMElement delement = (WBDOMElement) element;
boolean hasAttributes = delement.hasAttributes();
// can't do this check because sometimes we force stuff to be
// empty that isn't really.
// if (delement.hasChildren()) {
// throw new IllegalStateException(
// "Attempt to write an invalid (non-empty) element");
// }
try {
// Serialise the start of the element.
elementNameSerialiser.use(hasAttributes, false);
delement.accept(elementNameSerialiser);
// Serialise the attributes.
if (hasAttributes) {
attributesSerialiser.use(delement);
delement.forEachAttribute(attributesSerialiser);
handler.endElement();
}
} catch (WBDOMException e) {
throw new DissectionException(e);
} catch (WBSAXException e) {