OLD | NEW |
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/v8/V8DebuggerAgent.h" | 8 #include "core/inspector/v8/V8DebuggerAgent.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> |
17 class AsyncOperationMap final { | 17 class AsyncOperationMap final { |
18 ALLOW_ONLY_INLINE_ALLOCATION(); | 18 DISALLOW_NEW_EXCEPT_PLACEMENT_NEW(); |
19 public: | 19 public: |
20 using MapType = WillBeHeapHashMap<K, int>; | 20 using MapType = WillBeHeapHashMap<K, int>; |
21 explicit AsyncOperationMap(V8DebuggerAgent* debuggerAgent) | 21 explicit AsyncOperationMap(V8DebuggerAgent* debuggerAgent) |
22 : m_debuggerAgent(debuggerAgent) | 22 : m_debuggerAgent(debuggerAgent) |
23 { | 23 { |
24 } | 24 } |
25 | 25 |
26 ~AsyncOperationMap() | 26 ~AsyncOperationMap() |
27 { | 27 { |
28 // Verify that this object has been explicitly disposed. | 28 // Verify that this object has been explicitly disposed. |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 | 80 |
81 private: | 81 private: |
82 V8DebuggerAgent* m_debuggerAgent; | 82 V8DebuggerAgent* m_debuggerAgent; |
83 MapType m_asyncOperations; | 83 MapType m_asyncOperations; |
84 }; | 84 }; |
85 | 85 |
86 } // namespace blink | 86 } // namespace blink |
87 | 87 |
88 | 88 |
89 #endif // AsyncOperationMap_h | 89 #endif // AsyncOperationMap_h |
OLD | NEW |