mirror of
https://github.com/mitb-archive/filebot
synced 2024-12-24 08:48:51 -05:00
add File.resolveAsChild
This commit is contained in:
parent
7ea5b88011
commit
b87e662466
@ -56,6 +56,10 @@ public class ScriptShellMethods {
|
||||
return new File(self.getParentFile(), name);
|
||||
}
|
||||
|
||||
public static File resolveAsChild(File self, File folder) {
|
||||
return self.isAbsolute() ? self : new File(folder, self.getPath());
|
||||
}
|
||||
|
||||
public static List<File> listFiles(File self, Closure<?> closure) {
|
||||
return DefaultGroovyMethods.findAll(FileUtilities.getChildren(self), closure);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user