| Index: content/browser/loader/async_resource_handler.h
|
| diff --git a/content/browser/loader/async_resource_handler.h b/content/browser/loader/async_resource_handler.h
|
| index 0991021336043dc8b4d990a24352ca6408aaa22d..d8ce27df83c1b788e7dec0a0799732c7916b0470 100644
|
| --- a/content/browser/loader/async_resource_handler.h
|
| +++ b/content/browser/loader/async_resource_handler.h
|
| @@ -14,6 +14,8 @@
|
| #include "base/timer/timer.h"
|
| #include "content/browser/loader/resource_handler.h"
|
| #include "content/browser/loader/resource_message_delegate.h"
|
| +#include "mojo/message_pump/handle_watcher.h"
|
| +#include "mojo/public/cpp/system/data_pipe.h"
|
| #include "net/base/io_buffer.h"
|
| #include "url/gurl.h"
|
|
|
| @@ -34,7 +36,8 @@ class AsyncResourceHandler : public ResourceHandler,
|
| public ResourceMessageDelegate {
|
| public:
|
| AsyncResourceHandler(net::URLRequest* request,
|
| - ResourceDispatcherHostImpl* rdh);
|
| + ResourceDispatcherHostImpl* rdh,
|
| + bool using_mojo_data_handle);
|
| ~AsyncResourceHandler() override;
|
|
|
| bool OnMessageReceived(const IPC::Message& message) override;
|
| @@ -57,6 +60,7 @@ class AsyncResourceHandler : public ResourceHandler,
|
|
|
| private:
|
| class InliningHelper;
|
| + class MojoHelper;
|
|
|
| // IPC message handlers:
|
| void OnFollowRedirect(int request_id);
|
| @@ -71,6 +75,7 @@ class AsyncResourceHandler : public ResourceHandler,
|
| bool CheckForSufficientResource();
|
| int CalculateEncodedDataLengthToReport();
|
| void RecordHistogram();
|
| + void OnWritable(MojoResult result);
|
|
|
| scoped_refptr<ResourceBuffer> buffer_;
|
| ResourceDispatcherHostImpl* rdh_;
|
| @@ -86,6 +91,7 @@ class AsyncResourceHandler : public ResourceHandler,
|
| bool has_checked_for_sufficient_resources_;
|
| bool sent_received_response_msg_;
|
| bool sent_data_buffer_msg_;
|
| + bool using_mojo_data_handle_;
|
|
|
| std::unique_ptr<InliningHelper> inlining_helper_;
|
| base::TimeTicks response_started_ticks_;
|
| @@ -97,6 +103,8 @@ class AsyncResourceHandler : public ResourceHandler,
|
|
|
| int64_t reported_transfer_size_;
|
|
|
| + std::unique_ptr<MojoHelper> mojo_helper_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(AsyncResourceHandler);
|
| };
|
|
|
|
|