Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(39)

Side by Side Diff: media/base/android/media_url_interceptor.h

Issue 411353002: MediaUrlInterceptor for embedders to handle custom urls. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Nits Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « media/base/android/media_source_player_unittest.cc ('k') | media/media.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved.
xhwang 2014/07/29 17:08:20 nit: (c) not needed
Ignacio Solla 2014/07/30 08:45:12 Done.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef MEDIA_BASE_ANDROID_MEDIA_URL_INTERCEPTOR_H_
6 #define MEDIA_BASE_ANDROID_MEDIA_URL_INTERCEPTOR_H_
7
8 #include <string>
9
10 #include "base/android/jni_android.h"
11 #include "media/base/media_export.h"
12
13 namespace media {
14
15 // Interceptor for content embedders to handle custom media urls
16 // and translate them into files containing media.
17 class MEDIA_EXPORT MediaUrlInterceptor {
18 public:
19 virtual ~MediaUrlInterceptor() {};
20
21 // Returns true if the embedder has intercepted the url and
22 // false otherwise.
23 // Output arguments (only when the url has been intercepted):
24 // - |fd|: file descriptor to the file containing the media element.
25 // - |offset|: offset in bytes from the start of the file to the
26 // media element.
27 // - |size|: size in bytes of the media element.
28 virtual bool Intercept(const std::string& url,
29 int* fd,
30 int64* offset,
31 int64* size) const = 0;
32 };
33
34 } // namespace media
35
36 #endif // MEDIA_BASE_ANDROID_MEDIA_URL_INTERCEPTOR_H_
OLDNEW
« no previous file with comments | « media/base/android/media_source_player_unittest.cc ('k') | media/media.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698