String path = ((ClassPathResource) resource).getPath();
String fileName = path;
String packageName = "";
int ix = path.lastIndexOf('/');
if (ix > 0) {
fileName = path.substring(ix + 1);
packageName = path.substring(0, ix).replace('/', '.');
}
if (fileName.endsWith(ClassUtils.CLASS_FILE_SUFFIX)) {
String typeName = packageName + "." + fileName.substring(0, fileName.length() - 6);
for (IPackageFragmentRoot root : roots) {