public void restart(@NotNull CharSequence text) {
    lexer.start(text);

    if (lexer instanceof LexerEditorHighlighterLexer) {
      HighlighterIterator iterator = ((LexerEditorHighlighterLexer)lexer).getHighlighterIterator();
      if (iterator instanceof LayeredHighlighterIterator) {
        layeredHighlighterIterator = (LayeredHighlighterIterator)iterator;
      } else {
        layeredHighlighterIterator = null;
      }
    }
  }
public void restart(@NotNull CharSequence text)