Package com.google.android.exoplayer2.extractor.jpeg

## Class StartOffsetExtractorOutput

- java.lang.Object
- - com.google.android.exoplayer2.extractor.jpeg.StartOffsetExtractorOutput

- All Implemented Interfaces:
    `ExtractorOutput`

      public final class StartOffsetExtractorOutput
      extends Object
      implements ExtractorOutput

  An extractor output that wraps another extractor output and applies a give start byte offset to seek positions.

  This is useful for extracting from a container that's concatenated after some prefix data but where the container's extractor doesn't handle a non-zero start offset (for example, because it seeks to absolute positions read from the container data).

- - ### Field Summary

    - ### Fields inherited from interface com.google.android.exoplayer2.extractor.ExtractorOutput

      `PLACEHOLDER`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `StartOffsetExtractorOutput​(long startOffset, ExtractorOutput extractorOutput)` | Creates a new wrapper reading from the given start byte offset.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `void` | `endTracks()` | Called when all tracks have been identified, meaning no new `trackId` values will be passed to `ExtractorOutput.track(int, int)`.
    `void` | `seekMap​(SeekMap seekMap)` | Called when a `SeekMap` has been extracted from the stream.
    `TrackOutput` | `track​(int id, int type)` | Called by the `Extractor` to get the `TrackOutput` for a specific track.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### StartOffsetExtractorOutput

          public StartOffsetExtractorOutput​(long startOffset,
                                            ExtractorOutput extractorOutput)

      Creates a new wrapper reading from the given start byte offset.

  - ### Method Detail

    - #### track

          public TrackOutput track​(int id,
                                   int type)

      Description copied from interface: `ExtractorOutput`
      Called by the `Extractor` to get the `TrackOutput` for a specific track.

      The same `TrackOutput` is returned if multiple calls are made with the same `id`.

      Specified by:
        `track` in interface `ExtractorOutput`
      Parameters:
        `id` - A track identifier.
        `type` - The `track type`.
      Returns:
        The `TrackOutput` for the given track identifier.

    - #### endTracks

          public void endTracks()

      Description copied from interface: `ExtractorOutput`
      Called when all tracks have been identified, meaning no new `trackId` values will be passed to `ExtractorOutput.track(int, int)`.
      Specified by:
        `endTracks` in interface `ExtractorOutput`

    - #### seekMap

          public void seekMap​(SeekMap seekMap)

      Description copied from interface: `ExtractorOutput`
      Called when a `SeekMap` has been extracted from the stream.
      Specified by:
        `seekMap` in interface `ExtractorOutput`
      Parameters:
        `seekMap` - The extracted `SeekMap`.