protected final Document getDocument() {
return document;
}
public final void handleInsert(int offset, String text) {
Interval i = IntervalFactory.fromStartAndLength(offset, text.length());
Partition start = getStartPointForScan(i);
int endPosition = calculateEndOfDamagedRegionOnInsert(offset, text);
int tailShift = text.length();
calculateDamage(start, endPosition, tailShift);
}