Commit 3c5a509a by olly Committed by Oliver Woodman

Remove unused method.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=117338990
parent 1eff6cf2
......@@ -147,11 +147,6 @@ public final class FrameworkSampleSource implements SampleSource {
}
@Override
public boolean isPrepared() {
return prepared;
}
@Override
public long getDurationUs() {
return C.UNKNOWN_TIME_US;
}
......
......@@ -36,16 +36,16 @@ public class MultiSampleSource implements SampleSource {
@Override
public boolean prepare(long positionUs) throws IOException {
if (this.prepared) {
if (prepared) {
return true;
}
boolean prepared = true;
boolean sourcesPrepared = true;
for (int i = 0; i < sources.length; i++) {
prepared &= sources[i].prepare(positionUs);
sourcesPrepared &= sources[i].prepare(positionUs);
}
if (prepared) {
this.prepared = true;
this.durationUs = C.UNKNOWN_TIME_US;
if (sourcesPrepared) {
prepared = true;
durationUs = C.UNKNOWN_TIME_US;
int totalTrackGroupCount = 0;
for (int i = 0; i < sources.length; i++) {
totalTrackGroupCount += sources[i].getTrackGroups().length;
......@@ -67,11 +67,6 @@ public class MultiSampleSource implements SampleSource {
}
@Override
public boolean isPrepared() {
return prepared;
}
@Override
public TrackGroupArray getTrackGroups() {
return trackGroups;
}
......
......@@ -35,13 +35,6 @@ public interface SampleSource {
boolean prepare(long positionUs) throws IOException;
/**
* Returns whether the source is prepared.
*
* @return True if the source is prepared. False otherwise.
*/
boolean isPrepared();
/**
* Returns the duration of the source.
* <p>
* This method should only be called after the source has been prepared.
......@@ -58,7 +51,7 @@ public interface SampleSource {
*
* @return The {@link TrackGroup}s.
*/
public TrackGroupArray getTrackGroups();
TrackGroupArray getTrackGroups();
/**
* Indicates to the source that it should continue buffering data for its enabled tracks.
......@@ -103,7 +96,7 @@ public interface SampleSource {
* @param positionUs The current playback position in microseconds.
* @return A {@link TrackStream} from which the enabled track's data can be read.
*/
public TrackStream enable(TrackSelection selection, long positionUs);
TrackStream enable(TrackSelection selection, long positionUs);
/**
* Releases the source.
......
......@@ -96,11 +96,6 @@ public final class SingleSampleSource implements SampleSource, TrackStream, Load
}
@Override
public boolean isPrepared() {
return loader != null;
}
@Override
public long getDurationUs() {
return durationUs;
}
......
......@@ -168,11 +168,6 @@ public class ChunkSampleSource implements SampleSource, TrackStream, Loader.Call
}
@Override
public boolean isPrepared() {
return state != STATE_IDLE;
}
@Override
public long getDurationUs() {
return durationUs;
}
......
......@@ -352,11 +352,6 @@ public final class ExtractorSampleSource implements SampleSource, ExtractorOutpu
}
@Override
public boolean isPrepared() {
return prepared;
}
@Override
public long getDurationUs() {
return durationUs;
}
......
......@@ -177,11 +177,6 @@ public final class HlsSampleSource implements SampleSource, Loader.Callback {
}
@Override
public boolean isPrepared() {
return prepared;
}
@Override
public long getDurationUs() {
return chunkSource.getDurationUs();
}
......
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