Interface ProgressiveMediaExtractor
-
- All Known Implementing Classes:
BundledExtractorsAdapter
,MediaParserExtractorAdapter
@Deprecated public interface ProgressiveMediaExtractor
Deprecated.com.google.android.exoplayer2 is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.Extracts the contents of a container file from a progressive media stream.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
ProgressiveMediaExtractor.Factory
Deprecated.CreatesProgressiveMediaExtractor
instances.
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description void
disableSeekingOnMp3Streams()
Deprecated.Disables seeking in MP3 streams.long
getCurrentInputPosition()
Deprecated.Returns the current read position in the input stream, orC.INDEX_UNSET
if no input is available.void
init(DataReader dataReader, Uri uri, Map<String,List<String>> responseHeaders, long position, long length, ExtractorOutput output)
Deprecated.Initializes the underlying infrastructure for reading from the input.int
read(PositionHolder positionHolder)
Deprecated.Extracts data starting at the current input stream position.void
release()
Deprecated.Releases any held resources.void
seek(long position, long seekTimeUs)
Deprecated.Notifies the extracting infrastructure that a seek has occurred.
-
-
-
Method Detail
-
init
void init(DataReader dataReader, Uri uri, Map<String,List<String>> responseHeaders, long position, long length, ExtractorOutput output) throws IOException
Deprecated.Initializes the underlying infrastructure for reading from the input.- Parameters:
dataReader
- TheDataReader
from which data should be read.uri
- TheUri
from which the media is obtained.responseHeaders
- The response headers of the media, or an empty map if there are none.position
- The initial position of thedataReader
in the stream.length
- The length of the stream, orC.LENGTH_UNSET
if length is unknown.output
- TheExtractorOutput
that will be used to initialize the selected extractor.- Throws:
UnrecognizedInputFormatException
- Thrown if the input format could not be detected.IOException
- Thrown if the input could not be read.
-
release
void release()
Deprecated.Releases any held resources.
-
disableSeekingOnMp3Streams
void disableSeekingOnMp3Streams()
Deprecated.Disables seeking in MP3 streams.MP3 live streams commonly have seekable metadata, despite being unseekable.
-
getCurrentInputPosition
long getCurrentInputPosition()
Deprecated.Returns the current read position in the input stream, orC.INDEX_UNSET
if no input is available.
-
seek
void seek(long position, long seekTimeUs)
Deprecated.Notifies the extracting infrastructure that a seek has occurred.- Parameters:
position
- The byte offset in the stream from which data will be provided.seekTimeUs
- The seek time in microseconds.
-
read
int read(PositionHolder positionHolder) throws IOException
Deprecated.Extracts data starting at the current input stream position.- Parameters:
positionHolder
- IfExtractor.RESULT_SEEK
is returned, this holder is updated to hold the position of the required data.- Returns:
- One of the
Extractor
.RESULT_*
values. - Throws:
IOException
- If an error occurred reading from the input.
-
-