MeVisLab Toolbox Reference
boost::ml_iterator_map< IteratorTraits, IDMap > Class Template Reference

This is a helper template to create an external property map for an std random access container. More...

#include <mlGraphToBoostGraph.h>

Public Types

typedef property_traits< IDMap >::key_type key_type
 
typedef IteratorTraits::value_type value_type
 
typedef IteratorTraits::value_type & reference
 
typedef lvalue_property_map_tag category
 

Public Member Functions

 ml_iterator_map (typename IteratorTraits::iterator_type i=IteratorTraits::iterator_type(), const IDMap &id=IDMap())
 Constructor, takes an iterator to the beginning of a container, for example std::vector<>.begin and a property map to map the key of type key_type to an index used by the iterator. More...
 

Public Attributes

IteratorTraits::iterator_type m_iter
 
IDMap m_id
 

Detailed Description

template<class IteratorTraits, class IDMap>
class boost::ml_iterator_map< IteratorTraits, IDMap >

This is a helper template to create an external property map for an std random access container.

Property maps are generally thin wrapper around some data source and define basically a new type which allows overloading the get(), put() and at() functions used by the boost graph library. A property map maps a key to a value so the basic functions look like this: value get(property_map, key) void put(property_map, key, value) value& at(property_map, key) This property map uses a random access iterator to store the values. The IDMap must provide a function (operator[](key)) to translate the key into an offset which can be used as index for the random access iterator. This template is expected to be used with the broken_VC_ptr_traits as IteratorTraits parameter.

Definition at line 380 of file mlGraphToBoostGraph.h.

Member Typedef Documentation

◆ category

template<class IteratorTraits , class IDMap >
typedef lvalue_property_map_tag boost::ml_iterator_map< IteratorTraits, IDMap >::category

Definition at line 387 of file mlGraphToBoostGraph.h.

◆ key_type

template<class IteratorTraits , class IDMap >
typedef property_traits<IDMap>::key_type boost::ml_iterator_map< IteratorTraits, IDMap >::key_type

Definition at line 384 of file mlGraphToBoostGraph.h.

◆ reference

template<class IteratorTraits , class IDMap >
typedef IteratorTraits::value_type& boost::ml_iterator_map< IteratorTraits, IDMap >::reference

Definition at line 386 of file mlGraphToBoostGraph.h.

◆ value_type

template<class IteratorTraits , class IDMap >
typedef IteratorTraits::value_type boost::ml_iterator_map< IteratorTraits, IDMap >::value_type

Definition at line 385 of file mlGraphToBoostGraph.h.

Constructor & Destructor Documentation

◆ ml_iterator_map()

template<class IteratorTraits , class IDMap >
boost::ml_iterator_map< IteratorTraits, IDMap >::ml_iterator_map ( typename IteratorTraits::iterator_type  i = IteratorTraits::iterator_type(),
const IDMap &  id = IDMap() 
)
inline

Constructor, takes an iterator to the beginning of a container, for example std::vector<>.begin and a property map to map the key of type key_type to an index used by the iterator.

Definition at line 392 of file mlGraphToBoostGraph.h.

Member Data Documentation

◆ m_id

template<class IteratorTraits , class IDMap >
IDMap boost::ml_iterator_map< IteratorTraits, IDMap >::m_id

Definition at line 396 of file mlGraphToBoostGraph.h.

Referenced by boost::at(), boost::get(), and boost::put().

◆ m_iter

template<class IteratorTraits , class IDMap >
IteratorTraits::iterator_type boost::ml_iterator_map< IteratorTraits, IDMap >::m_iter

Definition at line 395 of file mlGraphToBoostGraph.h.

Referenced by boost::at(), boost::get(), and boost::put().


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