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

Side by Side Diff: webkit/appcache/appcache_url_request_job.cc

Issue 10542153: NetLogEventParameter to Callback refactoring 11. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Response to comments Created 8 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « net/base/net_log.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include <vector> 5 #include <vector>
6 6
7 #include "webkit/appcache/appcache_url_request_job.h" 7 #include "webkit/appcache/appcache_url_request_job.h"
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 case NETWORK_DELIVERY: 83 case NETWORK_DELIVERY:
84 // To fallthru to the network, we restart the request which will 84 // To fallthru to the network, we restart the request which will
85 // cause a new job to be created to retrieve the resource from the 85 // cause a new job to be created to retrieve the resource from the
86 // network. Our caller is responsible for arranging to not re-intercept 86 // network. Our caller is responsible for arranging to not re-intercept
87 // the same request. 87 // the same request.
88 NotifyRestartRequired(); 88 NotifyRestartRequired();
89 break; 89 break;
90 90
91 case ERROR_DELIVERY: 91 case ERROR_DELIVERY:
92 request()->net_log().AddEvent( 92 request()->net_log().AddEvent(
93 net::NetLog::TYPE_APPCACHE_DELIVERING_ERROR_RESPONSE, NULL); 93 net::NetLog::TYPE_APPCACHE_DELIVERING_ERROR_RESPONSE);
94 NotifyStartError(net::URLRequestStatus(net::URLRequestStatus::FAILED, 94 NotifyStartError(net::URLRequestStatus(net::URLRequestStatus::FAILED,
95 net::ERR_FAILED)); 95 net::ERR_FAILED));
96 break; 96 break;
97 97
98 case APPCACHED_DELIVERY: 98 case APPCACHED_DELIVERY:
99 request()->net_log().AddEvent( 99 request()->net_log().AddEvent(
100 is_fallback_ ? 100 is_fallback_ ?
101 net::NetLog::TYPE_APPCACHE_DELIVERING_FALLBACK_RESPONSE : 101 net::NetLog::TYPE_APPCACHE_DELIVERING_FALLBACK_RESPONSE :
102 net::NetLog::TYPE_APPCACHE_DELIVERING_CACHED_RESPONSE, 102 net::NetLog::TYPE_APPCACHE_DELIVERING_CACHED_RESPONSE);
103 NULL);
104 storage_->LoadResponseInfo( 103 storage_->LoadResponseInfo(
105 manifest_url_, group_id_, entry_.response_id(), this); 104 manifest_url_, group_id_, entry_.response_id(), this);
106 break; 105 break;
107 106
108 default: 107 default:
109 NOTREACHED(); 108 NOTREACHED();
110 break; 109 break;
111 } 110 }
112 } 111 }
113 112
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 return; 283 return;
285 } 284 }
286 285
287 // If multiple ranges are requested, we play dumb and 286 // If multiple ranges are requested, we play dumb and
288 // return the entire response with 200 OK. 287 // return the entire response with 200 OK.
289 if (ranges.size() == 1U) 288 if (ranges.size() == 1U)
290 range_requested_ = ranges[0]; 289 range_requested_ = ranges[0];
291 } 290 }
292 291
293 } // namespace appcache 292 } // namespace appcache
OLDNEW
« no previous file with comments | « net/base/net_log.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698