OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2005, 2006, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2005, 2006, 2008 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
8 * | 8 * |
9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 bool remove(const ValueType& value) { return remove(find(value)); } | 73 bool remove(const ValueType& value) { return remove(find(value)); } |
74 bool remove(iterator); | 74 bool remove(iterator); |
75 | 75 |
76 // Removes the value, regardless of its count. | 76 // Removes the value, regardless of its count. |
77 void removeAll(const ValueType& value) { removeAll(find(value)); } | 77 void removeAll(const ValueType& value) { removeAll(find(value)); } |
78 void removeAll(iterator); | 78 void removeAll(iterator); |
79 | 79 |
80 // Clears the whole set. | 80 // Clears the whole set. |
81 void clear() { m_impl.clear(); } | 81 void clear() { m_impl.clear(); } |
82 | 82 |
83 using HasInlinedTraceMethodMarker = int; | |
84 template<typename VisitorDispatcher> | 83 template<typename VisitorDispatcher> |
85 void trace(VisitorDispatcher visitor) { m_impl.trace(visitor); } | 84 void trace(VisitorDispatcher visitor) { m_impl.trace(visitor); } |
86 | 85 |
87 private: | 86 private: |
88 ImplType m_impl; | 87 ImplType m_impl; |
89 }; | 88 }; |
90 | 89 |
91 template<typename T, typename U, typename V, typename W> | 90 template<typename T, typename U, typename V, typename W> |
92 inline typename HashCountedSet<T, U, V, W>::AddResult HashCountedSet<T, U, V
, W>::add(const ValueType& value) | 91 inline typename HashCountedSet<T, U, V, W>::AddResult HashCountedSet<T, U, V
, W>::add(const ValueType& value) |
93 { | 92 { |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
154 struct NeedsTracing<HashCountedSet<T, U, V>> { | 153 struct NeedsTracing<HashCountedSet<T, U, V>> { |
155 static const bool value = false; | 154 static const bool value = false; |
156 }; | 155 }; |
157 #endif | 156 #endif |
158 | 157 |
159 } // namespace WTF | 158 } // namespace WTF |
160 | 159 |
161 using WTF::HashCountedSet; | 160 using WTF::HashCountedSet; |
162 | 161 |
163 #endif /* WTF_HashCountedSet_h */ | 162 #endif /* WTF_HashCountedSet_h */ |
OLD | NEW |