| 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 CHROMEOS_PLATFORM_UPDATE_ENGINE_OMAHA_RESQUEST_PREP_ACTION_H__ | 5 #ifndef CHROMEOS_PLATFORM_UPDATE_ENGINE_OMAHA_RESQUEST_PREP_ACTION_H__ |
| 6 #define CHROMEOS_PLATFORM_UPDATE_ENGINE_OMAHA_RESQUEST_PREP_ACTION_H__ | 6 #define CHROMEOS_PLATFORM_UPDATE_ENGINE_OMAHA_RESQUEST_PREP_ACTION_H__ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include "update_engine/action.h" | 9 #include "update_engine/action.h" |
| 10 #include "update_engine/update_check_action.h" | 10 #include "update_engine/update_check_action.h" |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 root_ = root; | 47 root_ = root; |
| 48 } | 48 } |
| 49 | 49 |
| 50 private: | 50 private: |
| 51 // Gets a machine-local ID (for now, first MAC address we find) | 51 // Gets a machine-local ID (for now, first MAC address we find) |
| 52 bool GetMachineId(std::string* out_id) const; | 52 bool GetMachineId(std::string* out_id) const; |
| 53 | 53 |
| 54 // Fetches the value for a given key from | 54 // Fetches the value for a given key from |
| 55 // /mnt/stateful_partition/etc/lsb-release if possible. Failing that, | 55 // /mnt/stateful_partition/etc/lsb-release if possible. Failing that, |
| 56 // it looks for the key in /etc/lsb-release . | 56 // it looks for the key in /etc/lsb-release . |
| 57 std::string GetLsbValue(const std::string& key) const; | 57 std::string GetLsbValue(const std::string& key, |
| 58 const std::string& default_value) const; |
| 58 | 59 |
| 59 // Gets the machine type (e.g. "i686") | 60 // Gets the machine type (e.g. "i686") |
| 60 std::string GetMachineType() const; | 61 std::string GetMachineType() const; |
| 61 | 62 |
| 62 // Set to true if this should set up the Update Check Action to do | 63 // Set to true if this should set up the Update Check Action to do |
| 63 // a full update | 64 // a full update |
| 64 bool force_full_update_; | 65 bool force_full_update_; |
| 65 | 66 |
| 66 // When reading files, prepend root_ to the paths. Useful for testing. | 67 // When reading files, prepend root_ to the paths. Useful for testing. |
| 67 std::string root_; | 68 std::string root_; |
| 68 | 69 |
| 69 DISALLOW_COPY_AND_ASSIGN(OmahaRequestPrepAction); | 70 DISALLOW_COPY_AND_ASSIGN(OmahaRequestPrepAction); |
| 70 }; | 71 }; |
| 71 | 72 |
| 72 } // namespace chromeos_update_engine | 73 } // namespace chromeos_update_engine |
| 73 | 74 |
| 74 #endif // CHROMEOS_PLATFORM_UPDATE_ENGINE_OMAHA_RESQUEST_PREP_ACTION_H__ | 75 #endif // CHROMEOS_PLATFORM_UPDATE_ENGINE_OMAHA_RESQUEST_PREP_ACTION_H__ |
| OLD | NEW |