Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(460)

Side by Side Diff: Source/core/inspector/AsyncOperationMap.h

Issue 1198863006: First version of PerformanceObserver (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Sync with latest spec draft (DOMString -> PerformanceEntryType and new PerformanceObserver -> windo… Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 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 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 AsyncOperationMap_h 5 #ifndef AsyncOperationMap_h
6 #define AsyncOperationMap_h 6 #define AsyncOperationMap_h
7 7
8 #include "core/inspector/InspectorDebuggerAgent.h" 8 #include "core/inspector/InspectorDebuggerAgent.h"
9 #include "platform/heap/Handle.h" 9 #include "platform/heap/Handle.h"
10 #include "wtf/HashMap.h" 10 #include "wtf/HashMap.h"
11 #include "wtf/PassRefPtr.h" 11 #include "wtf/PassRefPtr.h"
12 #include "wtf/RefPtr.h" 12 #include "wtf/RefPtr.h"
13 13
14 namespace blink { 14 namespace blink {
15 15
16 template <class K> 16 template <class K, class MapType = WillBeHeapHashMap<K, int>>
17 class AsyncOperationMap final { 17 class AsyncOperationMap final {
18 ALLOW_ONLY_INLINE_ALLOCATION(); 18 ALLOW_ONLY_INLINE_ALLOCATION();
19 public: 19 public:
20 using MapType = WillBeHeapHashMap<K, int>;
21 explicit AsyncOperationMap(InspectorDebuggerAgent* debuggerAgent) 20 explicit AsyncOperationMap(InspectorDebuggerAgent* debuggerAgent)
22 : m_debuggerAgent(debuggerAgent) 21 : m_debuggerAgent(debuggerAgent)
23 { 22 {
24 } 23 }
25 24
26 ~AsyncOperationMap() 25 ~AsyncOperationMap()
27 { 26 {
28 // Verify that this object has been explicitly disposed. 27 // Verify that this object has been explicitly disposed.
29 ASSERT(hasBeenDisposed()); 28 ASSERT(hasBeenDisposed());
30 } 29 }
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 80
82 private: 81 private:
83 RawPtrWillBeMember<InspectorDebuggerAgent> m_debuggerAgent; 82 RawPtrWillBeMember<InspectorDebuggerAgent> m_debuggerAgent;
84 MapType m_asyncOperations; 83 MapType m_asyncOperations;
85 }; 84 };
86 85
87 } // namespace blink 86 } // namespace blink
88 87
89 88
90 #endif // AsyncOperationMap_h 89 #endif // AsyncOperationMap_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698