| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #ifndef STORAGE_BROWSER_BLOB_BLOB_DATA_SNAPSHOT_H_ | 5 #ifndef STORAGE_BROWSER_BLOB_BLOB_DATA_SNAPSHOT_H_ |
| 6 #define STORAGE_BROWSER_BLOB_BLOB_DATA_SNAPSHOT_H_ | 6 #define STORAGE_BROWSER_BLOB_BLOB_DATA_SNAPSHOT_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 | 30 |
| 31 const std::vector<scoped_refptr<BlobDataItem>>& items() const { | 31 const std::vector<scoped_refptr<BlobDataItem>>& items() const { |
| 32 return items_; | 32 return items_; |
| 33 } | 33 } |
| 34 const std::string& content_type() const { return content_type_; } | 34 const std::string& content_type() const { return content_type_; } |
| 35 const std::string& content_disposition() const { | 35 const std::string& content_disposition() const { |
| 36 return content_disposition_; | 36 return content_disposition_; |
| 37 } | 37 } |
| 38 size_t GetMemoryUsage() const; | 38 size_t GetMemoryUsage() const; |
| 39 | 39 |
| 40 const std::string& uuid() const { return uuid_; } |
| 41 |
| 40 private: | 42 private: |
| 41 friend class BlobDataBuilder; | 43 friend class BlobDataBuilder; |
| 42 friend class BlobStorageContext; | 44 friend class BlobStorageContext; |
| 43 BlobDataSnapshot(const std::string& uuid, | 45 BlobDataSnapshot(const std::string& uuid, |
| 44 const std::string& content_type, | 46 const std::string& content_type, |
| 45 const std::string& content_disposition); | 47 const std::string& content_disposition); |
| 46 BlobDataSnapshot(const std::string& uuid, | 48 BlobDataSnapshot(const std::string& uuid, |
| 47 const std::string& content_type, | 49 const std::string& content_type, |
| 48 const std::string& content_disposition, | 50 const std::string& content_disposition, |
| 49 const std::vector<scoped_refptr<BlobDataItem>>& items); | 51 const std::vector<scoped_refptr<BlobDataItem>>& items); |
| 50 | 52 |
| 51 const std::string uuid_; | 53 const std::string uuid_; |
| 52 const std::string content_type_; | 54 const std::string content_type_; |
| 53 const std::string content_disposition_; | 55 const std::string content_disposition_; |
| 54 // Non-const for constrution in BlobStorageContext | 56 // Non-const for constrution in BlobStorageContext |
| 55 std::vector<scoped_refptr<BlobDataItem>> items_; | 57 std::vector<scoped_refptr<BlobDataItem>> items_; |
| 56 }; | 58 }; |
| 57 | 59 |
| 58 } // namespace storage | 60 } // namespace storage |
| 59 #endif // STORAGE_BROWSER_BLOB_BLOB_DATA_SNAPSHOT_H_ | 61 #endif // STORAGE_BROWSER_BLOB_BLOB_DATA_SNAPSHOT_H_ |
| OLD | NEW |