| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 // This file declares utility functions for the installer. The original reason | 5 // This file declares utility functions for the installer. The original reason |
| 6 // for putting these functions in installer\util library is so that we can | 6 // for putting these functions in installer\util library is so that we can |
| 7 // separate out the critical logic and write unit tests for it. | 7 // separate out the critical logic and write unit tests for it. |
| 8 | 8 |
| 9 #ifndef CHROME_INSTALLER_UTIL_INSTALL_UTIL_H__ | 9 #ifndef CHROME_INSTALLER_UTIL_INSTALL_UTIL_H__ |
| 10 #define CHROME_INSTALLER_UTIL_INSTALL_UTIL_H__ | 10 #define CHROME_INSTALLER_UTIL_INSTALL_UTIL_H__ |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 105 const std::wstring& value_name); | 105 const std::wstring& value_name); |
| 106 | 106 |
| 107 // Returns zero on install success, or an InstallStatus value otherwise. | 107 // Returns zero on install success, or an InstallStatus value otherwise. |
| 108 static int GetInstallReturnCode(installer::InstallStatus install_status); | 108 static int GetInstallReturnCode(installer::InstallStatus install_status); |
| 109 | 109 |
| 110 // Composes |exe_path| and |arguments| into |command_line|. | 110 // Composes |exe_path| and |arguments| into |command_line|. |
| 111 static void MakeUninstallCommand(const std::wstring& exe_path, | 111 static void MakeUninstallCommand(const std::wstring& exe_path, |
| 112 const std::wstring& arguments, | 112 const std::wstring& arguments, |
| 113 CommandLine* command_line); | 113 CommandLine* command_line); |
| 114 | 114 |
| 115 // Returns a string in the form YYYYMMDD of the current date. |
| 116 static std::wstring GetCurrentDate(); |
| 117 |
| 115 private: | 118 private: |
| 116 DISALLOW_COPY_AND_ASSIGN(InstallUtil); | 119 DISALLOW_COPY_AND_ASSIGN(InstallUtil); |
| 117 }; | 120 }; |
| 118 | 121 |
| 119 | 122 |
| 120 #endif // CHROME_INSTALLER_UTIL_INSTALL_UTIL_H__ | 123 #endif // CHROME_INSTALLER_UTIL_INSTALL_UTIL_H__ |
| OLD | NEW |