DrmExtractorLink

Class holds extracted DRM media info to be passed to the player.

Constructors

Link copied to clipboard
constructor(    source: String,     name: String,     url: String,     referer: String? = null,     quality: Int? = null,     type: ExtractorLinkType? = INFER_TYPE,     headers: Map<String, String> = mapOf(),     extractorData: String? = null,     kid: String? = null,     key: String? = null,     uuid: UUID = CLEARKEY_UUID,     kty: String? = "oct",     keyRequestParameters: HashMap<String, String> = hashMapOf(),     licenseUrl: String? = null)
constructor(    source: String,     name: String,     url: String,     referer: String,     quality: Int,     type: ExtractorLinkType?,     headers: Map<String, String> = mapOf(),     extractorData: String? = null,     kid: String? = null,     key: String? = null,     uuid: UUID = CLEARKEY_UUID,     kty: String? = "oct",     keyRequestParameters: HashMap<String, String> = hashMapOf(),     licenseUrl: String? = null)

Properties

Link copied to clipboard
open override var extractorData: String?

Used for getExtractorVerifierJob()

Link copied to clipboard
open override var headers: Map<String, String>

Headers map that will be used by network request.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open var key: String?

Base64 value of Key to be used to decrypt the media file.

Link copied to clipboard

Parameters that will used to request the key.

Link copied to clipboard
open var kid: String?

Base64 value of The KID element (Key Id) contains the identifier of the key associated with a license.

Link copied to clipboard
open var kty: String?

Key type "oct" (octet sequence) by default

Link copied to clipboard
open var licenseUrl: String?
Link copied to clipboard
open override val name: String

Title of the media, appears on player layout.

Link copied to clipboard
open override var quality: Int

Quality of the media file

Link copied to clipboard
open override var referer: String

Referer that will be used by network request.

Link copied to clipboard
open override val source: String

Name of the media source, appears on player layout.

Link copied to clipboard
open override var type: ExtractorLinkType

the type of the media, use INFER_TYPE if you want to auto infer the type from the url

Link copied to clipboard
open override val url: String

Url string of media file

Link copied to clipboard
open var uuid: UUID

Drm UUID WIDEVINE_UUID, PLAYREADY_UUID, CLEARKEY_UUID (by default) .. etc

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
suspend fun getVideoSize(timeoutSeconds: Long = 3): Long?

Get video size in bytes with one head request. Only available for ExtractorLinkType.Video

Link copied to clipboard
open override fun toString(): String