Package com.castlabs.android.player
Class HlsClearKeyCache
- java.lang.Object
-
- com.castlabs.android.player.HlsClearKeyCache
-
- Direct Known Subclasses:
MemoryHlsClearKeyCache
public abstract class HlsClearKeyCache extends Object
Cache forDrm.Clearkey
.Can be
gotten
orPlayerController.setHlsKeyCache(HlsClearKeyCache)
set} in the PlayerController.- See Also:
MemoryHlsClearKeyCache
-
-
Constructor Summary
Constructors Constructor Description HlsClearKeyCache()
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract boolean
containsUri(Uri uri)
Returns true ifuri
is present in the cache.abstract byte[]
get(Uri uri)
Returns theencryptionKey
cached against thisuri
, or null ifuri
is null or not present in the cache.abstract byte[]
put(Uri uri, byte[] encryptionKey)
Inserts an entry into the cache.abstract byte[]
remove(Uri uri)
Removesuri
from the cache.
-
-
-
Method Detail
-
get
@Nullable public abstract byte[] get(@Nullable Uri uri)
Returns theencryptionKey
cached against thisuri
, or null ifuri
is null or not present in the cache.
-
put
@Nullable public abstract byte[] put(@NonNull Uri uri, @NonNull byte[] encryptionKey)
Inserts an entry into the cache.- Throws:
NullPointerException
- ifuri
orencryptionKey
are null.
-
containsUri
public abstract boolean containsUri(@NonNull Uri uri)
Returns true ifuri
is present in the cache.- Throws:
NullPointerException
- ifuri
is null.
-
remove
@Nullable public abstract byte[] remove(@NonNull Uri uri)
Removesuri
from the cache. Ifuri
was present in the cahce, this returns the correspondingencryptionKey
, otherwise null.- Throws:
NullPointerException
- ifuri
is null.
-
-