| 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 #include "base/debug/trace_event_impl.h" | 5 #include "base/debug/trace_event_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/debug/leak_annotations.h" | 10 #include "base/debug/leak_annotations.h" |
| (...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 225 size_t current_iteration_index_; | 225 size_t current_iteration_index_; |
| 226 std::vector<TraceEvent> logged_events_; | 226 std::vector<TraceEvent> logged_events_; |
| 227 | 227 |
| 228 DISALLOW_COPY_AND_ASSIGN(TraceBufferVector); | 228 DISALLOW_COPY_AND_ASSIGN(TraceBufferVector); |
| 229 }; | 229 }; |
| 230 | 230 |
| 231 class TraceBufferDiscardsEvents : public TraceBuffer { | 231 class TraceBufferDiscardsEvents : public TraceBuffer { |
| 232 public: | 232 public: |
| 233 virtual ~TraceBufferDiscardsEvents() { } | 233 virtual ~TraceBufferDiscardsEvents() { } |
| 234 | 234 |
| 235 virtual void AddEvent(const TraceEvent& event) { } | 235 virtual void AddEvent(const TraceEvent& event) OVERRIDE {} |
| 236 virtual bool HasMoreEvents() const { return false; } | 236 virtual bool HasMoreEvents() const OVERRIDE { return false; } |
| 237 | 237 |
| 238 virtual const TraceEvent& NextEvent() { | 238 virtual const TraceEvent& NextEvent() OVERRIDE { |
| 239 NOTREACHED(); | 239 NOTREACHED(); |
| 240 return *static_cast<TraceEvent*>(NULL); | 240 return *static_cast<TraceEvent*>(NULL); |
| 241 } | 241 } |
| 242 | 242 |
| 243 virtual bool IsFull() const { return false; } | 243 virtual bool IsFull() const OVERRIDE { return false; } |
| 244 | 244 |
| 245 virtual size_t CountEnabledByName(const unsigned char* category, | 245 virtual size_t CountEnabledByName( |
| 246 const std::string& event_name) const { | 246 const unsigned char* category, |
| 247 const std::string& event_name) const OVERRIDE { |
| 247 return 0; | 248 return 0; |
| 248 } | 249 } |
| 249 | 250 |
| 250 virtual size_t Size() const { return 0; } | 251 virtual size_t Size() const OVERRIDE { return 0; } |
| 251 | 252 |
| 252 virtual const TraceEvent& GetEventAt(size_t index) const { | 253 virtual const TraceEvent& GetEventAt(size_t index) const OVERRIDE { |
| 253 NOTREACHED(); | 254 NOTREACHED(); |
| 254 return *static_cast<TraceEvent*>(NULL); | 255 return *static_cast<TraceEvent*>(NULL); |
| 255 } | 256 } |
| 256 }; | 257 }; |
| 257 | 258 |
| 258 //////////////////////////////////////////////////////////////////////////////// | 259 //////////////////////////////////////////////////////////////////////////////// |
| 259 // | 260 // |
| 260 // TraceEvent | 261 // TraceEvent |
| 261 // | 262 // |
| 262 //////////////////////////////////////////////////////////////////////////////// | 263 //////////////////////////////////////////////////////////////////////////////// |
| (...skipping 1144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1407 0, // num_args | 1408 0, // num_args |
| 1408 NULL, // arg_names | 1409 NULL, // arg_names |
| 1409 NULL, // arg_types | 1410 NULL, // arg_types |
| 1410 NULL, // arg_values | 1411 NULL, // arg_values |
| 1411 TRACE_EVENT_FLAG_NONE); // flags | 1412 TRACE_EVENT_FLAG_NONE); // flags |
| 1412 } | 1413 } |
| 1413 } | 1414 } |
| 1414 | 1415 |
| 1415 } // namespace trace_event_internal | 1416 } // namespace trace_event_internal |
| 1416 | 1417 |
| OLD | NEW |