Chromium Code Reviews| Index: content/child/shared_memory_data_consumer_handle.h |
| diff --git a/content/child/shared_memory_data_consumer_handle.h b/content/child/shared_memory_data_consumer_handle.h |
| index 6d74178f5cda317e5fdc1e0c6e85e5d92756ad25..cd760acd209784b2e30f35e7fa3ef3ec62ed48ed 100644 |
| --- a/content/child/shared_memory_data_consumer_handle.h |
| +++ b/content/child/shared_memory_data_consumer_handle.h |
| @@ -5,6 +5,7 @@ |
| #ifndef CONTENT_CHILD_SHARED_MEMORY_DATA_CONSUMER_HANDLE_H_ |
| #define CONTENT_CHILD_SHARED_MEMORY_DATA_CONSUMER_HANDLE_H_ |
| +#include "base/callback.h" |
| #include "base/memory/ref_counted.h" |
| #include "base/memory/scoped_ptr.h" |
| #include "content/common/content_export.h" |
| @@ -59,8 +60,17 @@ class CONTENT_EXPORT SharedMemoryDataConsumerHandle final |
| DISALLOW_COPY_AND_ASSIGN(ReaderImpl); |
| }; |
| + // Creates a handle and a writer associated with the handle. The created |
| + // writer should be used on the calling thread. |
| SharedMemoryDataConsumerHandle(BackpressureMode mode, |
| scoped_ptr<Writer>* writer); |
| + // |on_clear| will be called asynchronously on the calling thread when both |
| + // the associated handle and the reader are destructed. |
|
hiroshige
2015/06/22 18:23:16
Better name (here and related method/member names)
yhirano
2015/06/23 05:28:38
Done.
|
| + // The callback will be reset in the internal context when |Close| or |Error| |
| + // on the writer is called. |
|
hiroshige
2015/06/22 18:23:16
How about "will be reset in the internal context w
yhirano
2015/06/23 05:28:38
Done.
|
| + SharedMemoryDataConsumerHandle(BackpressureMode mode, |
| + const base::Closure& on_clear, |
| + scoped_ptr<Writer>* writer); |
| virtual ~SharedMemoryDataConsumerHandle(); |
| scoped_ptr<Reader> ObtainReader(Client* client); |