| java.lang.Object | |
| ↳ | android.drm.DrmManagerClient |
Interface of DRM Framework. Java application will instantiate this class to access DRM agent through DRM Framework.
| Nested Classes | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| DrmManagerClient.OnErrorListener | Interface definition of a callback to be invoked to communicate the error occurred | ||||||||||
| DrmManagerClient.OnEventListener | Interface definition of a callback to be invoked to communicate the result of time consuming APIs asynchronously | ||||||||||
| DrmManagerClient.OnInfoListener | Interface definition of a callback to be invoked to communicate some info and/or warning about DrmManagerClient. | ||||||||||
| Constants | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| int | ERROR_NONE | Constant field signifies the success or no error occurred | |||||||||
| int | ERROR_UNKNOWN | Constant field signifies that error occurred and the reason is not known | |||||||||
| Public Constructors | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
To instantiate DrmManagerClient
| |||||||||||
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Retrieves necessary information for register, unregister or rights acquisition.
| |||||||||||
Executes given DrmInfoRequest and returns the rights information asynchronously.
| |||||||||||
Check whether the given mimetype or uri can be handled.
| |||||||||||
Check whether the given mimetype or path can be handled.
| |||||||||||
Check whether the given content has valid rights or not
| |||||||||||
Check whether the given content has valid rights or not for specified action.
| |||||||||||
Check whether the given content has valid rights or not for specified action.
| |||||||||||
Check whether the given content has valid rights or not
| |||||||||||
Informs the Drm Agent when there is no more data which need to be converted
or when an error occurs.
| |||||||||||
Accepts and converts the input data which is part of DRM file.
| |||||||||||
Retrieves informations about all the plug-ins registered with DrmFramework.
| |||||||||||
Get constraints information evaluated from DRM content
| |||||||||||
Get constraints information evaluated from DRM content
| |||||||||||
Retrieves the type of the protected object (content, rights, etc..)
using specified uri or mimetype.
| |||||||||||
Retrieves the type of the protected object (content, rights, etc..)
using specified path or mimetype.
| |||||||||||
Get metadata information from DRM content
| |||||||||||
Get metadata information from DRM content
| |||||||||||
Retrieves the mime type embedded inside the original content
| |||||||||||
Retrieves the mime type embedded inside the original content
| |||||||||||
This API is for Forward Lock based DRM scheme.
| |||||||||||
Executes given drm information based on its type
| |||||||||||
Removes all the rights information of every plug-in associated with
DRM framework.
| |||||||||||
Removes the rights associated with the given protected content
| |||||||||||
Removes the rights associated with the given protected content
| |||||||||||
Save DRM rights to specified rights path
and make association with content path.
| |||||||||||
Register a callback to be invoked when the caller required to receive
error result of asynchronous APIs.
| |||||||||||
Register a callback to be invoked when the caller required to receive
the result of asynchronous APIs.
| |||||||||||
Register a callback to be invoked when the caller required to receive
supplementary information.
| |||||||||||
| Protected Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Called before the object's memory is reclaimed by the VM.
| |||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
Constant field signifies the success or no error occurred
Constant field signifies that error occurred and the reason is not known
To instantiate DrmManagerClient
| context | context of the caller |
|---|
Retrieves necessary information for register, unregister or rights acquisition.
| drmInfoRequest | Request information to retrieve drmInfo |
|---|
Executes given DrmInfoRequest and returns the rights information asynchronously.
This is a utility API which consists of acquireDrmInfo(DrmInfoRequest)
and processDrmInfo(DrmInfo).
It can be used if selected DRM agent can work with this combined sequences.
In case of some DRM schemes, such as OMA DRM, application needs to invoke
acquireDrmInfo(DrmInfoRequest) and processDrmInfo(DrmInfo), separately.
| drmInfoRequest | Request information to retrieve drmInfo |
|---|
Check whether the given mimetype or uri can be handled.
| uri | Content URI of the data to be handled. |
|---|---|
| mimeType | Mimetype of the object to be handled |
Check whether the given mimetype or path can be handled.
| path | Path of the content to be handled |
|---|---|
| mimeType | Mimetype of the object to be handled |
Check whether the given content has valid rights or not
| path | Path of the protected content |
|---|
Check whether the given content has valid rights or not for specified action.
| path | Path of the protected content |
|---|---|
| action | Action to perform |
Check whether the given content has valid rights or not for specified action.
| uri | The content URI of the data |
|---|---|
| action | Action to perform |
Check whether the given content has valid rights or not
| uri | The content URI of the data |
|---|
Informs the Drm Agent when there is no more data which need to be converted or when an error occurs. Upon successful conversion of the complete data, the agent will inform that where the header and body signature should be added. This signature appending is needed to integrity protect the converted file.
| convertId | Handle for the convert session |
|---|
Accepts and converts the input data which is part of DRM file. The resultant converted data and the status is returned in the DrmConvertedInfo object. This method will be called each time there are new block of data received by the application.
| convertId | Handle for the convert session |
|---|---|
| inputData | Input Data which need to be converted |
Retrieves informations about all the plug-ins registered with DrmFramework.
Get constraints information evaluated from DRM content
| path | Content path from where DRM constraints would be retrieved. |
|---|---|
| action | Actions defined in DrmStore.Action |
Get constraints information evaluated from DRM content
| uri | Content URI from where DRM constraints would be retrieved. |
|---|---|
| action | Actions defined in DrmStore.Action |
Retrieves the type of the protected object (content, rights, etc..) using specified uri or mimetype. At least one parameter should be non null to retrieve DRM object type
| uri | The content URI of the data |
|---|---|
| mimeType | Mimetype of the content or null. |
Retrieves the type of the protected object (content, rights, etc..) using specified path or mimetype. At least one parameter should be non null to retrieve DRM object type
| path | Path of the content or null. |
|---|---|
| mimeType | Mimetype of the content or null. |
Get metadata information from DRM content
| uri | Content URI from where DRM metadata would be retrieved. |
|---|
Get metadata information from DRM content
| path | Content path from where DRM metadata would be retrieved. |
|---|
Retrieves the mime type embedded inside the original content
| path | Path of the protected content |
|---|
Retrieves the mime type embedded inside the original content
| uri | The content URI of the data |
|---|
This API is for Forward Lock based DRM scheme. Each time the application tries to download a new DRM file which needs to be converted, then the application has to begin with calling this API.
| mimeType | Description/MIME type of the input data packet |
|---|
Executes given drm information based on its type
| drmInfo | Information needs to be processed |
|---|
Removes all the rights information of every plug-in associated with DRM framework. Will be used in master reset
Removes the rights associated with the given protected content
| path | Path of the protected content |
|---|
Removes the rights associated with the given protected content
| uri | The content URI of the data |
|---|
Save DRM rights to specified rights path and make association with content path.
In case of OMA or WM-DRM, rightsPath and contentPath could be null.
| drmRights | DrmRights to be saved |
|---|---|
| rightsPath | File path where rights to be saved |
| contentPath | File path where content was saved |
| IOException | if failed to save rights information in the given path |
|---|
Register a callback to be invoked when the caller required to receive error result of asynchronous APIs.
Register a callback to be invoked when the caller required to receive the result of asynchronous APIs.
Register a callback to be invoked when the caller required to receive supplementary information.
Called before the object's memory is reclaimed by the VM. This can only happen once the garbage collector has detected that the object is no longer reachable by any thread of the running application.
The method can be used to free system resources or perform other cleanup
before the object is garbage collected. The default implementation of the
method is empty, which is also expected by the VM, but subclasses can
override finalize() as required. Uncaught exceptions which are
thrown during the execution of this method cause it to terminate
immediately but are otherwise ignored.
Note that the VM does guarantee that finalize() is called at most
once for any object, but it doesn't guarantee when (if at all) finalize() will be called. For example, object B's finalize()
can delay the execution of object A's finalize() method and
therefore it can delay the reclamation of A's memory. To be safe, use a
ReferenceQueue, because it provides more control
over the way the VM deals with references during garbage collection.