Public Types | Public Member Functions | Private Attributes | Friends | List of all members
shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference > Struct Template Reference

#include <stdmap_shims.h>

Inheritance diagram for shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >:

Public Types

using type = TT
 

Public Member Functions

 iter (typename mapmap_t::iterator it)
 
 iter (typename listmap_t::iterator it)
 
TT & operator* ()
 
TT * operator-> ()
 
TT const * operator-> () const
 
TT & operator++ ()
 
bool operator== (iter other) const
 
bool operator!= (iter other) const
 
template<typename II >
std::enable_if_t< std::is_same_v< typename mapmap_t::iterator, II >, II > get (II)
 
template<typename II >
std::enable_if_t< std::is_same_v< typename listmap_t::iterator, II >, II > get (II)
 

Private Attributes

iterator_tuple _iters
 

Friends

template<typename IIL , typename IIR >
std::enable_if_t< !std::is_same_v< IIL, IIR > &&std::is_same_v< std::remove_const_t< typename IIL::type >, std::remove_const_t< typename IIR::type > >, booloperator== (IIL, IIR)
 
template<typename IIL , typename IIR >
std::enable_if_t< !std::is_same_v< IIL, IIR > &&std::is_same_v< std::remove_const_t< typename IIL::type >, std::remove_const_t< typename IIR::type > >, booloperator!= (IIL, IIR)
 

Detailed Description

template<class Key, class T, class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category, class TT, class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
struct shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >

Definition at line 52 of file stdmap_shims.h.

Member Typedef Documentation

template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
using shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::type = TT

Definition at line 53 of file stdmap_shims.h.

Constructor & Destructor Documentation

template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::iter ( typename mapmap_t::iterator  it)
inline

Definition at line 55 of file stdmap_shims.h.

55 { _iters.mapmap_iter = it; }
iterator_tuple _iters
Definition: stdmap_shims.h:124
mapmap_t::iterator mapmap_iter
Definition: stdmap_shims.h:43
template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::iter ( typename listmap_t::iterator  it)
inline

Definition at line 56 of file stdmap_shims.h.

56 { _iters.listmap_iter = it; }
iterator_tuple _iters
Definition: stdmap_shims.h:124
listmap_t::iterator listmap_iter
Definition: stdmap_shims.h:44

Member Function Documentation

template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
template<typename II >
std::enable_if_t<std::is_same_v<typename mapmap_t::iterator, II>, II> shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::get ( II  )
inline

Definition at line 94 of file stdmap_shims.h.

96  {
97  return _iters.mapmap_iter;
98  }
iterator_tuple _iters
Definition: stdmap_shims.h:124
mapmap_t::iterator mapmap_iter
Definition: stdmap_shims.h:43
template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
template<typename II >
std::enable_if_t<std::is_same_v<typename listmap_t::iterator, II>, II> shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::get ( II  )
inline

Definition at line 102 of file stdmap_shims.h.

103  {
104  return _iters.listmap_iter;
105  }
iterator_tuple _iters
Definition: stdmap_shims.h:124
listmap_t::iterator listmap_iter
Definition: stdmap_shims.h:44
template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
bool shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::operator!= ( iter< Category, TT, Distance, Pointer, Reference >  other) const
inline

Definition at line 88 of file stdmap_shims.h.

89  {
90  return !operator==(other);
91  }
bool operator==(iter other) const
Definition: stdmap_shims.h:80
template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
TT& shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::operator* ( )
inline

Definition at line 58 of file stdmap_shims.h.

59  {
61  }
bool isSnippetMode(bool m)
Definition: parse_shims.cc:9
iterator_tuple _iters
Definition: stdmap_shims.h:124
listmap_t::iterator listmap_iter
Definition: stdmap_shims.h:44
mapmap_t::iterator mapmap_iter
Definition: stdmap_shims.h:43
template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
TT& shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::operator++ ( )
inline

Definition at line 73 of file stdmap_shims.h.

74  {
75  return isSnippetMode() ? *(_iters.listmap_iter++) :
76  *(_iters.mapmap_iter++);
77  }
bool isSnippetMode(bool m)
Definition: parse_shims.cc:9
iterator_tuple _iters
Definition: stdmap_shims.h:124
listmap_t::iterator listmap_iter
Definition: stdmap_shims.h:44
mapmap_t::iterator mapmap_iter
Definition: stdmap_shims.h:43
template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
TT* shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::operator-> ( )
inline

Definition at line 63 of file stdmap_shims.h.

64  {
66  }
bool isSnippetMode(bool m)
Definition: parse_shims.cc:9
iterator_tuple _iters
Definition: stdmap_shims.h:124
listmap_t::iterator listmap_iter
Definition: stdmap_shims.h:44
mapmap_t::iterator mapmap_iter
Definition: stdmap_shims.h:43
template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
TT const* shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::operator-> ( ) const
inline

Definition at line 67 of file stdmap_shims.h.

68  {
70  }
bool isSnippetMode(bool m)
Definition: parse_shims.cc:9
iterator_tuple _iters
Definition: stdmap_shims.h:124
listmap_t::iterator listmap_iter
Definition: stdmap_shims.h:44
mapmap_t::iterator mapmap_iter
Definition: stdmap_shims.h:43
template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
bool shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::operator== ( iter< Category, TT, Distance, Pointer, Reference >  other) const
inline

Definition at line 80 of file stdmap_shims.h.

81  {
82  return isSnippetMode() ?
83  _iters.listmap_iter == other._iters.listmap_iter :
84  _iters.mapmap_iter == other._iters.mapmap_iter;
85  }
bool isSnippetMode(bool m)
Definition: parse_shims.cc:9
iterator_tuple _iters
Definition: stdmap_shims.h:124
listmap_t::iterator listmap_iter
Definition: stdmap_shims.h:44
mapmap_t::iterator mapmap_iter
Definition: stdmap_shims.h:43

Friends And Related Function Documentation

template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
template<typename IIL , typename IIR >
std::enable_if_t< !std::is_same_v<IIL, IIR> && std::is_same_v<std::remove_const_t<typename IIL::type>, std::remove_const_t<typename IIR::type> >, bool> operator!= ( IIL  left,
IIR  right 
)
friend

Definition at line 339 of file stdmap_shims.h.

340  {
341  return !operator==(left, right);
342  }
bool operator==(iter other) const
Definition: stdmap_shims.h:80
template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
template<typename IIL , typename IIR >
std::enable_if_t< !std::is_same_v<IIL, IIR> && std::is_same_v<std::remove_const_t<typename IIL::type>, std::remove_const_t<typename IIR::type> >, bool> operator== ( IIL  left,
IIR  right 
)
friend

Definition at line 327 of file stdmap_shims.h.

328  {
329  return isSnippetMode() ?
330  left._iters.listmap_iter == right._iters.listmap_iter :
331  left._iters.mapmap_iter == right._iters.mapmap_iter;
332  }
bool isSnippetMode(bool m)
Definition: parse_shims.cc:9

Member Data Documentation

template<class Key , class T , class Compare = std::less<Key>, class Allocator = std::allocator<std::pair<const Key, T>>>
template<class Category , class TT , class Distance = std::ptrdiff_t, class Pointer = TT*, class Reference = TT&>
iterator_tuple shims::map< Key, T, Compare, Allocator >::iter< Category, TT, Distance, Pointer, Reference >::_iters
private

Definition at line 124 of file stdmap_shims.h.


The documentation for this struct was generated from the following file: