Lumiera
0.pre.03
»edit your freedom«
|
Go to the source code of this file.
Some small helpers and convenience shortcuts to ease working with collections and sequences (given by iterator).
Mostly, these are tiny bits of existing functionality, just packaged in a more fluent and readable way.
Definition in file util-coll.hpp.
Classes | |
struct | can_direct_access_Last< T > |
struct | treat_as_LumieraIterator< T > |
struct | treat_as_STL_Container< T > |
Functions | |
template<typename COL > | |
void | __ensure_nonempty (COL const &coll) |
template<typename COLL , typename = enable_if< treat_as_STL_Container<COLL>>> | |
auto | first (COLL const &coll) |
access the first element of a STL-like container. More... | |
template<typename IT , typename = enable_if<treat_as_LumieraIterator<IT>>> | |
auto | first (IT ii) |
extract the first element yielded by an Lumiera Forward Iterator. More... | |
template<typename COLL , typename = enable_if< can_direct_access_Last<COLL>>> | |
auto | last (COLL const &coll) |
access the last element of a STL-like container. More... | |
template<class IT > | |
auto | max (IT &&elms) |
template<class CON > | |
auto | max (CON const &elms) |
template<class IT > | |
auto | min (IT &&elms) |
template<class CON > | |
auto | min (CON const &elms) |
Namespaces |
|
inline |
access the first element of a STL-like container.
const&
and the const
is stripped before access. Definition at line 102 of file util-coll.hpp.
References util::first().
Referenced by util::first().
|
inline |
access the last element of a STL-like container.
const&
and the const
is stripped before access. Definition at line 117 of file util-coll.hpp.
References util::last().
Referenced by util::last().
|
inline |
extract the first element yielded by an Lumiera Forward Iterator.
Definition at line 132 of file util-coll.hpp.
References util::first().