Search in sources :

Example 1 with IStructuredTextReParser

use of org.eclipse.wst.sse.core.internal.provisional.text.IStructuredTextReParser in project webtools.sourceediting by eclipse.

the class BasicStructuredDocument method updateModel.

private StructuredDocumentEvent updateModel(Object requester, int start, int lengthToReplace, String changes) {
    StructuredDocumentEvent result = null;
    IStructuredTextReParser reParser = getReParser();
    // initialize the IStructuredTextReParser with the standard data
    // that's
    // always needed
    reParser.initialize(requester, start, lengthToReplace, changes);
    result = reParser.reparse();
    // if result is null at this point, then there must be an error, since
    // even if there
    // was no change (either disallow due to readonly, or a person pasted
    // the same thing
    // they had selected) then a "NoChange" event should have been fired.
    // $NON-NLS-1$
    Assert.isNotNull(result, "no structuredDocument event was created in IStructuredDocument::updateStructuredDocument");
    return result;
}
Also used : StructuredDocumentEvent(org.eclipse.wst.sse.core.internal.provisional.events.StructuredDocumentEvent) IStructuredTextReParser(org.eclipse.wst.sse.core.internal.provisional.text.IStructuredTextReParser)

Aggregations

StructuredDocumentEvent (org.eclipse.wst.sse.core.internal.provisional.events.StructuredDocumentEvent)1 IStructuredTextReParser (org.eclipse.wst.sse.core.internal.provisional.text.IStructuredTextReParser)1