public final class

DrmInitData.SchemeData

extends java.lang.Object

 java.lang.Object

↳androidx.media3.common.DrmInitData.SchemeData

Overview

Scheme initialization data.

Summary

Fields
public static final <any>CREATOR

public final byte[]data

The initialization data.

public final java.lang.StringlicenseServerUrl

The URL of the server to which license requests should be made.

public final java.lang.StringmimeType

The mimeType of DrmInitData.SchemeData.data.

public final java.util.UUIDuuid

The java.util.UUID of the DRM scheme, or C.UUID_NIL if the data is universal (i.e.

Constructors
publicSchemeData(java.util.UUID uuid, java.lang.String mimeType, byte[] data[])

publicSchemeData(java.util.UUID uuid, java.lang.String licenseServerUrl, java.lang.String mimeType, byte[] data[])

Methods
public booleancanReplace(DrmInitData.SchemeData other)

Returns whether this DrmInitData.SchemeData can be used to replace other.

public DrmInitData.SchemeDatacopyWithData(byte[] data[])

Returns a copy of this instance with the specified data.

public intdescribeContents()

public booleanequals(java.lang.Object obj)

public booleanhasData()

Returns whether DrmInitData.SchemeData.data is non-null.

public inthashCode()

public booleanmatches(java.util.UUID schemeUuid)

Returns whether this initialization data applies to the specified scheme.

public voidwriteToParcel(Parcel dest, int flags)

from java.lang.Objectclone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait

Fields

public final java.util.UUID uuid

The java.util.UUID of the DRM scheme, or C.UUID_NIL if the data is universal (i.e. applies to all schemes).

public final java.lang.String licenseServerUrl

The URL of the server to which license requests should be made. May be null if unknown.

public final java.lang.String mimeType

The mimeType of DrmInitData.SchemeData.data.

public final byte[] data

The initialization data. May be null for scheme support checks only.

public static final <any> CREATOR

Constructors

public SchemeData(java.util.UUID uuid, java.lang.String mimeType, byte[] data[])

Parameters:

uuid: The java.util.UUID of the DRM scheme, or C.UUID_NIL if the data is universal (i.e. applies to all schemes).
mimeType: See DrmInitData.SchemeData.mimeType.
data: See DrmInitData.SchemeData.data.

public SchemeData(java.util.UUID uuid, java.lang.String licenseServerUrl, java.lang.String mimeType, byte[] data[])

Parameters:

uuid: The java.util.UUID of the DRM scheme, or C.UUID_NIL if the data is universal (i.e. applies to all schemes).
licenseServerUrl: See DrmInitData.SchemeData.licenseServerUrl.
mimeType: See DrmInitData.SchemeData.mimeType.
data: See DrmInitData.SchemeData.data.

Methods

public boolean matches(java.util.UUID schemeUuid)

Returns whether this initialization data applies to the specified scheme.

Parameters:

schemeUuid: The scheme java.util.UUID.

Returns:

Whether this initialization data applies to the specified scheme.

public boolean canReplace(DrmInitData.SchemeData other)

Returns whether this DrmInitData.SchemeData can be used to replace other.

Parameters:

other: A DrmInitData.SchemeData.

Returns:

Whether this DrmInitData.SchemeData can be used to replace other.

public boolean hasData()

Returns whether DrmInitData.SchemeData.data is non-null.

public DrmInitData.SchemeData copyWithData(byte[] data[])

Returns a copy of this instance with the specified data.

Parameters:

data: The data to include in the copy.

Returns:

The new instance.

public boolean equals(java.lang.Object obj)

public int hashCode()

public int describeContents()

public void writeToParcel(Parcel dest, int flags)