if (referenceTimes == null || referenceTimes.length == 0) {
return checkTimes;
}
long[] referenceTimesMinusLast = new long[referenceTimes.length - 1];
System.arraycopy(referenceTimes, 0, referenceTimesMinusLast, 0, referenceTimes.length - 1);
long[] checkTimesMinusLast = new long[checkTimes.length - 1];
System.arraycopy(checkTimes, 0, checkTimesMinusLast, 0, checkTimes.length - 1);
if (!Arrays.equals(checkTimesMinusLast, referenceTimesMinusLast)) {
String log = "";
log += (referenceTimes.length);
log += ("Reference : [");
for (long l : referenceTimes) {
log += (String.format("%10d,", l));
}
log += ("]");
LOG.warning(log);
log = "";
log += (checkTimes.length);
log += ("Current : [");
for (long l : checkTimes) {
log += (String.format("%10d,", l));
}
log += ("]");
LOG.warning(log);
throw new IOException("Track does not have the same fragment borders as its predecessor.");
} else {
return checkTimes;
}