OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "extensions/browser/crx_file_info.h" |
| 6 |
| 7 #include "base/logging.h" |
| 8 |
| 9 namespace extensions { |
| 10 |
| 11 CRXFileInfo::CRXFileInfo() : path() { |
| 12 } |
| 13 |
| 14 CRXFileInfo::CRXFileInfo(const std::string& i, |
| 15 const base::FilePath& p, |
| 16 const std::string& h) |
| 17 : extension_id(i), path(p), expected_hash(h) { |
| 18 DCHECK(!path.empty()); |
| 19 } |
| 20 |
| 21 CRXFileInfo::CRXFileInfo(const std::string& i, const base::FilePath& p) |
| 22 : extension_id(i), path(p), expected_hash() { |
| 23 DCHECK(!path.empty()); |
| 24 } |
| 25 |
| 26 CRXFileInfo::CRXFileInfo(const base::FilePath& p) |
| 27 : extension_id(), path(p), expected_hash() { |
| 28 DCHECK(!path.empty()); |
| 29 } |
| 30 |
| 31 bool CRXFileInfo::operator==(const CRXFileInfo& that) const { |
| 32 return extension_id == that.extension_id && path == that.path && |
| 33 expected_hash == that.expected_hash; |
| 34 } |
| 35 |
| 36 } // namespace extensions |
OLD | NEW |