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

Side by Side Diff: webkit/browser/appcache/appcache_update_job.h

Issue 276093003: appcache content-type check (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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
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 #ifndef WEBKIT_BROWSER_APPCACHE_APPCACHE_UPDATE_JOB_H_ 5 #ifndef WEBKIT_BROWSER_APPCACHE_APPCACHE_UPDATE_JOB_H_
6 #define WEBKIT_BROWSER_APPCACHE_APPCACHE_UPDATE_JOB_H_ 6 #define WEBKIT_BROWSER_APPCACHE_APPCACHE_UPDATE_JOB_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 URLFetcher* manifest_fetcher_; 312 URLFetcher* manifest_fetcher_;
313 PendingUrlFetches pending_url_fetches_; 313 PendingUrlFetches pending_url_fetches_;
314 314
315 // Temporary storage of manifest response data for parsing and comparison. 315 // Temporary storage of manifest response data for parsing and comparison.
316 std::string manifest_data_; 316 std::string manifest_data_;
317 scoped_ptr<net::HttpResponseInfo> manifest_response_info_; 317 scoped_ptr<net::HttpResponseInfo> manifest_response_info_;
318 scoped_ptr<AppCacheResponseWriter> manifest_response_writer_; 318 scoped_ptr<AppCacheResponseWriter> manifest_response_writer_;
319 scoped_refptr<net::IOBuffer> read_manifest_buffer_; 319 scoped_refptr<net::IOBuffer> read_manifest_buffer_;
320 std::string loaded_manifest_data_; 320 std::string loaded_manifest_data_;
321 scoped_ptr<AppCacheResponseReader> manifest_response_reader_; 321 scoped_ptr<AppCacheResponseReader> manifest_response_reader_;
322 bool manifest_has_valid_mime_type_;
322 323
323 // New master entries added to the cache by this job, used to cleanup 324 // New master entries added to the cache by this job, used to cleanup
324 // in error conditions. 325 // in error conditions.
325 std::vector<GURL> added_master_entries_; 326 std::vector<GURL> added_master_entries_;
326 327
327 // Response ids stored by this update job, used to cleanup in 328 // Response ids stored by this update job, used to cleanup in
328 // error conditions. 329 // error conditions.
329 std::vector<int64> stored_response_ids_; 330 std::vector<int64> stored_response_ids_;
330 331
331 // In some cases we fetch the same resource multiple times, and then 332 // In some cases we fetch the same resource multiple times, and then
332 // have to delete the duplicates upon successful update. These ids 333 // have to delete the duplicates upon successful update. These ids
333 // are also in the stored_response_ids_ collection so we only schedule 334 // are also in the stored_response_ids_ collection so we only schedule
334 // these for deletion on success. 335 // these for deletion on success.
335 // TODO(michaeln): Rework when we no longer fetches master entries directly. 336 // TODO(michaeln): Rework when we no longer fetches master entries directly.
336 std::vector<int64> duplicate_response_ids_; 337 std::vector<int64> duplicate_response_ids_;
337 338
338 // Whether we've stored the resulting group/cache yet. 339 // Whether we've stored the resulting group/cache yet.
339 StoredState stored_state_; 340 StoredState stored_state_;
340 341
341 AppCacheStorage* storage_; 342 AppCacheStorage* storage_;
342 343
343 FRIEND_TEST_ALL_PREFIXES(content::AppCacheGroupTest, QueueUpdate); 344 FRIEND_TEST_ALL_PREFIXES(content::AppCacheGroupTest, QueueUpdate);
344 345
345 DISALLOW_COPY_AND_ASSIGN(AppCacheUpdateJob); 346 DISALLOW_COPY_AND_ASSIGN(AppCacheUpdateJob);
346 }; 347 };
347 348
348 } // namespace appcache 349 } // namespace appcache
349 350
350 #endif // WEBKIT_BROWSER_APPCACHE_APPCACHE_UPDATE_JOB_H_ 351 #endif // WEBKIT_BROWSER_APPCACHE_APPCACHE_UPDATE_JOB_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698