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

Side by Side Diff: content/child/shared_memory_received_data_factory.h

Issue 2105713002: Render process changes for ResourceTiming sizes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@resource_timing_sizes_browser_process
Patch Set: Fixes from ksakamoto review Created 4 years, 5 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 CONTENT_CHILD_SHARED_MEMORY_RECEIVED_DATA_FACTORY_H_ 5 #ifndef CONTENT_CHILD_SHARED_MEMORY_RECEIVED_DATA_FACTORY_H_
6 #define CONTENT_CHILD_SHARED_MEMORY_RECEIVED_DATA_FACTORY_H_ 6 #define CONTENT_CHILD_SHARED_MEMORY_RECEIVED_DATA_FACTORY_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 15 matching lines...) Expand all
26 26
27 class CONTENT_EXPORT SharedMemoryReceivedDataFactory final 27 class CONTENT_EXPORT SharedMemoryReceivedDataFactory final
28 : public base::RefCounted<SharedMemoryReceivedDataFactory> { 28 : public base::RefCounted<SharedMemoryReceivedDataFactory> {
29 public: 29 public:
30 SharedMemoryReceivedDataFactory(IPC::Sender* message_sender, 30 SharedMemoryReceivedDataFactory(IPC::Sender* message_sender,
31 int request_id, 31 int request_id,
32 linked_ptr<base::SharedMemory> memory); 32 linked_ptr<base::SharedMemory> memory);
33 33
34 std::unique_ptr<RequestPeer::ReceivedData> Create(int offset, 34 std::unique_ptr<RequestPeer::ReceivedData> Create(int offset,
35 int length, 35 int length,
36 int encoded_length); 36 int encoded_length,
kinuko 2016/07/04 04:08:12 nit: encoded_data_length
Adam Rice 2016/07/04 06:33:42 Done.
37 int encoded_body_length);
37 38
38 // Stops this factory. After calling this function, releasing issued data 39 // Stops this factory. After calling this function, releasing issued data
39 // won't send ack signal to the browser process. 40 // won't send ack signal to the browser process.
40 void Stop(); 41 void Stop();
41 42
42 private: 43 private:
43 // Here TicketId is uint32_t, but a factory may issue more data by reusing id. 44 // Here TicketId is uint32_t, but a factory may issue more data by reusing id.
44 using TicketId = uint32_t; 45 using TicketId = uint32_t;
45 46
46 class SharedMemoryReceivedData; 47 class SharedMemoryReceivedData;
(...skipping 15 matching lines...) Expand all
62 bool is_stopped_; 63 bool is_stopped_;
63 // Just to keep the payload alive while issued data is alive. 64 // Just to keep the payload alive while issued data is alive.
64 linked_ptr<base::SharedMemory> memory_; 65 linked_ptr<base::SharedMemory> memory_;
65 66
66 DISALLOW_COPY_AND_ASSIGN(SharedMemoryReceivedDataFactory); 67 DISALLOW_COPY_AND_ASSIGN(SharedMemoryReceivedDataFactory);
67 }; 68 };
68 69
69 } // namespace content 70 } // namespace content
70 71
71 #endif // CONTENT_CHILD_SHARED_MEMORY_RECEIVED_DATA_FACTORY_H_ 72 #endif // CONTENT_CHILD_SHARED_MEMORY_RECEIVED_DATA_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698