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

Side by Side Diff: content/common/url_loader.mojom

Issue 2629513003: Implement CachedMetadata handling on MojoAsyncResourceHandler (Closed)
Patch Set: fix Created 3 years, 11 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 2016 The Chromium Authors. All rights reserved. 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 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 module content.mojom; 5 module content.mojom;
6 6
7 [Native] 7 [Native]
8 struct URLRequest; 8 struct URLRequest;
9 9
10 [Native] 10 [Native]
(...skipping 30 matching lines...) Expand all
41 // call FollowRedirect or cancel the request. 41 // call FollowRedirect or cancel the request.
42 OnReceiveRedirect(URLRequestRedirectInfo redirect_info, URLResponseHead head); 42 OnReceiveRedirect(URLRequestRedirectInfo redirect_info, URLResponseHead head);
43 43
44 // Called when some data from a resource request has been downloaded to the 44 // Called when some data from a resource request has been downloaded to the
45 // file. This is only called in the 'download_to_file' case and replaces 45 // file. This is only called in the 'download_to_file' case and replaces
46 // OnStartLoadingResponseBody in the call sequence in that case. 46 // OnStartLoadingResponseBody in the call sequence in that case.
47 // TODO(yhirano): Remove |encoded_length| and use OnTransferSizeUpdated 47 // TODO(yhirano): Remove |encoded_length| and use OnTransferSizeUpdated
48 // instead. 48 // instead.
49 OnDataDownloaded(int64 data_length, int64 encoded_length); 49 OnDataDownloaded(int64 data_length, int64 encoded_length);
50 50
51 // Called when cached metadata from a resource request is ready.
52 OnReceiveCachedMetadata(array<uint8> data);
53
51 // Called when the transfer size is updated. This is only called if 54 // Called when the transfer size is updated. This is only called if
52 // |report_raw_headers| is set and |download_to_file| is unset in the request. 55 // |report_raw_headers| is set and |download_to_file| is unset in the request.
53 // The transfer size is the length of the response (including both headers 56 // The transfer size is the length of the response (including both headers
54 // and the body) over the network. |transfer_size_diff| is the difference from 57 // and the body) over the network. |transfer_size_diff| is the difference from
55 // the value previously reported one (including the one in OnReceiveResponse 58 // the value previously reported one (including the one in OnReceiveResponse
56 // and OnReceiveRedirect). It must be positive. 59 // and OnReceiveRedirect). It must be positive.
57 // TODO(yhirano): Dispatch this notification even when |download_to_file| is 60 // TODO(yhirano): Dispatch this notification even when |download_to_file| is
58 // set. 61 // set.
59 // TODO(yhirano): Consider using an unsigned type. 62 // TODO(yhirano): Consider using an unsigned type.
60 OnTransferSizeUpdated(int32 transfer_size_diff); 63 OnTransferSizeUpdated(int32 transfer_size_diff);
61 64
62 // Called when the loader starts loading response body. 65 // Called when the loader starts loading response body.
63 OnStartLoadingResponseBody(handle<data_pipe_consumer> body); 66 OnStartLoadingResponseBody(handle<data_pipe_consumer> body);
64 67
65 // Called when the loading completes. No notification will be dispatched for 68 // Called when the loading completes. No notification will be dispatched for
66 // this client after this message arrives. 69 // this client after this message arrives.
67 OnComplete(URLLoaderStatus completion_status); 70 OnComplete(URLLoaderStatus completion_status);
68 }; 71 };
69 72
OLDNEW
« no previous file with comments | « content/child/url_loader_client_impl_unittest.cc ('k') | content/renderer/service_worker/service_worker_context_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698