可以使用如下简单语句:
URL classFileDir =new yourClassName().getClass().getResource(".");
print结果为:file:....的URL
To see a world in a grain of sand.
And a heaven in a wild flower
Hold infinity in the palm of your hand.
And eternity in an hour
一花一世界
一沙一天堂
掌中握无限
霎那成永恒