DrmInfoRequest
public
class
DrmInfoRequest
extends Object
| java.lang.Object | |
| ↳ | android.drm.DrmInfoRequest |
An entity class that is used to pass information to an online DRM server. An instance of this
class is passed to the DrmManagerClient#acquireDrmInfo method to get an
instance of a DrmInfo.
Summary
Constants | |
|---|---|
String |
ACCOUNT_ID
Key that is used to pass the unique session ID for the account or the user. |
String |
SUBSCRIPTION_ID
Key that is used to pass the unique session ID for the subscription. |
int |
TYPE_REGISTRATION_INFO
Acquires DRM server registration information. |
int |
TYPE_RIGHTS_ACQUISITION_INFO
Acquires rights information. |
int |
TYPE_RIGHTS_ACQUISITION_PROGRESS_INFO
Acquires the progress of the rights acquisition. |
int |
TYPE_UNREGISTRATION_INFO
Acquires information for unregistering the DRM server. |
Public constructors | |
|---|---|
DrmInfoRequest(int infoType, String mimeType)
Creates a |
|
Public methods | |
|---|---|
Object
|
get(String key)
Retrieves the value of a given key. |
int
|
getInfoType()
Retrieves the information type associated with this object. |
String
|
getMimeType()
Retrieves the MIME type associated with this object. |
Iterator<Object>
|
iterator()
Retrieves an iterator object that you can use to iterate over the values associated with
this |
Iterator<String>
|
keyIterator()
Retrieves an iterator object that you can use to iterate over the keys associated with
this |
void
|
put(String key, Object value)
Adds optional information as key-value pairs to this object. |
Inherited methods | |
|---|---|
Constants
ACCOUNT_ID
public static final String ACCOUNT_ID
Key that is used to pass the unique session ID for the account or the user.
Constant Value: "account_id"
SUBSCRIPTION_ID
public static final String SUBSCRIPTION_ID
Key that is used to pass the unique session ID for the subscription.
Constant Value: "subscription_id"
TYPE_REGISTRATION_INFO
public static final int TYPE_REGISTRATION_INFO
Acquires DRM server registration information.
Constant Value: 1 (0x00000001)
TYPE_RIGHTS_ACQUISITION_INFO
public static final int TYPE_RIGHTS_ACQUISITION_INFO
Acquires rights information.
Constant Value: 3 (0x00000003)
TYPE_RIGHTS_ACQUISITION_PROGRESS_INFO
public static final int TYPE_RIGHTS_ACQUISITION_PROGRESS_INFO
Acquires the progress of the rights acquisition.
Constant Value: 4 (0x00000004)
TYPE_UNREGISTRATION_INFO
public static final int TYPE_UNREGISTRATION_INFO
Acquires information for unregistering the DRM server.
Constant Value: 2 (0x00000002)
Public constructors
DrmInfoRequest
public DrmInfoRequest (int infoType,
String mimeType)
Creates a DrmInfoRequest object with type and MIME type.
| Parameters | |
|---|---|
infoType |
int: Type of information. |
mimeType |
String: MIME type. |
Public methods
get
public Object get (String key)
Retrieves the value of a given key.
| Parameters | |
|---|---|
key |
String: The key whose value is being retrieved. |
| Returns | |
|---|---|
Object |
The value of the key that is being retrieved. Returns null if the key cannot be found. |
getInfoType
public int getInfoType ()
Retrieves the information type associated with this object.
| Returns | |
|---|---|
int |
The information type. |
getMimeType
public String getMimeType ()
Retrieves the MIME type associated with this object.
| Returns | |
|---|---|
String |
The MIME type. |
iterator
public Iterator<Object> iterator ()
Retrieves an iterator object that you can use to iterate over the values associated with
this DrmInfoRequest object.
| Returns | |
|---|---|
Iterator<Object> |
The iterator object. |
keyIterator
public Iterator<String> keyIterator ()
Retrieves an iterator object that you can use to iterate over the keys associated with
this DrmInfoRequest object.
| Returns | |
|---|---|
Iterator<String> |
The iterator object. |
put
public void put (String key, Object value)
Adds optional information as key-value pairs to this object.
| Parameters | |
|---|---|
key |
String: The key to add. |
value |
Object: The value to add. |