File failed to load: https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.3/config/TeX-MML-AM_CHTML/MathJax.js
DGtal 2.0.0
DGtal::concepts::CSTLAssociativeContainer< T > Struct Template Reference

Aim: Defines the concept describing an Associative Container of the STL (https://www.sgi.com/tech/stl/AssociativeContainer.html). More...

#include <DGtal/base/CSTLAssociativeContainer.h>

Inheritance diagram for DGtal::concepts::CSTLAssociativeContainer< T >:
[legend]

Public Types

typedef T::iterator iterator
typedef T::value_type value_type
typedef T::key_type key_type
typedef T::size_type size_type
typedef T::const_iterator const_iterator

Public Member Functions

 BOOST_CONCEPT_USAGE (CSTLAssociativeContainer)

Private Member Functions

void const_constraints (const T &cc)

Private Attributes

x
iterator p
iterator q
const_iterator ci
value_type val
key_type key
size_type n
std::pair< iterator, iteratorr
std::pair< const_iterator, const_iteratorcr

Detailed Description

template<typename T>
struct DGtal::concepts::CSTLAssociativeContainer< T >

Aim: Defines the concept describing an Associative Container of the STL (https://www.sgi.com/tech/stl/AssociativeContainer.html).

DescriptionDescription of concept 'CSTLAssociativeContainer'

Note
This concept can also be found in the boost library under the name boost::AssociativeContainer. However, there is a issue in this concept (problem in boost 1.58 but present in several releases) which requires the container to be "sorted". As a consequence, boost::unordered_set does not satisfy the concept.

Refinement of

Provided types:

Notation:

For a complete desccription of this concept, please check https://www.sgi.com/tech/stl/AssociativeContainer.html.

Invariants

Models

std::set, std::unordered_set (c++11), boost::unordered_set.

Notes

Template Parameters
Tthe type that is checked. T should be a model of CSTLAssociativeContainer.

Definition at line 102 of file CSTLAssociativeContainer.h.

Member Typedef Documentation

◆ const_iterator

template<typename T>
typedef T::const_iterator DGtal::concepts::CSTLAssociativeContainer< T >::const_iterator

Definition at line 110 of file CSTLAssociativeContainer.h.

◆ iterator

template<typename T>
typedef T::iterator DGtal::concepts::CSTLAssociativeContainer< T >::iterator

Definition at line 106 of file CSTLAssociativeContainer.h.

◆ key_type

template<typename T>
typedef T::key_type DGtal::concepts::CSTLAssociativeContainer< T >::key_type

Definition at line 108 of file CSTLAssociativeContainer.h.

◆ size_type

template<typename T>
typedef T::size_type DGtal::concepts::CSTLAssociativeContainer< T >::size_type

Definition at line 109 of file CSTLAssociativeContainer.h.

◆ value_type

template<typename T>
typedef T::value_type DGtal::concepts::CSTLAssociativeContainer< T >::value_type

Definition at line 107 of file CSTLAssociativeContainer.h.

Member Function Documentation

◆ BOOST_CONCEPT_USAGE()

template<typename T>
DGtal::concepts::CSTLAssociativeContainer< T >::BOOST_CONCEPT_USAGE ( CSTLAssociativeContainer< T > )
inline

◆ const_constraints()

template<typename T>
void DGtal::concepts::CSTLAssociativeContainer< T >::const_constraints ( const T & cc)
inlineprivate

Definition at line 124 of file CSTLAssociativeContainer.h.

125 {
126 ci = cc.find(key);
127 n = cc.count(key);
128 cr = cc.equal_range(key);
129 }
Aim: Defines the concept describing an Associative Container of the STL (https://www....
std::pair< const_iterator, const_iterator > cr

References ci, cr, key, and n.

Field Documentation

◆ ci

template<typename T>
const_iterator DGtal::concepts::CSTLAssociativeContainer< T >::ci
private

Definition at line 135 of file CSTLAssociativeContainer.h.

Referenced by const_constraints().

◆ cr

template<typename T>
std::pair<const_iterator,const_iterator> DGtal::concepts::CSTLAssociativeContainer< T >::cr
private

Definition at line 140 of file CSTLAssociativeContainer.h.

Referenced by const_constraints().

◆ key

template<typename T>
key_type DGtal::concepts::CSTLAssociativeContainer< T >::key
private

Definition at line 137 of file CSTLAssociativeContainer.h.

Referenced by BOOST_CONCEPT_USAGE(), and const_constraints().

◆ n

template<typename T>
size_type DGtal::concepts::CSTLAssociativeContainer< T >::n
private

Definition at line 138 of file CSTLAssociativeContainer.h.

Referenced by BOOST_CONCEPT_USAGE(), and const_constraints().

◆ p

template<typename T>
iterator DGtal::concepts::CSTLAssociativeContainer< T >::p
private

Definition at line 134 of file CSTLAssociativeContainer.h.

Referenced by BOOST_CONCEPT_USAGE().

◆ q

template<typename T>
iterator DGtal::concepts::CSTLAssociativeContainer< T >::q
private

Definition at line 134 of file CSTLAssociativeContainer.h.

Referenced by BOOST_CONCEPT_USAGE().

◆ r

template<typename T>
std::pair<iterator,iterator> DGtal::concepts::CSTLAssociativeContainer< T >::r
private

Definition at line 139 of file CSTLAssociativeContainer.h.

Referenced by BOOST_CONCEPT_USAGE().

◆ val

template<typename T>
value_type DGtal::concepts::CSTLAssociativeContainer< T >::val
private

Definition at line 136 of file CSTLAssociativeContainer.h.

◆ x

template<typename T>
T DGtal::concepts::CSTLAssociativeContainer< T >::x
private

Definition at line 133 of file CSTLAssociativeContainer.h.

Referenced by BOOST_CONCEPT_USAGE().


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