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

Side by Side Diff: Source/core/fetch/ResourceLoader.h

Issue 531553002: Remove dead content sniffing code (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 3 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
« no previous file with comments | « Source/core/fetch/ResourceFetcher.cpp ('k') | Source/core/fetch/ResourceLoaderOptions.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2005, 2006, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2005, 2006, 2011 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 virtual void willSendRequest(blink::WebURLLoader*, blink::WebURLRequest&, co nst blink::WebURLResponse& redirectResponse) OVERRIDE; 77 virtual void willSendRequest(blink::WebURLLoader*, blink::WebURLRequest&, co nst blink::WebURLResponse& redirectResponse) OVERRIDE;
78 virtual void didSendData(blink::WebURLLoader*, unsigned long long bytesSent, unsigned long long totalBytesToBeSent) OVERRIDE; 78 virtual void didSendData(blink::WebURLLoader*, unsigned long long bytesSent, unsigned long long totalBytesToBeSent) OVERRIDE;
79 virtual void didReceiveResponse(blink::WebURLLoader*, const blink::WebURLRes ponse&) OVERRIDE; 79 virtual void didReceiveResponse(blink::WebURLLoader*, const blink::WebURLRes ponse&) OVERRIDE;
80 virtual void didReceiveData(blink::WebURLLoader*, const char*, int, int enco dedDataLength) OVERRIDE; 80 virtual void didReceiveData(blink::WebURLLoader*, const char*, int, int enco dedDataLength) OVERRIDE;
81 virtual void didReceiveCachedMetadata(blink::WebURLLoader*, const char* data , int length) OVERRIDE; 81 virtual void didReceiveCachedMetadata(blink::WebURLLoader*, const char* data , int length) OVERRIDE;
82 virtual void didFinishLoading(blink::WebURLLoader*, double finishTime, int64 encodedDataLength) OVERRIDE; 82 virtual void didFinishLoading(blink::WebURLLoader*, double finishTime, int64 encodedDataLength) OVERRIDE;
83 virtual void didFail(blink::WebURLLoader*, const blink::WebURLError&) OVERRI DE; 83 virtual void didFail(blink::WebURLLoader*, const blink::WebURLError&) OVERRI DE;
84 virtual void didDownloadData(blink::WebURLLoader*, int, int) OVERRIDE; 84 virtual void didDownloadData(blink::WebURLLoader*, int, int) OVERRIDE;
85 85
86 const KURL& url() const { return m_request.url(); } 86 const KURL& url() const { return m_request.url(); }
87 bool shouldSniffContent() const { return m_options.sniffContent == SniffCont ent; }
88 bool isLoadedBy(ResourceLoaderHost*) const; 87 bool isLoadedBy(ResourceLoaderHost*) const;
89 88
90 bool reachedTerminalState() const { return m_state == Terminated; } 89 bool reachedTerminalState() const { return m_state == Terminated; }
91 const ResourceRequest& request() const { return m_request; } 90 const ResourceRequest& request() const { return m_request; }
92 91
93 class RequestCountTracker { 92 class RequestCountTracker {
94 public: 93 public:
95 RequestCountTracker(ResourceLoaderHost*, Resource*); 94 RequestCountTracker(ResourceLoaderHost*, Resource*);
96 RequestCountTracker(const RequestCountTracker&); 95 RequestCountTracker(const RequestCountTracker&);
97 ~RequestCountTracker(); 96 ~RequestCountTracker();
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 // Used for sanity checking to make sure we don't experience illegal state 145 // Used for sanity checking to make sure we don't experience illegal state
147 // transitions. 146 // transitions.
148 ConnectionState m_connectionState; 147 ConnectionState m_connectionState;
149 148
150 OwnPtr<RequestCountTracker> m_requestCountTracker; 149 OwnPtr<RequestCountTracker> m_requestCountTracker;
151 }; 150 };
152 151
153 } 152 }
154 153
155 #endif 154 #endif
OLDNEW
« no previous file with comments | « Source/core/fetch/ResourceFetcher.cpp ('k') | Source/core/fetch/ResourceLoaderOptions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698