Google OR-Tools v9.14
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V > Class Template Reference

#include <attr_key.h>

Classes

class  IteratorImpl

Public Types

using value_type = V
using Key = AttrKey<0, Symmetry>
using iterator = IteratorImpl<value_type>
using const_iterator = IteratorImpl<const value_type>

Public Member Functions

 AttrKey0RawSet ()=default
bool empty () const
size_t size () const
const_iterator begin () const
const_iterator end () const
iterator begin ()
iterator end ()
bool contains (Key) const
const_iterator find (Key) const
iterator find (Key)
void clear ()
size_t erase (Key)
size_t erase (const_iterator)
template<typename... Args>
std::pair< iterator, bool > try_emplace (Key, Args &&... args)
std::pair< iterator, bool > insert (const value_type &v)

Detailed Description

template<typename Symmetry, typename V>
class operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >

A set of zero or one AttrKey<0, Symmetry>, V. This is used to make implementations of AttrDiff and AttrStorage uniform. V must by default constructible, trivially destructible and copyable (we'll fail to compile otherwise). After c++26, optional is a sequence container, so this can pretty much become std::optional<AttrKey<0, Symmetry>> + find().

Definition at line 240 of file attr_key.h.

Member Typedef Documentation

◆ const_iterator

template<typename Symmetry, typename V>
using operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::const_iterator = IteratorImpl<const value_type>

Definition at line 286 of file attr_key.h.

◆ iterator

template<typename Symmetry, typename V>
using operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::iterator = IteratorImpl<value_type>

Definition at line 285 of file attr_key.h.

◆ Key

template<typename Symmetry, typename V>
using operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::Key = AttrKey<0, Symmetry>

Definition at line 243 of file attr_key.h.

◆ value_type

template<typename Symmetry, typename V>
using operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::value_type = V

Definition at line 242 of file attr_key.h.

Constructor & Destructor Documentation

◆ AttrKey0RawSet()

template<typename Symmetry, typename V>
operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::AttrKey0RawSet ( )
default

Member Function Documentation

◆ begin() [1/2]

template<typename Symmetry, typename V>
iterator operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::begin ( )
inline

Definition at line 297 of file attr_key.h.

◆ begin() [2/2]

template<typename Symmetry, typename V>
const_iterator operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::begin ( ) const
inline

Definition at line 293 of file attr_key.h.

◆ clear()

template<typename Symmetry, typename V>
void operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::clear ( )
inline

Definition at line 304 of file attr_key.h.

◆ contains()

template<typename Symmetry, typename V>
bool operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::contains ( Key ) const
inline

Definition at line 300 of file attr_key.h.

◆ empty()

template<typename Symmetry, typename V>
bool operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::empty ( ) const
inline

Definition at line 290 of file attr_key.h.

◆ end() [1/2]

template<typename Symmetry, typename V>
iterator operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::end ( )
inline

Definition at line 298 of file attr_key.h.

◆ end() [2/2]

template<typename Symmetry, typename V>
const_iterator operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::end ( ) const
inline

Definition at line 296 of file attr_key.h.

◆ erase() [1/2]

template<typename Symmetry, typename V>
size_t operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::erase ( const_iterator )
inline

Definition at line 312 of file attr_key.h.

◆ erase() [2/2]

template<typename Symmetry, typename V>
size_t operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::erase ( Key )
inline

Definition at line 305 of file attr_key.h.

◆ find() [1/2]

template<typename Symmetry, typename V>
iterator operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::find ( Key )
inline

Definition at line 302 of file attr_key.h.

◆ find() [2/2]

template<typename Symmetry, typename V>
const_iterator operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::find ( Key ) const
inline

Definition at line 301 of file attr_key.h.

◆ insert()

template<typename Symmetry, typename V>
std::pair< iterator, bool > operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::insert ( const value_type & v)
inline

Definition at line 324 of file attr_key.h.

◆ size()

template<typename Symmetry, typename V>
size_t operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::size ( ) const
inline

Definition at line 291 of file attr_key.h.

◆ try_emplace()

template<typename Symmetry, typename V>
template<typename... Args>
std::pair< iterator, bool > operations_research::math_opt::detail::AttrKey0RawSet< Symmetry, V >::try_emplace ( Key ,
Args &&... args )
inline

Definition at line 315 of file attr_key.h.


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