blob: cbecc4327a224fe7cf9e7b11061ebc6f935a0551 [file] [log] [blame]
Adam Lesinski927634a2014-06-04 15:14:03 -07001/*
2 * Copyright (C) 2014 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#include "NoOpDrmManagerClientImpl.h"
18
19namespace android {
20
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070021void NoOpDrmManagerClientImpl::remove(int /* uniqueId */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070022}
23
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070024void NoOpDrmManagerClientImpl::addClient(int /* uniqueId */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070025}
26
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070027void NoOpDrmManagerClientImpl::removeClient(int /* uniqueId */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070028}
29
30status_t NoOpDrmManagerClientImpl::setOnInfoListener(
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070031 int /* uniqueId */,
32 const sp<DrmManagerClient::OnInfoListener>& /* infoListener */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070033 return UNKNOWN_ERROR;
34}
35
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070036DrmConstraints* NoOpDrmManagerClientImpl::getConstraints(int /* uniqueId */,
37 const String8* /* path */, const int /* action */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070038 return NULL;
39}
40
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070041DrmMetadata* NoOpDrmManagerClientImpl::getMetadata(int /* uniqueId */,
42 const String8* /* path */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070043 return NULL;
44}
45
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070046bool NoOpDrmManagerClientImpl::canHandle(int /* uniqueId */,
47 const String8& /* path */, const String8& /* mimeType */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070048 return false;
49}
50
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070051DrmInfoStatus* NoOpDrmManagerClientImpl::processDrmInfo(int /* uniqueId */,
52 const DrmInfo* /* drmInfo */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070053 return NULL;
54}
55
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070056DrmInfo* NoOpDrmManagerClientImpl::acquireDrmInfo(int /* uniqueId */,
57 const DrmInfoRequest* /* drmInfoRequest */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070058 return NULL;
59}
60
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070061status_t NoOpDrmManagerClientImpl::saveRights(int /* uniqueId */,
62 const DrmRights& /* drmRights */, const String8& /* rightsPath */,
63 const String8& /* contentPath */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070064 return UNKNOWN_ERROR;
65}
66
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070067String8 NoOpDrmManagerClientImpl::getOriginalMimeType(int /* uniqueId */,
68 const String8& /* path */, int /* fd */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070069 return String8();
70}
71
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070072int NoOpDrmManagerClientImpl::getDrmObjectType(int /* uniqueId */,
73 const String8& /* path */, const String8& /* mimeType */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070074 return -1;
75}
76
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070077int NoOpDrmManagerClientImpl::checkRightsStatus(int /* uniqueId */,
78 const String8& /* path */, int /* action */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070079 return -1;
80}
81
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070082status_t NoOpDrmManagerClientImpl::consumeRights(int /* uniqueId */,
83 sp<DecryptHandle>& /* decryptHandle */, int /* action */,
84 bool /* reserve */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070085 return UNKNOWN_ERROR;
86}
87
88status_t NoOpDrmManagerClientImpl::setPlaybackStatus(
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070089 int /* uniqueId */, sp<DecryptHandle>& /* decryptHandle */,
90 int /* playbackStatus */, int64_t /* position */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070091 return UNKNOWN_ERROR;
92}
93
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -070094bool NoOpDrmManagerClientImpl::validateAction(int /* uniqueId */,
95 const String8& /* path */, int /* action */,
96 const ActionDescription& /* description */) {
Adam Lesinski927634a2014-06-04 15:14:03 -070097 return false;
98}
99
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700100status_t NoOpDrmManagerClientImpl::removeRights(int /* uniqueId */,
101 const String8& /* path */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700102 return UNKNOWN_ERROR;
103}
104
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700105status_t NoOpDrmManagerClientImpl::removeAllRights(int /* uniqueId */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700106 return UNKNOWN_ERROR;
107}
108
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700109int NoOpDrmManagerClientImpl::openConvertSession(int /* uniqueId */,
110 const String8& /* mimeType */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700111 return -1;
112}
113
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700114DrmConvertedStatus* NoOpDrmManagerClientImpl::convertData(int /* uniqueId */,
115 int /* convertId */, const DrmBuffer* /* inputData */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700116 return NULL;
117}
118
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700119DrmConvertedStatus* NoOpDrmManagerClientImpl::closeConvertSession(
120 int /* uniqueId */, int /* convertId */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700121 return NULL;
122}
123
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700124status_t NoOpDrmManagerClientImpl::getAllSupportInfo(int /* uniqueId */,
125 int* /* length */, DrmSupportInfo** /* drmSupportInfoArray */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700126 return UNKNOWN_ERROR;
127}
128
129sp<DecryptHandle> NoOpDrmManagerClientImpl::openDecryptSession(
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700130 int /* uniqueId */, int /* fd */, off64_t /* offset */,
131 off64_t /* length */, const char* /* mime */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700132 return NULL;
133}
134
135sp<DecryptHandle> NoOpDrmManagerClientImpl::openDecryptSession(
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700136 int /* uniqueId */, const char* /* uri */, const char* /* mime */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700137 return NULL;
138}
139
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700140sp<DecryptHandle> NoOpDrmManagerClientImpl::openDecryptSession(int /* uniqueId */,
141 const DrmBuffer& /* buf */, const String8& /* mimeType */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700142 return NULL;
143}
144
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700145status_t NoOpDrmManagerClientImpl::closeDecryptSession(int /* uniqueId */,
146 sp<DecryptHandle>& /* decryptHandle */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700147 return UNKNOWN_ERROR;
148}
149
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700150status_t NoOpDrmManagerClientImpl::initializeDecryptUnit(int /* uniqueId */,
151 sp<DecryptHandle>& /* decryptHandle */, int /* decryptUnitId */,
152 const DrmBuffer* /* headerInfo */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700153 return UNKNOWN_ERROR;
154}
155
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700156status_t NoOpDrmManagerClientImpl::decrypt(int /* uniqueId */,
157 sp<DecryptHandle>& /* decryptHandle */, int /* decryptUnitId */,
158 const DrmBuffer* /* encBuffer */, DrmBuffer** /* decBuffer */,
159 DrmBuffer* /* IV */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700160 return UNKNOWN_ERROR;
161}
162
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700163status_t NoOpDrmManagerClientImpl::finalizeDecryptUnit(int /* uniqueId */,
164 sp<DecryptHandle>& /* decryptHandle */, int /* decryptUnitId */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700165 return UNKNOWN_ERROR;
166}
167
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700168ssize_t NoOpDrmManagerClientImpl::pread(int /* uniqueId */,
169 sp<DecryptHandle>& /* decryptHandle */,
170 void* /* buffer */, ssize_t /* numBytes */, off64_t /* offset */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700171 return -1;
172}
173
Mark Salyzyn5a8dbe72014-06-23 14:13:52 -0700174status_t NoOpDrmManagerClientImpl::notify(const DrmInfoEvent& /* event */) {
Adam Lesinski927634a2014-06-04 15:14:03 -0700175 return UNKNOWN_ERROR;
176}
177
178}