| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 CHROME_BROWSER_CHROMEOS_CROS_UPDATE_LIBRARY_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_CROS_UPDATE_LIBRARY_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_CROS_UPDATE_LIBRARY_H_ | 6 #define CHROME_BROWSER_CHROMEOS_CROS_UPDATE_LIBRARY_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/observer_list.h" | 11 #include "base/observer_list.h" |
| 12 #include "base/singleton.h" | 12 #include "base/singleton.h" |
| 13 #include "base/time.h" | 13 #include "base/time.h" |
| 14 #include "cros/chromeos_update_engine.h" | 14 #include "third_party/cros/chromeos_update_engine.h" |
| 15 | 15 |
| 16 namespace chromeos { | 16 namespace chromeos { |
| 17 | 17 |
| 18 // This interface defines interaction with the ChromeOS update library APIs. | 18 // This interface defines interaction with the ChromeOS update library APIs. |
| 19 // Classes can add themselves as observers. Users can get an instance of this | 19 // Classes can add themselves as observers. Users can get an instance of this |
| 20 // library class like this: chromeos::CrosLibrary::Get()->GetUpdateLibrary() | 20 // library class like this: chromeos::CrosLibrary::Get()->GetUpdateLibrary() |
| 21 | 21 |
| 22 class UpdateLibrary { | 22 class UpdateLibrary { |
| 23 public: | 23 public: |
| 24 // TODO(seanparent): Should make the UpdateProgress type copyable. | 24 // TODO(seanparent): Should make the UpdateProgress type copyable. |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 virtual const Status& status() const = 0; | 79 virtual const Status& status() const = 0; |
| 80 | 80 |
| 81 // Factory function, creates a new instance and returns ownership. | 81 // Factory function, creates a new instance and returns ownership. |
| 82 // For normal usage, access the singleton via CrosLibrary::Get(). | 82 // For normal usage, access the singleton via CrosLibrary::Get(). |
| 83 static UpdateLibrary* GetImpl(bool stub); | 83 static UpdateLibrary* GetImpl(bool stub); |
| 84 }; | 84 }; |
| 85 | 85 |
| 86 } // namespace chromeos | 86 } // namespace chromeos |
| 87 | 87 |
| 88 #endif // CHROME_BROWSER_CHROMEOS_CROS_UPDATE_LIBRARY_H_ | 88 #endif // CHROME_BROWSER_CHROMEOS_CROS_UPDATE_LIBRARY_H_ |
| OLD | NEW |