1
0
mirror of https://github.com/mitb-archive/filebot synced 2024-12-22 15:58:52 -05:00

Add File.isClutter() extension method.

This commit is contained in:
Reinhard Pointner 2018-12-20 18:38:44 +07:00
parent dd95a40d11
commit 62e276a9cf
2 changed files with 4 additions and 4 deletions

View File

@ -135,6 +135,10 @@ public class ScriptShellMethods {
return false;
}
public static boolean isClutter(File self) {
return MediaDetection.getClutterTypeFilter().accept(self) || MediaDetection.getClutterFileFilter().accept(self);
}
public static File getDir(File self) {
return self.getParentFile();
}

View File

@ -93,10 +93,6 @@ public class MediaDetection {
return getDiskFolderFilter().accept(folder);
}
public static boolean isClutterFile(File file) throws IOException {
return getClutterFileFilter().accept(file);
}
public static boolean isVideoDiskFile(File file) throws Exception {
if (file.isFile() && file.length() > ONE_MEGABYTE) {
try (Archive iso = Archive.open(file)) {