• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright 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 CONTENT_RENDERER_PEPPER_URL_RESPONSE_INFO_UTIL_H_
6 #define CONTENT_RENDERER_PEPPER_URL_RESPONSE_INFO_UTIL_H_
7 
8 #include "base/callback.h"
9 #include "ppapi/c/pp_instance.h"
10 #include "ppapi/shared_impl/url_response_info_data.h"
11 
12 namespace blink {
13 class WebURLResponse;
14 }
15 
16 namespace content {
17 class RendererPpapiHostImpl;
18 
19 typedef base::Callback<void(const ppapi::URLResponseInfoData&)>
20     DataFromWebURLResponseCallback;
21 
22 // The returned object will have one plugin reference to the "body_as_file_ref"
23 // if it's non-null. It's expected that the result of this function will be
24 // passed to the plugin.
25 void DataFromWebURLResponse(RendererPpapiHostImpl* host_impl,
26                             PP_Instance pp_instance,
27                             const blink::WebURLResponse& response,
28                             const DataFromWebURLResponseCallback& callback);
29 
30 }  // namespace content
31 
32 #endif  // CONTENT_RENDERER_PEPPER_URL_RESPONSE_INFO_UTIL_H_
33