interface PlayerBufferAPI {
    getLevel(type, media): BufferLevel;
    setTargetLevel(type, value, media): void;
}

Methods

  • Returns the current and target buffer level for the given buffer type and media type.

    Parameters

    • type: BufferType

      the buffer type for which to get the buffer level for.

    • media: MediaType

      the media type for which to get the buffer level for.

    Returns BufferLevel

    Since

    v8.1

  • Sets the target buffer level for the chosen buffer and media type.

    Parameters

    • type: BufferType

      The buffer type to change the target buffer level for.

    • value: number

      The value to set.

    • media: MediaType

      The media type to change the target buffer level for.

    Returns void

    Since

    v8.1