void () { if (myDocument instanceof DocumentImpl) { ((DocumentImpl)myDocument).assertNotInBulkUpdate(); } else if (myDocument.isInBulkUpdate()) { throw new IllegalStateException("Current operation is not permitted in bulk mode"); } if (myEditor.getInlayModel().isInBatchMode()) { throw new IllegalStateException("Current operation is not permitted during batch inlay update"); } }