mirror of
https://github.com/samsonjs/media.git
synced 2026-03-28 09:55:48 +00:00
Merge pull request #454 from pakerfeldt/property-setter
Support setting properties on MediaDrm
This commit is contained in:
commit
ea9611aceb
1 changed files with 24 additions and 0 deletions
|
|
@ -213,6 +213,18 @@ public class StreamingDrmSessionManager implements DrmSessionManager {
|
|||
return mediaDrm.getPropertyString(key);
|
||||
}
|
||||
|
||||
/**
|
||||
* Provides access to {@link MediaDrm#setPropertyString(String, String)}.
|
||||
* <p>
|
||||
* This method may be called when the manager is in any state.
|
||||
*
|
||||
* @param key The property to write.
|
||||
* @param value The value to write.
|
||||
*/
|
||||
public final void setPropertyString(String key, String value) {
|
||||
mediaDrm.setPropertyString(key, value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Provides access to {@link MediaDrm#getPropertyByteArray(String)}.
|
||||
* <p>
|
||||
|
|
@ -225,6 +237,18 @@ public class StreamingDrmSessionManager implements DrmSessionManager {
|
|||
return mediaDrm.getPropertyByteArray(key);
|
||||
}
|
||||
|
||||
/**
|
||||
* Provides access to {@link MediaDrm#setPropertyByteArray(String, byte[])}.
|
||||
* <p>
|
||||
* This method may be called when the manager is in any state.
|
||||
*
|
||||
* @param key The property to write.
|
||||
* @param value The value to write.
|
||||
*/
|
||||
public final void setPropertyByteArray(String key, byte[] value) {
|
||||
mediaDrm.setPropertyByteArray(key, value);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void open(DrmInitData drmInitData) {
|
||||
if (++openCount != 1) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue