String path= this.getClass().getClassLoader().getResource("").getPath(); path=path.substring(1).replace("/","\\") ; 相关文章: