break;
}
System.out.println("Snapshot " + i);
Condition<?> timeReachedCondition = new TimeReachedCondition(mediaPlayer, time) {
@Override
protected boolean onBefore() {
mediaPlayer.setTime(targetTime);
return true;
}
};
timeReachedCondition.await();
Condition<?> pausedCondition = new PausedCondition(mediaPlayer) {
@Override
protected boolean onBefore() {
mediaPlayer.pause();