how to get the file resources in the idea plugin xxxx.jar

I have create a idea plugin  but i cannot get the inner file ,such as   test.txt . i know the imageLoader can get image resources ,but no fileLoader method.
I neednt any third jar.

thanks.

4 comments
Comment actions Permalink
String file =   this.getClass().getClassLoader().getResource("/com/plugin/test/test.txt").getFile();
0
Comment actions Permalink

I have similar problem. Idea won`t add unkonwn files such as *.txt to the jar file and for this reason I can`t load them in application.

0

Please sign in to leave a comment.