OLD | NEW |
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 #ifndef MEDIA_BASE_MEDIA_LOG_H_ | 5 #ifndef MEDIA_BASE_MEDIA_LOG_H_ |
6 #define MEDIA_BASE_MEDIA_LOG_H_ | 6 #define MEDIA_BASE_MEDIA_LOG_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "media/base/media_export.h" | |
11 #include "media/base/media_log_event.h" | 10 #include "media/base/media_log_event.h" |
12 | 11 |
13 namespace media { | 12 namespace media { |
14 | 13 |
15 class MEDIA_EXPORT MediaLog : public base::RefCountedThreadSafe<MediaLog> { | 14 class MediaLog : public base::RefCountedThreadSafe<MediaLog> { |
16 public: | 15 public: |
17 | 16 |
18 // Return a string to represent an EventType. | 17 // Return a string to represent an EventType. |
19 static const char* EventTypeToString(MediaLogEvent::Type type); | 18 static const char* EventTypeToString(MediaLogEvent::Type type); |
20 | 19 |
21 MediaLog(); | 20 MediaLog(); |
22 | 21 |
23 // Methods called by loggers when events occur. These generate appropriate | 22 // Methods called by loggers when events occur. These generate appropriate |
24 // event parameters so the caller need not worry about them. | 23 // event parameters so the caller need not worry about them. |
25 void Load(const std::string& url); | 24 void Load(const std::string& url); |
(...skipping 16 matching lines...) Expand all Loading... |
42 private: | 41 private: |
43 // A unique (to this process) id for this MediaLog. | 42 // A unique (to this process) id for this MediaLog. |
44 int32 id_; | 43 int32 id_; |
45 | 44 |
46 DISALLOW_COPY_AND_ASSIGN(MediaLog); | 45 DISALLOW_COPY_AND_ASSIGN(MediaLog); |
47 }; | 46 }; |
48 | 47 |
49 } // namespace media | 48 } // namespace media |
50 | 49 |
51 #endif // MEDIA_BASE_MEDIA_LOG_H_ | 50 #endif // MEDIA_BASE_MEDIA_LOG_H_ |
OLD | NEW |