Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(202)

Side by Side Diff: chrome/installer/util/install_util.h

Issue 6526040: CommandLine refactoring and cleanup. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix nits, merge changes. Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/common/switch_utils_unittest.cc ('k') | chrome/installer/util/install_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 virtual bool Evaluate(const std::wstring& value) const OVERRIDE; 144 virtual bool Evaluate(const std::wstring& value) const OVERRIDE;
145 protected: 145 protected:
146 std::wstring value_to_match_; 146 std::wstring value_to_match_;
147 private: 147 private:
148 DISALLOW_COPY_AND_ASSIGN(ValueEquals); 148 DISALLOW_COPY_AND_ASSIGN(ValueEquals);
149 }; 149 };
150 150
151 // Returns zero on install success, or an InstallStatus value otherwise. 151 // Returns zero on install success, or an InstallStatus value otherwise.
152 static int GetInstallReturnCode(installer::InstallStatus install_status); 152 static int GetInstallReturnCode(installer::InstallStatus install_status);
153 153
154 // Composes |exe_path| and |arguments| into |command_line|. 154 // Composes |program| and |arguments| into |command_line|.
155 static void MakeUninstallCommand(const std::wstring& exe_path, 155 static void MakeUninstallCommand(const std::wstring& program,
156 const std::wstring& arguments, 156 const std::wstring& arguments,
157 CommandLine* command_line); 157 CommandLine* command_line);
158 158
159 // Returns a string in the form YYYYMMDD of the current date. 159 // Returns a string in the form YYYYMMDD of the current date.
160 static std::wstring GetCurrentDate(); 160 static std::wstring GetCurrentDate();
161 161
162 private: 162 private:
163 DISALLOW_COPY_AND_ASSIGN(InstallUtil); 163 DISALLOW_COPY_AND_ASSIGN(InstallUtil);
164 }; 164 };
165 165
166 166
167 #endif // CHROME_INSTALLER_UTIL_INSTALL_UTIL_H__ 167 #endif // CHROME_INSTALLER_UTIL_INSTALL_UTIL_H__
OLDNEW
« no previous file with comments | « chrome/common/switch_utils_unittest.cc ('k') | chrome/installer/util/install_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698