输出引用jar包的地址

233 阅读1分钟
    	ClassLoader classloader =
        org.apache.poi.poifs.filesystem.POIFSFileSystem.class.getClassLoader();
         URL res = classloader.getResource(
                  "org/apache/poi/hssf/usermodel/HSSFDateUtil.class");
         String path = res.getPath();
         System.out.println("HSSFDateUtil POI came from :" + path);