/** * Resolve a resource from the provided context and path. * * @param context the context of the application that will help to resolve the path source code * @param path the path of the resource to resolve * @return the resolved resource or null if it cannot be determined * @throws NullPointerException if any argument is null * @throws IllegalArgumentException if the context package is not valid */ public FileObject resolveResourceFromClassPath(ElementHandle.Package context, Path.Absolute path) throws NullPointerException, IllegalArgumentException { return resolveResourceFromClassPath(context, FileKey.newName(path)); }
/** * Resolve a resource from the provided context and path. * * @param context the context of the application that will help to resolve the path source code * @param path the path of the resource to resolve * @return the resolved resource or null if it cannot be determined * @throws NullPointerException if any argument is null * @throws IllegalArgumentException if the context package is not valid */ public FileObject resolveResourceFromClassPath(ElementHandle.Package context, Path.Absolute path) throws NullPointerException, IllegalArgumentException { return resolveResourceFromClassPath(context, FileKey.newName(path)); }