while (restStart < nameLength && name.charAt(restStart) == '/') restStart++;
if (restStart == nameLength) throw new IllegalArgumentException("Invalid name(" + name + ")");
String componentName = name.substring(componentNameStart, componentNameEnd);
URL location = FlexibleLocation.resolveLocation("component://" + componentName + "/.");
FileObject ofbizBase = getContext().resolveFile(location.toString(), properties);
return VFSUtil.toFileObject(ofbizBase.getFileSystem().getFileSystemManager(), ofbizBase.resolveFile(name.substring(restStart)).getURL().toString(), properties);
} catch (Exception e) {
throw UtilMisc.initCause(new FileSystemException(e.getMessage(), null, e), e);
}
}
}