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

Side by Side Diff: storage/browser/blob/blob_data_item.cc

Issue 1292523002: [BlobAsync] Patch 3: Renderer Classes & Logic (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@async2
Patch Set: comments and test Created 5 years, 1 month 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 (c) 2015 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2015 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 "storage/browser/blob/blob_data_item.h" 5 #include "storage/browser/blob/blob_data_item.h"
6 6
7 namespace storage { 7 namespace storage {
8 8
9 BlobDataItem::DataHandle::~DataHandle() { 9 BlobDataItem::DataHandle::~DataHandle() {
10 } 10 }
(...skipping 26 matching lines...) Expand all
37 37
38 void PrintTo(const BlobDataItem& x, ::std::ostream* os) { 38 void PrintTo(const BlobDataItem& x, ::std::ostream* os) {
39 DCHECK(os); 39 DCHECK(os);
40 *os << "<BlobDataItem>{item: "; 40 *os << "<BlobDataItem>{item: ";
41 PrintTo(*x.item_, os); 41 PrintTo(*x.item_, os);
42 *os << ", has_data_handle: " << (x.data_handle_.get() ? "true" : "false") 42 *os << ", has_data_handle: " << (x.data_handle_.get() ? "true" : "false")
43 << ", disk_cache_entry_ptr: " << x.disk_cache_entry_ 43 << ", disk_cache_entry_ptr: " << x.disk_cache_entry_
44 << ", disk_cache_stream_index_: " << x.disk_cache_stream_index_ << "}"; 44 << ", disk_cache_stream_index_: " << x.disk_cache_stream_index_ << "}";
45 } 45 }
46 46
47 bool operator==(const BlobDataItem& a, const BlobDataItem& b) {
48 return a.disk_cache_entry() == b.disk_cache_entry() &&
49 a.disk_cache_stream_index() == b.disk_cache_stream_index() &&
50 a.data_element() == b.data_element();
51 }
52
53 bool operator!=(const BlobDataItem& a, const BlobDataItem& b) {
54 return !(a == b);
55 }
56
47 } // namespace storage 57 } // namespace storage
OLDNEW
« no previous file with comments | « storage/browser/blob/blob_data_item.h ('k') | storage/common/blob_storage/blob_item_bytes_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698