CGAL 5.6 - CGAL and Boost Property Maps
CGAL::Random_access_property_map< Container > Class Template Reference

#include <CGAL/property_map.h>

Definition

A property map with std::size_t as key-type that can be used to access the i'th element in a container with random access.

Is Model Of:
LvaluePropertyMap, constness being than of Container.

Public Types

using Iterator = std::conditional_t< std::is_const< Container >::value, typename Container::const_iterator, typename Container::iterator >
 
typedef std::size_t key_type
 
typedef std::iterator_traits< Iterator >::value_type value_type
 
typedef std::iterator_traits< Iterator >::reference reference
 
typedef boost::lvalue_property_map_tag category
 

Public Member Functions

 Random_access_property_map (Container &container)
 
decltype(auto) operator[] (key_type index) const
 

Friends

reference get (Random_access_property_map map, key_type index)
 
template<class Key >
void put (Random_access_property_map map, Key index, const value_type &value, std::enable_if_t<!std::is_const< Container >::value > *=0)
 

Related Functions

(Note that these are not member functions.)

template<class Container >
Random_access_property_map< Containermake_random_access_property_map (Container &container)