OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2016 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_PUBLIC_COMMON_RESOURCE_REQUEST_BODY_H_ | |
6 #define CONTENT_PUBLIC_COMMON_RESOURCE_REQUEST_BODY_H_ | |
7 | |
8 #include <stdint.h> | |
9 | |
10 #include <vector> | |
11 | |
12 #include "base/macros.h" | |
13 #include "base/memory/ref_counted.h" | |
14 #include "content/common/content_export.h" | |
15 | |
16 namespace content { | |
17 | |
18 // ResourceRequestBody represents body (i.e. upload data) of a HTTP request. | |
19 // | |
20 // This class is intentionally opaque: | |
21 // - //content embedders cannot inspect payload of ResourceRequestBody (i.e. | |
Charlie Reis
2016/06/08 22:43:20
nit: Embedders
(No need to mention //content here.
Łukasz Anforowicz
2016/06/08 23:22:38
Done.
| |
22 // only the //content layer can decompose ResourceRequestBody into references | |
23 // to file ranges, byte vectors, blob uris, etc.) | |
Charlie Reis
2016/06/08 22:43:20
nit: Add a period after close paren. Same below.
Łukasz Anforowicz
2016/06/08 23:22:38
Done.
| |
24 // - //content embedders can get instances of ResourceRequestBody only by | |
25 // receiving an instance created inside //content layer (e.g. passed to the | |
26 // //content embedder via content::OpenURLParams) | |
Łukasz Anforowicz
2016/06/08 16:51:56
This will have to be amended in the next CL to say
Charlie Reis
2016/06/08 22:43:20
Acknowledged.
| |
27 // - //content embedders typically end up passing ResourceRequestBody back into | |
28 // the //content layer via content::NavigationController::LoarUrlParams. | |
29 class CONTENT_EXPORT ResourceRequestBody | |
30 : public base::RefCountedThreadSafe<ResourceRequestBody> { | |
31 protected: | |
32 ResourceRequestBody(); | |
33 virtual ~ResourceRequestBody(); | |
34 | |
35 private: | |
36 friend class base::RefCountedThreadSafe<ResourceRequestBody>; | |
37 DISALLOW_COPY_AND_ASSIGN(ResourceRequestBody); | |
38 }; | |
39 | |
40 } // namespace content | |
41 | |
42 #endif // CONTENT_PUBLIC_COMMON_RESOURCE_REQUEST_BODY_H_ | |
OLD | NEW |