}
// Inherit Javadoc.
public void addTextCost(DissectableText text, Accumulator accumulator)
throws DissectionException {
WBDOMText dtext = (WBDOMText) text;
WBSAXValueSizeVisitor valueSummer =
new WBSAXValueSizeVisitor(accumulator);
try {
// Calculate the size of the text
dtext.getBuffer().accept(valueSummer);
} catch (WBSAXException e) {
throw new DissectionException(
exceptionLocalizer.format("cannot-calculate-size"), e);
}
}