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

Unified Diff: chrome/browser/chromeos/system_logs/single_log_source.h

Issue 2883553002: Revert of Add SingleLogSource to system_logs sources (Closed)
Patch Set: Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/chromeos/BUILD.gn ('k') | chrome/browser/chromeos/system_logs/single_log_source.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/system_logs/single_log_source.h
diff --git a/chrome/browser/chromeos/system_logs/single_log_source.h b/chrome/browser/chromeos/system_logs/single_log_source.h
deleted file mode 100644
index 18b4cc5fa5f940e036e91850aac8493800c22368..0000000000000000000000000000000000000000
--- a/chrome/browser/chromeos/system_logs/single_log_source.h
+++ /dev/null
@@ -1,56 +0,0 @@
-// Copyright 2017 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_BROWSER_CHROMEOS_SYSTEM_LOGS_SINGLE_LOG_SOURCE_H_
-#define CHROME_BROWSER_CHROMEOS_SYSTEM_LOGS_SINGLE_LOG_SOURCE_H_
-
-#include <stddef.h>
-
-#include "base/files/file.h"
-#include "base/macros.h"
-#include "chrome/browser/feedback/system_logs/system_logs_fetcher_base.h"
-#include "components/feedback/anonymizer_tool.h"
-
-namespace system_logs {
-
-// Gathers log data from a single source, possibly incrementally.
-class SingleLogSource : public SystemLogsSource {
- public:
- enum class SupportedSource {
- // For /var/log/messages.
- kMessages,
-
- // For /var/log/ui/ui.LATEST.
- kUiLatest,
- };
-
- explicit SingleLogSource(SupportedSource source);
- ~SingleLogSource() override;
-
- // system_logs::SystemLogsSource:
- void Fetch(const SysLogsSourceCallback& callback) override;
-
- private:
- friend class SingleLogSourceTest;
-
- // Reads all available content from |file_| that has not already been read.
- void ReadFile(SystemLogsResponse* result);
-
- // Keeps track of how much data has been read from |file_|.
- size_t num_bytes_read_;
-
- // Handle for reading the log file that is source of logging data.
- base::File file_;
-
- // For removing PII from log results.
- feedback::AnonymizerTool anonymizer_;
-
- base::WeakPtrFactory<SingleLogSource> weak_ptr_factory_;
-
- DISALLOW_COPY_AND_ASSIGN(SingleLogSource);
-};
-
-} // namespace system_logs
-
-#endif // CHROME_BROWSER_CHROMEOS_SYSTEM_LOGS_SINGLE_LOG_SOURCE_H_
« no previous file with comments | « chrome/browser/chromeos/BUILD.gn ('k') | chrome/browser/chromeos/system_logs/single_log_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698