Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 REMOTING_HOST_HOST_EVENT_LOGGER_H_ | 5 #ifndef REMOTING_HOST_HOST_EVENT_LOGGER_H_ |
| 6 #define REMOTING_HOST_HOST_EVENT_LOGGER_H_ | 6 #define REMOTING_HOST_HOST_EVENT_LOGGER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
| 12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
| 13 | 13 |
| 14 namespace remoting { | 14 namespace remoting { |
| 15 | 15 |
| 16 class ChromotingHost; | 16 class ChromotingHost; |
| 17 | 17 |
| 18 class HostEventLogger { | 18 class HostEventLogger { |
| 19 public: | 19 public: |
| 20 virtual ~HostEventLogger() {} | 20 virtual ~HostEventLogger() {} |
| 21 | 21 |
| 22 // Creates an event-logger that monitors host status changes and logs | 22 // Creates an event-logger that monitors host status changes and logs |
| 23 // corresponding events to the OS-specific log (syslog/EventLog). | 23 // corresponding events to the OS-specific log (syslog/EventLog). |
| 24 static scoped_ptr<HostEventLogger> Create( | 24 static scoped_ptr<HostEventLogger> Create( |
| 25 ChromotingHost* host, const std::string& application_name); | 25 ChromotingHost* host, const std::string& application_name); |
| 26 | 26 |
| 27 // Called when hosting is started for an account. | |
| 28 virtual void OnStart(const std::string& xmpp_login) {}; | |
|
alexeypa (please no reviews)
2012/08/29 15:15:48
ChromotingHost::Start is called after HostEventLog
Jamie
2012/08/29 17:24:14
I agree. HostStatusObserver is the best place to a
Lambros
2012/08/29 17:34:25
nit: no semicolon needed
rmsousa
2012/08/29 19:24:40
Done.
rmsousa
2012/08/29 19:24:40
Done.
rmsousa
2012/08/29 19:24:40
Done.
| |
| 27 protected: | 29 protected: |
| 28 HostEventLogger() {} | 30 HostEventLogger() {} |
| 29 | 31 |
| 30 private: | 32 private: |
| 31 DISALLOW_COPY_AND_ASSIGN(HostEventLogger); | 33 DISALLOW_COPY_AND_ASSIGN(HostEventLogger); |
| 32 }; | 34 }; |
| 33 | 35 |
| 34 } | 36 } |
| 35 | 37 |
| 36 #endif // REMOTING_HOST_HOST_EVENT_LOGGER_H_ | 38 #endif // REMOTING_HOST_HOST_EVENT_LOGGER_H_ |
| OLD | NEW |