public void formatModel(IStructuredModel structuredModel, int start, int length) {
if(fProgressMonitor != null)
fProgressMonitor.beginTask("", 2);
IStructuredDocument structuredDocument = structuredModel.getStructuredDocument();
DocumentRewriteSession activeRewriteSession = ((IDocumentExtension4) structuredDocument).getActiveRewriteSession();
boolean startedRewriteSession = false;
if (activeRewriteSession == null) {
activeRewriteSession = ((IDocumentExtension4) structuredDocument).startRewriteSession(DocumentRewriteSessionType.UNRESTRICTED);
startedRewriteSession = true;
}