Go to the documentation of this file.
17 #ifndef MOMO_INCLUDE_GUARD_STDISH_UNORDERED_MULTIMAP
18 #define MOMO_INCLUDE_GUARD_STDISH_UNORDERED_MULTIMAP
20 #include "../HashMultiMap.h"
57 template<
typename TKey,
typename TMapped,
58 typename THashFunc = HashCoder<TKey>,
59 typename TEqualFunc = std::equal_to<TKey>,
60 typename TAllocator = std::allocator<std::pair<const TKey, TMapped>>,
61 typename THashMultiMap = HashMultiMap<TKey, TMapped, HashTraitsStd<TKey, THashFunc, TEqualFunc>,
62 MemManagerStd<TAllocator>>>
66 typedef THashMultiMap HashMultiMap;
82 typedef std::pair<const key_type, mapped_type>
value_type;
102 template<
typename KeyArg>
103 struct IsValidKeyArg :
public HashTraits::template IsValidKeyArg<KeyArg>
115 struct IteratorProxy :
public iterator
127 : mHashMultiMap(HashTraits(), MemManager(alloc))
133 : mHashMultiMap(HashTraits(bucketCount), MemManager(alloc))
139 : mHashMultiMap(HashTraits(bucketCount, hashFunc), MemManager(alloc))
145 : mHashMultiMap(HashTraits(bucketCount, hashFunc, equalFunc), MemManager(alloc))
149 template<
typename Iterator>
155 template<
typename Iterator>
163 template<
typename Iterator>
171 template<
typename Iterator>
205 : mHashMultiMap(std::move(right.mHashMultiMap))
211 noexcept(std::is_empty<allocator_type>::value)
212 : mHashMultiMap(pvCreateMultiMap(
std::move(right), alloc))
217 : mHashMultiMap(right.mHashMultiMap)
223 : mHashMultiMap(right.mHashMultiMap, MemManager(alloc))
230 noexcept(std::is_empty<allocator_type>::value ||
231 std::allocator_traits<allocator_type>::propagate_on_container_move_assignment::value)
235 bool propagate = std::is_empty<allocator_type>::value ||
236 std::allocator_traits<allocator_type>::propagate_on_container_move_assignment::value;
238 mHashMultiMap = pvCreateMultiMap(std::move(right), alloc);
247 bool propagate = std::is_empty<allocator_type>::value ||
248 std::allocator_traits<allocator_type>::propagate_on_container_copy_assignment::value;
250 mHashMultiMap = HashMultiMap(right.mHashMultiMap, MemManager(alloc));
257 HashMultiMap hashMultiMap(mHashMultiMap.GetHashTraits(), MemManager(
get_allocator()));
258 hashMultiMap.Add(values.begin(), values.end());
259 mHashMultiMap = std::move(hashMultiMap);
265 MOMO_ASSERT(std::allocator_traits<allocator_type>::propagate_on_container_swap::value
267 mHashMultiMap.Swap(right.mHashMultiMap);
277 return mHashMultiMap;
282 return mHashMultiMap;
287 return ConstIteratorProxy(mHashMultiMap.GetBegin());
292 return IteratorProxy(mHashMultiMap.GetBegin());
297 return ConstIteratorProxy(mHashMultiMap.GetEnd());
302 return IteratorProxy(mHashMultiMap.GetEnd());
320 return mHashMultiMap.GetHashTraits().GetHashFunc();
325 return mHashMultiMap.GetHashTraits().GetEqualFunc();
330 return allocator_type(mHashMultiMap.GetMemManager().GetByteAllocator());
335 return std::allocator_traits<allocator_type>::max_size(
get_allocator());
340 return mHashMultiMap.GetValueCount();
350 mHashMultiMap.Clear();
366 template<
typename KeyArg>
373 template<
typename KeyArg>
383 return !!keyIter ? keyIter->GetCount() : 0;
386 template<
typename KeyArg>
391 return !!keyIter ? keyIter->GetCount() : 0;
396 return count(key) > 0;
399 template<
typename KeyArg>
403 return count(key) > 0;
408 return pvEqualRange<const_iterator, ConstIteratorProxy>(mHashMultiMap,
409 mHashMultiMap.Find(key));
414 return pvEqualRange<iterator, IteratorProxy>(mHashMultiMap, mHashMultiMap.Find(key));
417 template<
typename KeyArg>
419 std::pair<const_iterator, const_iterator>>
equal_range(
const KeyArg& key)
const
421 return pvEqualRange<const_iterator, ConstIteratorProxy>(mHashMultiMap,
422 mHashMultiMap.Find(key));
425 template<
typename KeyArg>
429 return pvEqualRange<iterator, IteratorProxy>(mHashMultiMap, mHashMultiMap.Find(key));
450 return pvEmplace(std::forward_as_tuple(std::move(value.first)),
451 std::forward_as_tuple(std::move(value.second)));
456 return insert(std::move(value));
459 template<
typename First,
typename Second>
461 && std::is_constructible<mapped_type, const Second&>::value,
464 return pvEmplace(std::forward_as_tuple(value.first), std::forward_as_tuple(value.second));
467 template<
typename First,
typename Second>
469 && std::is_constructible<mapped_type, const Second&>::value,
475 template<
typename First,
typename Second>
477 && std::is_constructible<mapped_type, Second&&>::value,
480 return pvEmplace(std::forward_as_tuple(std::forward<First>(value.first)),
481 std::forward_as_tuple(std::forward<Second>(value.second)));
484 template<
typename First,
typename Second>
486 && std::is_constructible<mapped_type, Second&&>::value,
489 return insert(std::move(value));
492 template<
typename Iterator>
493 void insert(Iterator first, Iterator last)
498 void insert(std::initializer_list<value_type> values)
500 mHashMultiMap.Add(values.begin(), values.end());
505 return pvEmplace(std::tuple<>(), std::tuple<>());
513 template<
typename ValueArg>
516 return insert(std::forward<ValueArg>(valueArg));
519 template<
typename ValueArg>
522 return emplace(std::forward<ValueArg>(valueArg));
525 template<
typename KeyArg,
typename MappedArg>
528 return pvEmplace(std::forward_as_tuple(std::forward<KeyArg>(keyArg)),
529 std::forward_as_tuple(std::forward<MappedArg>(mappedArg)));
532 template<
typename KeyArg,
typename MappedArg>
535 return emplace(std::forward<KeyArg>(keyArg), std::forward<MappedArg>(mappedArg));
538 template<
typename... KeyArgs,
typename... MappedArgs>
540 std::tuple<KeyArgs...> keyArgs, std::tuple<MappedArgs...> mappedArgs)
542 return pvEmplace(std::move(keyArgs), std::move(mappedArgs));
545 template<
typename... KeyArgs,
typename... MappedArgs>
547 std::tuple<KeyArgs...> keyArgs, std::tuple<MappedArgs...> mappedArgs)
549 return pvEmplace(std::move(keyArgs), std::move(mappedArgs));
556 if (keyIter->GetCount() == 1)
557 return IteratorProxy(mHashMultiMap.MakeIterator(mHashMultiMap.RemoveKey(keyIter)));
559 return IteratorProxy(mHashMultiMap.Remove(iter));
569 if (first ==
begin() && last ==
end())
576 return IteratorProxy(mHashMultiMap.MakeMutableIterator(
577 ConstIteratorProxy::GetBaseIterator(first)));
581 if (std::next(first) == last)
584 ConstIteratorProxy::GetBaseIterator(first).GetKeyIterator();
585 if (last == ConstIteratorProxy(mHashMultiMap.MakeIterator(keyIter, keyIter->GetCount())))
586 return IteratorProxy(mHashMultiMap.MakeIterator(mHashMultiMap.RemoveKey(keyIter)));
588 throw std::invalid_argument(
"invalid unordered_multimap erase arguments");
593 return mHashMultiMap.RemoveKey(key);
596 template<
typename ValueFilter>
601 return cont.mHashMultiMap.Remove(pairFilter);
624 if (mHashMultiMap.GetKeyCount() != right.mHashMultiMap.GetKeyCount())
626 if (mHashMultiMap.GetValueCount() != right.mHashMultiMap.GetValueCount())
630 if (ref.GetCount() == 0)
635 if (ref.GetCount() != rightKeyIter->GetCount())
637 if (!std::is_permutation(ref.GetBegin(), ref.GetEnd(), rightKeyIter->GetBegin()))
645 return !(*
this == right);
651 if (right.get_allocator() == alloc)
652 return std::move(right.mHashMultiMap);
653 HashMultiMap hashMultiMap(right.mHashMultiMap.GetHashTraits(), MemManager(alloc));
655 hashMultiMap.Add(ref.first, std::move(ref.second));
660 template<
typename Iterator,
typename IteratorProxy,
typename HashMultiMap,
typename KeyIterator>
661 static std::pair<Iterator, Iterator> pvEqualRange(
HashMultiMap& hashMultiMap,
664 Iterator
end = IteratorProxy(hashMultiMap.
GetEnd());
667 size_t count = keyIter->GetCount();
670 Iterator first = IteratorProxy(hashMultiMap.
MakeIterator(keyIter, 0));
672 return { first, last };
675 template<
typename... KeyArgs,
typename... MappedArgs>
676 iterator pvEmplace(std::tuple<KeyArgs...>&& keyArgs, std::tuple<MappedArgs...>&& mappedArgs)
678 typedef typename HashMultiMap::KeyValueTraits
679 ::template ValueCreator<MappedArgs...> MappedCreator;
680 return pvInsert(std::move(keyArgs),
681 MappedCreator(mHashMultiMap.GetMemManager(), std::move(mappedArgs)));
684 template<
typename... KeyArgs,
typename MappedCreator>
685 iterator pvInsert(std::tuple<KeyArgs...>&& keyArgs, MappedCreator&& mappedCreator)
687 MemManager& memManager = mHashMultiMap.GetMemManager();
690 typedef typename KeyManager::template Creator<KeyArgs...> KeyCreator;
692 KeyCreator(memManager, std::move(keyArgs))(&keyBuffer);
696 resIter = pvInsert(std::forward_as_tuple(std::move(*&keyBuffer)),
697 std::forward<MappedCreator>(mappedCreator));
701 KeyManager::Destroy(memManager, *&keyBuffer);
704 KeyManager::Destroy(memManager, *&keyBuffer);
708 template<
typename RKey,
typename MappedCreator,
709 typename Key =
typename std::decay<RKey>::type>
711 iterator> pvInsert(std::tuple<RKey>&& key, MappedCreator&& mappedCreator)
713 return IteratorProxy(mHashMultiMap.AddCrt(
714 std::forward<RKey>(std::get<0>(key)), std::forward<MappedCreator>(mappedCreator)));
717 template<
typename Iterator>
718 void pvInsert(Iterator first, Iterator last, std::true_type )
720 mHashMultiMap.Add(first, last);
723 template<
typename Iterator>
724 void pvInsert(Iterator first, Iterator last, std::false_type )
726 for (Iterator iter = first; iter != last; ++iter)
731 HashMultiMap mHashMultiMap;
743 template<
typename TKey,
typename TMapped,
744 typename THashFunc = HashCoder<TKey>,
745 typename TEqualFunc = std::equal_to<TKey>,
746 typename TAllocator = std::allocator<std::pair<const TKey, TMapped>>>
748 HashMultiMap<TKey, TMapped, HashTraitsStd<TKey, THashFunc, TEqualFunc, HashBucketOpenDefault>,
749 MemManagerStd<TAllocator>>>
764 using UnorderedMultiMap::UnorderedMultiMap;
779 template<
typename ValueFilter>
784 return cont.get_nested_container().Remove(pairFilter);
788 #ifdef MOMO_HAS_DEDUCTION_GUIDES
790 #define MOMO_DECLARE_DEDUCTION_GUIDES(unordered_multimap) \
791 template<typename Iterator, \
792 typename Key = std::remove_const_t<typename std::iterator_traits<Iterator>::value_type::first_type>, \
793 typename Mapped = typename std::iterator_traits<Iterator>::value_type::second_type> \
794 unordered_multimap(Iterator, Iterator) \
795 -> unordered_multimap<Key, Mapped>; \
796 template<typename Iterator, \
797 typename Key = std::remove_const_t<typename std::iterator_traits<Iterator>::value_type::first_type>, \
798 typename Mapped = typename std::iterator_traits<Iterator>::value_type::second_type, \
799 typename Allocator = std::allocator<std::pair<const Key, Mapped>>, \
800 typename = decltype(std::declval<Allocator&>().allocate(size_t{}))> \
801 unordered_multimap(Iterator, Iterator, size_t, Allocator = Allocator()) \
802 -> unordered_multimap<Key, Mapped, HashCoder<Key>, std::equal_to<Key>, Allocator>; \
803 template<typename Iterator, typename HashFunc, \
804 typename Key = std::remove_const_t<typename std::iterator_traits<Iterator>::value_type::first_type>, \
805 typename Mapped = typename std::iterator_traits<Iterator>::value_type::second_type, \
806 typename Allocator = std::allocator<std::pair<const Key, Mapped>>, \
807 typename = decltype(std::declval<HashFunc&>()(std::declval<const Key&>())), \
808 typename = decltype(std::declval<Allocator&>().allocate(size_t{}))> \
809 unordered_multimap(Iterator, Iterator, size_t, HashFunc, Allocator = Allocator()) \
810 -> unordered_multimap<Key, Mapped, HashFunc, std::equal_to<Key>, Allocator>; \
811 template<typename Iterator, typename HashFunc, typename EqualFunc, \
812 typename Key = std::remove_const_t<typename std::iterator_traits<Iterator>::value_type::first_type>, \
813 typename Mapped = typename std::iterator_traits<Iterator>::value_type::second_type, \
814 typename Allocator = std::allocator<std::pair<const Key, Mapped>>, \
815 typename = decltype(std::declval<HashFunc&>()(std::declval<const Key&>())), \
816 typename = decltype(std::declval<EqualFunc&>()(std::declval<const Key&>(), std::declval<const Key&>()))> \
817 unordered_multimap(Iterator, Iterator, size_t, HashFunc, EqualFunc, Allocator = Allocator()) \
818 -> unordered_multimap<Key, Mapped, HashFunc, EqualFunc, Allocator>; \
819 template<typename Key, typename Mapped> \
820 unordered_multimap(std::initializer_list<std::pair<Key, Mapped>>) \
821 -> unordered_multimap<Key, Mapped>; \
822 template<typename Key, typename Mapped, \
823 typename Allocator = std::allocator<std::pair<const Key, Mapped>>, \
824 typename = decltype(std::declval<Allocator&>().allocate(size_t{}))> \
825 unordered_multimap(std::initializer_list<std::pair<Key, Mapped>>, size_t, Allocator = Allocator()) \
826 -> unordered_multimap<Key, Mapped, HashCoder<Key>, std::equal_to<Key>, Allocator>; \
827 template<typename Key, typename Mapped, typename HashFunc, \
828 typename Allocator = std::allocator<std::pair<const Key, Mapped>>, \
829 typename = decltype(std::declval<HashFunc&>()(std::declval<const Key&>())), \
830 typename = decltype(std::declval<Allocator&>().allocate(size_t{}))> \
831 unordered_multimap(std::initializer_list<std::pair<Key, Mapped>>, size_t, HashFunc, Allocator = Allocator()) \
832 -> unordered_multimap<Key, Mapped, HashFunc, std::equal_to<Key>, Allocator>; \
833 template<typename Key, typename Mapped, typename HashFunc, typename EqualFunc, \
834 typename Allocator = std::allocator<std::pair<const Key, Mapped>>, \
835 typename = decltype(std::declval<HashFunc&>()(std::declval<const Key&>())), \
836 typename = decltype(std::declval<EqualFunc&>()(std::declval<const Key&>(), std::declval<const Key&>()))> \
837 unordered_multimap(std::initializer_list<std::pair<Key, Mapped>>, size_t, HashFunc, EqualFunc, Allocator = Allocator()) \
838 -> unordered_multimap<Key, Mapped, HashFunc, EqualFunc, Allocator>;
840 MOMO_DECLARE_DEDUCTION_GUIDES(unordered_multimap)
841 MOMO_DECLARE_DEDUCTION_GUIDES(unordered_multimap_open)
843 #undef MOMO_DECLARE_DEDUCTION_GUIDES
845 #endif // MOMO_HAS_DEDUCTION_GUIDES
851 #endif // MOMO_INCLUDE_GUARD_STDISH_UNORDERED_MULTIMAP
friend void swap(unordered_multimap &left, unordered_multimap &right) noexcept
Definition: unordered_multimap.h:270
MOMO_FORCEINLINE momo::internal::EnableIf< IsValidKeyArg< KeyArg >::value, std::pair< iterator, iterator > > equal_range(const KeyArg &key)
Definition: unordered_multimap.h:427
Definition: ObjectManager.h:196
internal::HashMultiMapIterator< KeyIterator, Settings > Iterator
Definition: HashMultiMap.h:674
size_type max_size() const noexcept
Definition: unordered_multimap.h:333
void insert(std::initializer_list< value_type > values)
Definition: unordered_multimap.h:498
unordered_multimap(const unordered_multimap &right)
Definition: unordered_multimap.h:216
unordered_multimap(unordered_multimap &&right, const momo::internal::Identity< allocator_type > &alloc) noexcept(std::is_empty< allocator_type >::value)
Definition: unordered_multimap.h:209
Definition: HashMultiMap.h:182
ConstIterator MakeIterator(ConstKeyIterator keyIter, size_t valueIndex=0) const
Definition: HashMultiMap.h:1126
TReference< typename BaseIterator::Reference > Reference
Definition: IteratorUtility.h:396
TAllocator allocator_type
Definition: unordered_multimap.h:75
TMapped mapped_type
Definition: unordered_multimap.h:72
unordered_multimap(std::initializer_list< value_type > values, size_type bucketCount, const hasher &hashFunc, const allocator_type &alloc=allocator_type())
Definition: unordered_multimap.h:191
iterator erase(iterator where)
Definition: unordered_multimap.h:562
void swap(unordered_multimap &right) noexcept
Definition: unordered_multimap.h:263
unordered_multimap_open()
Definition: unordered_multimap.h:766
THashTraits HashTraits
Definition: HashMultiMap.h:564
const_iterator cbegin() const noexcept
Definition: unordered_multimap.h:305
Definition: MapUtility.h:1004
const nested_container_type & get_nested_container() const noexcept
Definition: unordered_multimap.h:275
const_iterator end() const noexcept
Definition: unordered_multimap.h:295
MOMO_FORCEINLINE momo::internal::EnableIf< IsValidKeyArg< KeyArg >::value, size_type > count(const KeyArg &key) const
Definition: unordered_multimap.h:388
iterator erase(const_iterator where)
Definition: unordered_multimap.h:552
unordered_multimap(std::initializer_list< value_type > values, size_type bucketCount, const allocator_type &alloc=allocator_type())
Definition: unordered_multimap.h:185
unordered_multimap()
Definition: unordered_multimap.h:122
const_iterator begin() const noexcept
Definition: unordered_multimap.h:285
unordered_multimap(Iterator first, Iterator last, size_type bucketCount, const allocator_type &alloc=allocator_type())
Definition: unordered_multimap.h:156
size_t size_type
Definition: unordered_multimap.h:79
MOMO_FORCEINLINE momo::internal::EnableIf< IsValidKeyArg< KeyArg >::value, iterator > find(const KeyArg &key)
Definition: unordered_multimap.h:375
unordered_multimap & operator=(std::initializer_list< value_type > values)
Definition: unordered_multimap.h:255
momo::stdish::unordered_multimap is similar to std::unordered_multimap, but much more efficient in me...
Definition: unordered_multimap.h:64
HashMultiMap nested_container_type
Definition: unordered_multimap.h:77
unordered_multimap(std::initializer_list< value_type > values, size_type bucketCount, const hasher &hashFunc, const key_equal &equalFunc, const allocator_type &alloc=allocator_type())
Definition: unordered_multimap.h:197
momo::internal::EnableIf< std::is_constructible< key_type, First && >::value &&std::is_constructible< mapped_type, Second && >::value, iterator > insert(std::pair< First, Second > &&value)
Definition: unordered_multimap.h:478
unordered_multimap(Iterator first, Iterator last, size_type bucketCount, const hasher &hashFunc, const key_equal &equalFunc, const allocator_type &alloc=allocator_type())
Definition: unordered_multimap.h:172
iterator emplace(KeyArg &&keyArg, MappedArg &&mappedArg)
Definition: unordered_multimap.h:526
iterator emplace(std::piecewise_construct_t, std::tuple< KeyArgs... > keyArgs, std::tuple< MappedArgs... > mappedArgs)
Definition: unordered_multimap.h:539
KeyIterator GetKeyIterator() const noexcept
Definition: HashMultiMap.h:249
nested_container_type & get_nested_container() noexcept
Definition: unordered_multimap.h:280
iterator begin() noexcept
Definition: unordered_multimap.h:290
MemManagerStd uses allocator<unsigned char>::allocate and deallocate
Definition: MemManager.h:176
unordered_multimap(unordered_multimap &&right) noexcept
Definition: unordered_multimap.h:204
unordered_multimap(std::initializer_list< value_type > values)
Definition: unordered_multimap.h:180
TEqualFunc key_equal
Definition: unordered_multimap.h:74
unordered_multimap(Iterator first, Iterator last, size_type bucketCount, const hasher &hashFunc, const allocator_type &alloc=allocator_type())
Definition: unordered_multimap.h:164
unordered_multimap(size_type bucketCount, const allocator_type &alloc=allocator_type())
Definition: unordered_multimap.h:131
iterator emplace()
Definition: unordered_multimap.h:503
unordered_multimap(Iterator first, Iterator last)
Definition: unordered_multimap.h:150
iterator emplace_hint(const_iterator, ValueArg &&valueArg)
Definition: unordered_multimap.h:520
const_iterator cend() const noexcept
Definition: unordered_multimap.h:310
iterator end() noexcept
Definition: unordered_multimap.h:300
unordered_multimap(size_type bucketCount, const hasher &hashFunc, const key_equal &equalFunc, const allocator_type &alloc=allocator_type())
Definition: unordered_multimap.h:143
friend size_type erase_if(unordered_multimap &cont, const ValueFilter &valueFilter)
Definition: unordered_multimap.h:597
TMapped mapped_type
Definition: unordered_multimap.h:72
TKey key_type
Definition: unordered_multimap.h:71
unordered_multimap & operator=(unordered_multimap &&right) noexcept(std::is_empty< allocator_type >::value||std::allocator_traits< allocator_type >::propagate_on_container_move_assignment::value)
Definition: unordered_multimap.h:229
unordered_multimap & operator=(const unordered_multimap &right)
Definition: unordered_multimap.h:243
MOMO_FORCEINLINE std::pair< iterator, iterator > equal_range(const key_type &key)
Definition: unordered_multimap.h:412
size_type erase(const key_type &key)
Definition: unordered_multimap.h:591
typename std::enable_if< value, Type >::type EnableIf
Definition: Utility.h:174
momo::internal::EnableIf< std::is_constructible< key_type, First && >::value &&std::is_constructible< mapped_type, Second && >::value, iterator > insert(const_iterator, std::pair< First, Second > &&value)
Definition: unordered_multimap.h:487
iterator emplace(ValueArg &&valueArg)
Definition: unordered_multimap.h:514
momo::internal::HashDerivedIterator< typename HashMultiMap::Iterator, momo::internal::MapReferenceStd > iterator
Definition: unordered_multimap.h:85
momo::stdish::unordered_multimap_open is similar to std::unordered_multimap, but much more efficient ...
Definition: unordered_multimap.h:750
allocator_type get_allocator() const noexcept
Definition: unordered_multimap.h:328
friend void swap(unordered_multimap_open &left, unordered_multimap_open &right) noexcept
Definition: unordered_multimap.h:774
MOMO_FORCEINLINE const_iterator find(const key_type &key) const
Definition: unordered_multimap.h:356
Definition: IteratorUtility.h:279
THashFunc hasher
Definition: unordered_multimap.h:73
iterator erase(const_iterator first, const_iterator last)
Definition: unordered_multimap.h:567
EnableIf< true, Type > Identity
Definition: Utility.h:177
const_iterator::Pointer const_pointer
Definition: unordered_multimap.h:92
TBaseIterator BaseIterator
Definition: IteratorUtility.h:393
friend size_type erase_if(unordered_multimap_open &cont, const ValueFilter &valueFilter)
Definition: unordered_multimap.h:780
size_t size_type
Definition: unordered_multimap.h:79
MOMO_FORCEINLINE momo::internal::EnableIf< IsValidKeyArg< KeyArg >::value, const_iterator > find(const KeyArg &key) const
Definition: unordered_multimap.h:368
bool operator!=(const unordered_multimap &right) const
Definition: unordered_multimap.h:643
iterator insert(const_iterator, std::pair< key_type, mapped_type > &&value)
Definition: unordered_multimap.h:454
#define MOMO_DECLARE_PROXY_CONSTRUCTOR(Object)
Definition: Utility.h:85
iterator emplace_hint(const_iterator, KeyArg &&keyArg, MappedArg &&mappedArg)
Definition: unordered_multimap.h:533
MOMO_NODISCARD bool empty() const noexcept
Definition: unordered_multimap.h:343
momo::internal::EnableIf< std::is_constructible< key_type, const First & >::value &&std::is_constructible< mapped_type, const Second & >::value, iterator > insert(const std::pair< First, Second > &value)
Definition: unordered_multimap.h:462
key_equal key_eq() const
Definition: unordered_multimap.h:323
Definition: IteratorUtility.h:391
unordered_multimap(const unordered_multimap &right, const momo::internal::Identity< allocator_type > &alloc)
Definition: unordered_multimap.h:221
ptrdiff_t difference_type
Definition: unordered_multimap.h:80
Definition: ObjectManager.h:161
Definition: ArrayUtility.h:299
#define MOMO_FORCEINLINE
Definition: UserSettings.h:114
iterator::Reference reference
Definition: unordered_multimap.h:88
unordered_multimap(size_type bucketCount, const hasher &hashFunc, const allocator_type &alloc=allocator_type())
Definition: unordered_multimap.h:137
void clear() noexcept
Definition: unordered_multimap.h:348
MOMO_FORCEINLINE iterator find(const key_type &key)
Definition: unordered_multimap.h:361
ConstIterator GetEnd() const noexcept
Definition: HashMultiMap.h:828
hasher hash_function() const
Definition: unordered_multimap.h:318
Definition: HashMultiMap.h:560
TMemManager MemManager
Definition: HashMultiMap.h:565
MOMO_FORCEINLINE std::pair< const_iterator, const_iterator > equal_range(const key_type &key) const
Definition: unordered_multimap.h:406
unordered_multimap(const allocator_type &alloc)
Definition: unordered_multimap.h:126
MOMO_FORCEINLINE momo::internal::EnableIf< IsValidKeyArg< KeyArg >::value, std::pair< const_iterator, const_iterator > > equal_range(const KeyArg &key) const
Definition: unordered_multimap.h:419
iterator::ConstIterator const_iterator
Definition: unordered_multimap.h:86
TKey key_type
Definition: unordered_multimap.h:71
size_type size() const noexcept
Definition: unordered_multimap.h:338
momo::internal::EnableIf< std::is_constructible< key_type, const First & >::value &&std::is_constructible< mapped_type, const Second & >::value, iterator > insert(const_iterator, const std::pair< First, Second > &value)
Definition: unordered_multimap.h:470
MOMO_FORCEINLINE size_type count(const key_type &key) const
Definition: unordered_multimap.h:380
const_iterator::Reference const_reference
Definition: unordered_multimap.h:89
const_iterator::Reference const_reference
Definition: unordered_multimap.h:89
std::pair< const key_type, mapped_type > value_type
Definition: unordered_multimap.h:82
MOMO_FORCEINLINE momo::internal::EnableIf< IsValidKeyArg< KeyArg >::value, bool > contains(const KeyArg &key) const
Definition: unordered_multimap.h:401
iterator::Pointer pointer
Definition: unordered_multimap.h:91
void insert(Iterator first, Iterator last)
Definition: unordered_multimap.h:493
unordered_multimap_open & operator=(std::initializer_list< value_type > values)
Definition: unordered_multimap.h:768
MOMO_FORCEINLINE bool contains(const key_type &key) const
Definition: unordered_multimap.h:394
#define MOMO_ASSERT(expr)
Definition: UserSettings.h:162
~unordered_multimap()=default
iterator emplace_hint(const_iterator)
Definition: unordered_multimap.h:508
#define MOMO_DECLARE_PROXY_FUNCTION(Object, Func, Result)
Definition: Utility.h:94
iterator insert(std::pair< key_type, mapped_type > &&value)
Definition: unordered_multimap.h:448
bool operator==(const unordered_multimap &right) const
Definition: unordered_multimap.h:622
#define MOMO_NODISCARD
Definition: UserSettings.h:192
iterator emplace_hint(const_iterator, std::piecewise_construct_t, std::tuple< KeyArgs... > keyArgs, std::tuple< MappedArgs... > mappedArgs)
Definition: unordered_multimap.h:546
Definition: MapUtility.h:68