Home | History | Annotate | Download | only in power_profiler
      1 // Copyright 2014 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 CONTENT_BROWSER_POWER_PROFILER_POWER_PROFILER_OBSERVER_H_
      6 #define CONTENT_BROWSER_POWER_PROFILER_POWER_PROFILER_OBSERVER_H_
      7 
      8 #include <vector>
      9 
     10 #include "base/basictypes.h"
     11 #include "content/common/content_export.h"
     12 
     13 namespace content {
     14 
     15 struct PowerEvent;
     16 typedef std::vector<PowerEvent> PowerEventVector;
     17 
     18 // A class used to monitor power usage data.
     19 class CONTENT_EXPORT PowerProfilerObserver {
     20  public:
     21   PowerProfilerObserver() {}
     22   virtual ~PowerProfilerObserver() {}
     23 
     24   // This method will be called on the UI thread.
     25   virtual void OnPowerEvent(const PowerEventVector&) = 0;
     26 
     27  private:
     28   DISALLOW_COPY_AND_ASSIGN(PowerProfilerObserver);
     29 };
     30 
     31 }  // namespace content
     32 
     33 #endif  // CONTENT_BROWSER_POWER_PROFILER_POWER_PROFILER_OBSERVER_H_
     34