Search code examples
intellij-ideapluginsintellij-plugin

Custom intellij plugin to trigger function like textChange()


I am writing a custom plugin for intellij.

This plugin listens to port. When receiving specific information, it should trigger to scan text, like textChange().

When java file has been modified, Inspection plugin will inspect all file again to find some errors or warnings. But I want to trigger inspecting by my program, instead of modifying

How can I trigger this event?


Solution

  • To force rehighlighting of a file, use DaemonCodeAnalyzer.getInstance(project).restart(file).