Torne (Richard Coles) | c2e0dbd | 2013-05-09 18:35:53 +0100 | [diff] [blame] | 1 | // Copyright (c) 2013 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 | #ifndef CHROME_BROWSER_CHROMEOS_DRIVE_LOGGING_H_ |
| 6 | #define CHROME_BROWSER_CHROMEOS_DRIVE_LOGGING_H_ |
| 7 | |
Torne (Richard Coles) | c2e0dbd | 2013-05-09 18:35:53 +0100 | [diff] [blame] | 8 | #include <vector> |
| 9 | |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 10 | #include "chrome/browser/drive/event_logger.h" |
Torne (Richard Coles) | c2e0dbd | 2013-05-09 18:35:53 +0100 | [diff] [blame] | 11 | |
| 12 | namespace drive { |
| 13 | // Originally wanted to use 'logging' here, but it conflicts with |
| 14 | // base/logging.h, and breaks DCHECK() and friends. |
| 15 | namespace util { |
| 16 | |
| 17 | // Logs a message using printf format. |
| 18 | // This function can be called from any thread. |
Torne (Richard Coles) | a36e592 | 2013-08-05 13:57:33 +0100 | [diff] [blame] | 19 | void Log( |
| 20 | logging::LogSeverity severity, const char* format, ...) PRINTF_FORMAT(2, 3); |
Torne (Richard Coles) | c2e0dbd | 2013-05-09 18:35:53 +0100 | [diff] [blame] | 21 | |
| 22 | // Returns the log history. |
| 23 | // This function can be called from any thread. |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 24 | std::vector<EventLogger::Event> GetLogHistory(); |
Torne (Richard Coles) | c2e0dbd | 2013-05-09 18:35:53 +0100 | [diff] [blame] | 25 | |
| 26 | } // namespace util |
| 27 | } // namespace drive |
| 28 | |
| 29 | #endif // CHROME_BROWSER_CHROMEOS_DRIVE_LOGGING_H_ |