Clarify JavaDoc of MediaPeriod.

Two of MediaPeriod's methods are only called after the media period has been
prepared. Added this to JavaDoc of these method to simplify implementations.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=160510373
This commit is contained in:
tonihei 2017-06-29 04:16:16 -07:00 committed by Oliver Woodman
parent c33d16d6ae
commit df84f2930c

View file

@ -106,6 +106,8 @@ public interface MediaPeriod extends SequenceableLoader {
/**
* Discards buffered media up to the specified position.
* <p>
* This method should only be called after the period has been prepared.
*
* @param positionUs The position in microseconds.
*/
@ -116,6 +118,8 @@ public interface MediaPeriod extends SequenceableLoader {
* <p>
* After this method has returned a value other than {@link C#TIME_UNSET}, all
* {@link SampleStream}s provided by the period are guaranteed to start from a key frame.
* <p>
* This method should only be called after the period has been prepared.
*
* @return If a discontinuity was read then the playback position in microseconds after the
* discontinuity. Else {@link C#TIME_UNSET}.