Flip Reference

map_iterator Class Reference

Declared in

flip/iterator.h

using map_iterator = ...;
using const_map_iterator = ...;

map_iterator satisfies the BidirectionalIterator C++ concept. It is a generic iterator that can be used to iterate other any specialization of template class Map.

All specializations of template class Map inherit from MapBase which has the methods gbegin, gcbegin, gend, gcend which return iterators of type map_iterator or const_map_iterator.

Member Types

value_type

Object

reference

Object &

pointer

Object *

iterator_category

std::bidirectional_iterator_tag

Member Functions Synopsys

Miscellaneous

key

Returns the key associated to the iterator.

added

Returns true iff the iterator was added to the container.

removed

Returns true iff the iterator was removed to the container.

resident

Returns true iff the iterator was neither added or removed.

Member Functions

key

const KeyBlob & key () const;

Returns the key associated to the iterator.

The key is guaranteed unique in the container.


added

bool added () const;

Returns true iff the iterator was added to the container.

Note: When an object is moved in the container, then the destination iterator is considered as added while the object is considered as resident. See Map::iterator for an example of it.


removed

bool removed () const;

Returns true iff the iterator was removed to the container.

Note: When an object is moved in the container, then the source iterator is considered as removed while the object is considered as resident. See Map::iterator for an example of it.


resident

bool resident () const;

Returns true iff the iterator was neither added or removed.