summaryrefslogtreecommitdiffstats
path: root/media/tests/players
diff options
context:
space:
mode:
authorniko <niko@google.com>2009-07-16 16:39:53 -0700
committerniko <niko@google.com>2009-07-17 11:31:11 -0700
commit8994837f27e783a10f5cc038a7ae7595aabffdb6 (patch)
treeeb1a0cbb9e4d3c99f65a093574522e0016595046 /media/tests/players
parent3720cf2de9a86b4fb5583f190b183498f0ad3fc0 (diff)
downloadframeworks_base-8994837f27e783a10f5cc038a7ae7595aabffdb6.zip
frameworks_base-8994837f27e783a10f5cc038a7ae7595aabffdb6.tar.gz
frameworks_base-8994837f27e783a10f5cc038a7ae7595aabffdb6.tar.bz2
Added method to get metadata out of the player.
The method passes a list of metadata ids to be retrieved and a parcel where the metadata records should be appended. If the list of ids is empty, all the metadata should be returned.
Diffstat (limited to 'media/tests/players')
-rw-r--r--media/tests/players/invoke_mock_media_player.cpp12
1 files changed, 9 insertions, 3 deletions
diff --git a/media/tests/players/invoke_mock_media_player.cpp b/media/tests/players/invoke_mock_media_player.cpp
index f02298d..8d575a3 100644
--- a/media/tests/players/invoke_mock_media_player.cpp
+++ b/media/tests/players/invoke_mock_media_player.cpp
@@ -20,14 +20,17 @@
#include <string.h>
-#include "binder/Parcel.h"
-#include "media/MediaPlayerInterface.h"
-#include "utils/Errors.h"
+#include <binder/Parcel.h>
+#include <media/MediaPlayerInterface.h>
+#include <utils/Errors.h>
+using android::INVALID_OPERATION;
using android::ISurface;
using android::MediaPlayerBase;
+using android::MetadataType;
using android::OK;
using android::Parcel;
+using android::SortedVector;
using android::TEST_PLAYER;
using android::UNKNOWN_ERROR;
using android::player_type;
@@ -75,6 +78,9 @@ class Player: public MediaPlayerBase
virtual status_t setLooping(int loop) {return OK;}
virtual player_type playerType() {return TEST_PLAYER;}
virtual status_t invoke(const Parcel& request, Parcel *reply);
+ virtual status_t getMetadata(const SortedVector<MetadataType>& ids,
+ Parcel *records) {return INVALID_OPERATION;}
+
private:
// Take a request, copy it to the reply.
void ping(const Parcel& request, Parcel *reply);