Refactor MediaInfo

This commit is contained in:
Reinhard Pointner 2016-08-10 04:13:39 +08:00
parent 9dd4a82e04
commit 0ef31fc19d
1 changed files with 2 additions and 5 deletions

View File

@ -248,12 +248,9 @@ public class MediaInfo implements Closeable {
} }
} }
/**
* Helper for easy usage
*/
public static Map<StreamKind, List<Map<String, String>>> snapshot(File file) throws IOException { public static Map<StreamKind, List<Map<String, String>>> snapshot(File file) throws IOException {
try (MediaInfo mi = new MediaInfo()) { try (MediaInfo mi = new MediaInfo().open(file)) {
return mi.open(file).snapshot(); return mi.snapshot();
} }
} }