OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef WEBKIT_PLUGINS_PPAPI_PPB_URL_RESPONSE_INFO_IMPL_H_ | 5 #ifndef WEBKIT_PLUGINS_PPAPI_PPB_URL_RESPONSE_INFO_IMPL_H_ |
6 #define WEBKIT_PLUGINS_PPAPI_PPB_URL_RESPONSE_INFO_IMPL_H_ | 6 #define WEBKIT_PLUGINS_PPAPI_PPB_URL_RESPONSE_INFO_IMPL_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 | 23 |
24 class PPB_URLResponseInfo_Impl | 24 class PPB_URLResponseInfo_Impl |
25 : public Resource, | 25 : public Resource, |
26 public ::ppapi::thunk::PPB_URLResponseInfo_API { | 26 public ::ppapi::thunk::PPB_URLResponseInfo_API { |
27 public: | 27 public: |
28 explicit PPB_URLResponseInfo_Impl(PluginInstance* instance); | 28 explicit PPB_URLResponseInfo_Impl(PluginInstance* instance); |
29 virtual ~PPB_URLResponseInfo_Impl(); | 29 virtual ~PPB_URLResponseInfo_Impl(); |
30 | 30 |
31 bool Initialize(const WebKit::WebURLResponse& response); | 31 bool Initialize(const WebKit::WebURLResponse& response); |
32 | 32 |
33 // ResourceObjectBase overrides. | 33 // Resource overrides. |
34 virtual PPB_URLResponseInfo_API* AsPPB_URLResponseInfo_API() OVERRIDE; | 34 virtual PPB_URLResponseInfo_API* AsPPB_URLResponseInfo_API() OVERRIDE; |
35 | 35 |
36 // PPB_URLResponseInfo_API implementation. | 36 // PPB_URLResponseInfo_API implementation. |
37 virtual PP_Var GetProperty(PP_URLResponseProperty property) OVERRIDE; | 37 virtual PP_Var GetProperty(PP_URLResponseProperty property) OVERRIDE; |
38 virtual PP_Resource GetBodyAsFileRef() OVERRIDE; | 38 virtual PP_Resource GetBodyAsFileRef() OVERRIDE; |
39 | 39 |
40 PPB_FileRef_Impl* body() { return body_; } | 40 PPB_FileRef_Impl* body() { return body_; } |
41 std::string redirect_url() { return redirect_url_; } | 41 std::string redirect_url() { return redirect_url_; } |
42 | 42 |
43 private: | 43 private: |
44 std::string url_; | 44 std::string url_; |
45 std::string headers_; | 45 std::string headers_; |
46 int32_t status_code_; | 46 int32_t status_code_; |
47 std::string status_text_; | 47 std::string status_text_; |
48 std::string redirect_url_; | 48 std::string redirect_url_; |
49 scoped_refptr<PPB_FileRef_Impl> body_; | 49 scoped_refptr<PPB_FileRef_Impl> body_; |
50 | 50 |
51 DISALLOW_COPY_AND_ASSIGN(PPB_URLResponseInfo_Impl); | 51 DISALLOW_COPY_AND_ASSIGN(PPB_URLResponseInfo_Impl); |
52 }; | 52 }; |
53 | 53 |
54 } // namespace ppapi | 54 } // namespace ppapi |
55 } // namespace webkit | 55 } // namespace webkit |
56 | 56 |
57 #endif // WEBKIT_PLUGINS_PPAPI_PPB_URL_RESPONSE_INFO_IMPL_H_ | 57 #endif // WEBKIT_PLUGINS_PPAPI_PPB_URL_RESPONSE_INFO_IMPL_H_ |
OLD | NEW |