Package com.castlabs.android.player.models.mpd

# Class EventStream

java.lang.Object
com.castlabs.android.player.models.mpd.EventStream

public final class EventStream extends Object
A DASH in-MPD EventStream element, as defined by ISO/IEC 23009-1, 2nd edition, section 5.10.

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static class`
  `EventStream.Builder`
  Builder for creating EventStream instances.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `EventStream(String schemeIdUri, String value, long timescale, List<Long> presentationTimesUs, List<EventMessage> events)`
  Creates a new EventStream.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `List<EventMessage>`
  `getEvents()`
  Gets the list of event messages in the event stream.
  `List<Long>`
  `getPresentationTimesUs()`
  Gets the presentation times of the events in microseconds, sorted in ascending order.
  `String`
  `getSchemeIdUri()`
  Gets the scheme URI.
  `long`
  `getTimescale()`
  Gets the timescale of the event stream in units per second.
  `String`
  `getValue()`
  Gets the value of the event stream.
  `String`
  `id()`
  Gets the constructed ID of this event stream.

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

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

- ## Constructor Details

  - ### EventStream

    public EventStream(@NonNull String schemeIdUri, @NonNull String value, long timescale, @NonNull List<Long> presentationTimesUs, @NonNull List<EventMessage> events)
    Creates a new EventStream.
    Parameters:
      `schemeIdUri` - The scheme URI
      `value` - The value of the event stream
      `timescale` - The timescale in units per seconds
      `presentationTimesUs` - The presentation times in microseconds
      `events` - The list of event messages

- ## Method Details

  - ### getEvents

    @NonNull public List<EventMessage> getEvents()
    Gets the list of event messages in the event stream.
    Returns:
      An unmodifiable list of event messages

  - ### getPresentationTimesUs

    @NonNull public List<Long> getPresentationTimesUs()
    Gets the presentation times of the events in microseconds, sorted in ascending order.
    Returns:
      An unmodifiable list of presentation times

  - ### getSchemeIdUri

    @NonNull public String getSchemeIdUri()
    Gets the scheme URI.
    Returns:
      The scheme URI

  - ### getValue

    @NonNull public String getValue()
    Gets the value of the event stream.
    Returns:
      The value of the event stream, empty string if not defined in manifest

  - ### getTimescale

    public long getTimescale()
    Gets the timescale of the event stream in units per second.
    Returns:
      The timescale

  - ### id

    @NonNull public String id()
    Gets the constructed ID of this event stream.
    Returns:
      The ID in the format "schemeIdUri/value"