Commit 3998ed49 by Oliver Woodman

Mini cleanup

parent 1a138ad4
...@@ -53,13 +53,14 @@ public final class SsaDecoder extends SimpleSubtitleDecoder { ...@@ -53,13 +53,14 @@ public final class SsaDecoder extends SimpleSubtitleDecoder {
} }
/** /**
* @param initializationData Optional initialization data for the decoder. If not null, the * @param initializationData Optional initialization data for the decoder. If not null or empty,
* initialization data must consist of two byte arrays. The first must contain an SSA format * the initialization data must consist of two byte arrays. The first must contain an SSA
* line. The second must contain an SSA header that will be assumed common to all samples. * format line. The second must contain an SSA header that will be assumed common to all
* samples.
*/ */
public SsaDecoder(List<byte[]> initializationData) { public SsaDecoder(List<byte[]> initializationData) {
super("SsaDecoder"); super("SsaDecoder");
if (initializationData != null && initializationData.size() > 0) { if (initializationData != null && !initializationData.isEmpty()) {
haveInitializationData = true; haveInitializationData = true;
String formatLine = new String(initializationData.get(0)); String formatLine = new String(initializationData.get(0));
Assertions.checkArgument(formatLine.startsWith(FORMAT_LINE_PREFIX)); Assertions.checkArgument(formatLine.startsWith(FORMAT_LINE_PREFIX));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment