Loading [MathJax]/extensions/TeX/AMSmath.js
 
CGAL 6.1 - CGAL and Boost Property Maps
All Classes Namespaces Functions Typedefs Pages
Loading...
Searching...
No Matches
CGAL::Constant_property_map< KeyType, ValueType > Struct Template Reference

#include <CGAL/property_map.h>

Definition

template<class KeyType, class ValueType>
struct CGAL::Constant_property_map< KeyType, ValueType >

Property map that returns a fixed value.

Note that this value is chosen when the map is constructed and cannot be changed afterwards. Specifically, the free function put() does nothing.

Is model of
ReadWritePropertyMap

Public Types

typedef KeyType key_type
 
typedef ValueType value_type
 
typedef const value_typereference
 
typedef boost::read_write_property_map_tag category
 

Public Member Functions

 Constant_property_map (const value_type &default_value=value_type())
 

Public Attributes

ValueType default_value
 

Friends

reference get (const Constant_property_map &pm, const key_type &)
 Free function that returns pm.default_value.
 
void put (const Constant_property_map &, const key_type &, const value_type &)
 Free function that does nothing.
 

Member Typedef Documentation

◆ category

template<class KeyType , class ValueType >
typedef boost::read_write_property_map_tag CGAL::Constant_property_map< KeyType, ValueType >::category

◆ key_type

template<class KeyType , class ValueType >
typedef KeyType CGAL::Constant_property_map< KeyType, ValueType >::key_type

◆ reference

template<class KeyType , class ValueType >
typedef const value_type& CGAL::Constant_property_map< KeyType, ValueType >::reference

◆ value_type

template<class KeyType , class ValueType >
typedef ValueType CGAL::Constant_property_map< KeyType, ValueType >::value_type

Constructor & Destructor Documentation

◆ Constant_property_map()

template<class KeyType , class ValueType >
CGAL::Constant_property_map< KeyType, ValueType >::Constant_property_map ( const value_type default_value = value_type())

Friends And Related Symbol Documentation

◆ get

template<class KeyType , class ValueType >
reference get ( const Constant_property_map< KeyType, ValueType > &  pm,
const key_type  
)
friend

Free function that returns pm.default_value.

◆ put

template<class KeyType , class ValueType >
void put ( const Constant_property_map< KeyType, ValueType > &  ,
const key_type ,
const value_type  
)
friend

Free function that does nothing.

Member Data Documentation

◆ default_value

template<class KeyType , class ValueType >
ValueType CGAL::Constant_property_map< KeyType, ValueType >::default_value