OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
| 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_RESOURCE_GETTER_H_ |
| 6 #define MEDIA_BASE_ANDROID_MEDIA_RESOURCE_GETTER_H_ |
| 7 |
| 8 #include <string> |
| 9 |
| 10 #include "base/callback.h" |
| 11 #include "base/files/file_path.h" |
| 12 #include "googleurl/src/gurl.h" |
| 13 #include "media/base/media_export.h" |
| 14 |
| 15 namespace media { |
| 16 |
| 17 // Class for asynchronously retrieving resources for a media URL. All callbacks |
| 18 // are executed on the caller's thread. |
| 19 class MEDIA_EXPORT MediaResourceGetter { |
| 20 public: |
| 21 typedef base::Callback<void(const std::string&)> GetCookieCB; |
| 22 typedef base::Callback<void(const std::string&)> GetPlatformPathCB; |
| 23 virtual ~MediaResourceGetter(); |
| 24 |
| 25 // Method for getting the cookies for a given URL. |
| 26 virtual void GetCookies(const GURL& url, |
| 27 const GURL& first_party_for_cookies, |
| 28 const GetCookieCB& callback) = 0; |
| 29 |
| 30 // Method for getting the platform path from a file system URL. |
| 31 virtual void GetPlatformPathFromFileSystemURL( |
| 32 const GURL& url, |
| 33 const GetPlatformPathCB& callback) = 0; |
| 34 }; |
| 35 |
| 36 } // namespace media |
| 37 |
| 38 #endif // MEDIA_BASE_ANDROID_MEDIA_RESOURCE_GETTER_H_ |
OLD | NEW |