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

Side by Side Diff: webkit/common/appcache/appcache_interfaces.cc

Issue 164933002: Expose details for appcache error events [Chromium] (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix merge glitch, complete a rename Created 6 years, 8 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 | « webkit/common/appcache/appcache_interfaces.h ('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 "webkit/common/appcache/appcache_interfaces.h" 5 #include "webkit/common/appcache/appcache_interfaces.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/strings/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "net/url_request/url_request.h" 10 #include "net/url_request/url_request.h"
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 is_intercept(false), 42 is_intercept(false),
43 is_fallback(false), 43 is_fallback(false),
44 is_foreign(false), 44 is_foreign(false),
45 is_explicit(false), 45 is_explicit(false),
46 response_id(kNoResponseId) { 46 response_id(kNoResponseId) {
47 } 47 }
48 48
49 AppCacheResourceInfo::~AppCacheResourceInfo() { 49 AppCacheResourceInfo::~AppCacheResourceInfo() {
50 } 50 }
51 51
52 ErrorDetails::ErrorDetails()
53 : message(),
54 reason(UNKNOWN_ERROR),
55 url(),
56 status(0),
57 is_cross_origin(false) {}
58
59 ErrorDetails::ErrorDetails(
60 std::string in_message,
61 ErrorReason in_reason,
62 GURL in_url,
63 int in_status,
64 bool in_is_cross_origin)
65 : message(in_message),
66 reason(in_reason),
67 url(in_url),
68 status(in_status),
69 is_cross_origin(in_is_cross_origin) {}
70
71 ErrorDetails::~ErrorDetails() {}
72
52 Namespace::Namespace() 73 Namespace::Namespace()
53 : type(FALLBACK_NAMESPACE), 74 : type(FALLBACK_NAMESPACE),
54 is_pattern(false), 75 is_pattern(false),
55 is_executable(false) { 76 is_executable(false) {
56 } 77 }
57 78
58 Namespace::Namespace( 79 Namespace::Namespace(
59 NamespaceType type, const GURL& url, const GURL& target, bool is_pattern) 80 NamespaceType type, const GURL& url, const GURL& target, bool is_pattern)
60 : type(type), 81 : type(type),
61 namespace_url(url), 82 namespace_url(url),
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 bool IsMethodSupported(const std::string& method) { 129 bool IsMethodSupported(const std::string& method) {
109 return (method == kHttpGETMethod) || (method == kHttpHEADMethod); 130 return (method == kHttpGETMethod) || (method == kHttpHEADMethod);
110 } 131 }
111 132
112 bool IsSchemeAndMethodSupported(const net::URLRequest* request) { 133 bool IsSchemeAndMethodSupported(const net::URLRequest* request) {
113 return IsSchemeSupported(request->url()) && 134 return IsSchemeSupported(request->url()) &&
114 IsMethodSupported(request->method()); 135 IsMethodSupported(request->method());
115 } 136 }
116 137
117 } // namespace appcache 138 } // namespace appcache
OLDNEW
« no previous file with comments | « webkit/common/appcache/appcache_interfaces.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698