java - How to get the current file name in plugin action class -
java - How to get the current file name in plugin action class -
in intellij thought plugin action class, want java class file name user viewing. how that?
in intellij idea, if click analyse -> inspect code
, show window take scope, in show current file name also. similar view, want current file name in plugin action class. how that?
public class myaction extends anaction { public void actionperformed(anactionevent e) { virtualfile vfile = e.getdata(platformdatakeys.virtual_file); string filename = vfile != null ? vfile.getname() : null; } }
java plugins intellij-idea intellij-plugin
Comments
Post a Comment