| 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 | 5 |
| 6 #ifndef BASE_DEBUG_TRACE_EVENT_IMPL_H_ | 6 #ifndef BASE_DEBUG_TRACE_EVENT_IMPL_H_ |
| 7 #define BASE_DEBUG_TRACE_EVENT_IMPL_H_ | 7 #define BASE_DEBUG_TRACE_EVENT_IMPL_H_ |
| 8 | 8 |
| 9 #include <stack> | 9 #include <stack> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 518 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 529 void SetWatchEvent(const std::string& category_name, | 529 void SetWatchEvent(const std::string& category_name, |
| 530 const std::string& event_name); | 530 const std::string& event_name); |
| 531 // Cancel the watch event. If tracing is enabled, this may race with the | 531 // Cancel the watch event. If tracing is enabled, this may race with the |
| 532 // watch event notification firing. | 532 // watch event notification firing. |
| 533 void CancelWatchEvent(); | 533 void CancelWatchEvent(); |
| 534 | 534 |
| 535 int process_id() const { return process_id_; } | 535 int process_id() const { return process_id_; } |
| 536 | 536 |
| 537 // Exposed for unittesting: | 537 // Exposed for unittesting: |
| 538 | 538 |
| 539 void InstallWaitableEventForSamplingTesting(WaitableEvent* waitable_event); | 539 void WaitSamplingEventForTesting(); |
| 540 | 540 |
| 541 // Allows deleting our singleton instance. | 541 // Allows deleting our singleton instance. |
| 542 static void DeleteForTesting(); | 542 static void DeleteForTesting(); |
| 543 | 543 |
| 544 // Allow tests to inspect TraceEvents. | 544 // Allow tests to inspect TraceEvents. |
| 545 size_t GetEventsSize() const { return logged_events_->Size(); } | 545 size_t GetEventsSize() const { return logged_events_->Size(); } |
| 546 TraceEvent* GetEventByHandle(TraceEventHandle handle); | 546 TraceEvent* GetEventByHandle(TraceEventHandle handle); |
| 547 | 547 |
| 548 void SetProcessID(int process_id); | 548 void SetProcessID(int process_id); |
| 549 | 549 |
| (...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 716 scoped_refptr<MessageLoopProxy> flush_message_loop_proxy_; | 716 scoped_refptr<MessageLoopProxy> flush_message_loop_proxy_; |
| 717 subtle::AtomicWord generation_; | 717 subtle::AtomicWord generation_; |
| 718 | 718 |
| 719 DISALLOW_COPY_AND_ASSIGN(TraceLog); | 719 DISALLOW_COPY_AND_ASSIGN(TraceLog); |
| 720 }; | 720 }; |
| 721 | 721 |
| 722 } // namespace debug | 722 } // namespace debug |
| 723 } // namespace base | 723 } // namespace base |
| 724 | 724 |
| 725 #endif // BASE_DEBUG_TRACE_EVENT_IMPL_H_ | 725 #endif // BASE_DEBUG_TRACE_EVENT_IMPL_H_ |
| OLD | NEW |