How to get a package name from Absolute Path?

时间:2018-12-19 11:13:49

标签: java path classpath

I have the following String example which contains Absolute Path for a class

String myPath = "C:\Users\com\module\mypackage\MyClass.class" Need to get The package name: "com.module.mypackage" Is there any Build in library for That?

0 个答案:

没有答案