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

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -