py namespace
Namespaces
- namespace detail
Classes
-
template<typename Iter>struct key_iterator
-
template<typename Key, typename T>class dict
-
template<typename T>class Lict
- Dict-like data structure by std::vector and Range.
-
template<typename Graph>class VertexView
-
template<typename Graph>class EdgeView
-
template<typename Vertex, typename Graph>class AtlasView
-
template<typename _Graph>class GrAdaptor
-
template<typename T>struct RangeIterator
-
template<typename T>struct Range
- Range.
-
template<typename Key>class set
Functions
-
template<typename Key, typename T>auto operator<(const Key& key, const dict<Key, T>& m) -> bool -> auto
-
template<typename Key, typename T>auto len(const dict<Key, T>& m) -> size_t -> auto
-
template<typename T>auto enumerate(T& iterable) -> detail::EnumerateIterableWrapper< T > -> auto
- enumerate(T &iterable)
-
template<typename T>auto const_enumerate(const T& iterable) -> detail::EnumerateIterableWrapper< const T > -> auto
- const_
enumerate(const T &iterable) -
template<typename T>auto range(T start, T stop) -> Range< T > -> CONSTEXPR14 auto
- range(T start, T stop)
-
template<typename T>auto range(T stop) -> Range< T > -> CONSTEXPR14 auto
- range(T stop)
-
template<typename Key>auto operator<(const Key& key, const set<Key>& m) -> bool -> auto
-
template<typename Key>auto len(const set<Key>& m) -> size_t -> auto
Function documentation
#include <py2cpp/dict.hpp>
template<typename Key, typename T>
auto py:: operator<(const Key& key,
const dict<Key, T>& m) -> bool
Template parameters | |
---|---|
Key | |
T | |
Parameters | |
key in | |
m in | |
Returns | true |
#include <py2cpp/dict.hpp>
template<typename Key, typename T>
auto py:: len(const dict<Key, T>& m) -> size_t
Template parameters | |
---|---|
Key | |
T | |
Parameters | |
m in | |
Returns | size_t |
#include <py2cpp/enumerate.hpp>
template<typename T>
auto py:: enumerate(T& iterable) -> detail::EnumerateIterableWrapper< T >
Template parameters | |
---|---|
T | |
Parameters | |
iterable in | |
Returns | detail::EnumerateIterableWrapper<T> |
The enumerate(T &iterable)
function is a utility function that allows you to iterate over a container or range and also get the index of each element in the iteration. It returns an instance of the detail::
class, which provides a range-based for loop compatible interface.
#include <py2cpp/enumerate.hpp>
template<typename T>
auto py:: const_enumerate(const T& iterable) -> detail::EnumerateIterableWrapper< const T >
const_
Template parameters | |
---|---|
T | |
Parameters | |
iterable in | |
Returns | detail::EnumerateIterableWrapper<const T> |
The const_
function is a utility function that allows you to iterate over a constant container or range and also get the index of each element in the iteration. It returns an instance of the detail::
class, which provides a range-based for loop compatible interface. This function is useful when you want to iterate over a constant container without modifying its elements.
#include <py2cpp/range.hpp>
template<typename T>
CONSTEXPR14 auto py:: range(T start,
T stop) -> Range< T >
Template parameters | |
---|---|
T | |
Parameters | |
start in | |
stop in | |
Returns | Range<T> |
The range(T start, T stop)
function is creating a range of values from start
to stop
. It returns a Range<T>
object that represents the range. The range includes all values from start
up to, but not including, stop
.
#include <py2cpp/range.hpp>
template<typename T>
CONSTEXPR14 auto py:: range(T stop) -> Range< T >
Template parameters | |
---|---|
T | |
Parameters | |
stop in | |
Returns | Range<T> |
The range(T stop)
function is creating a range of values from 0 to stop
. It returns a Range<T>
object that represents the range. The range includes all values from 0 up to, but not including, stop
.
#include <py2cpp/set.hpp>
template<typename Key>
auto py:: operator<(const Key& key,
const set<Key>& m) -> bool
Template parameters | |
---|---|
Key | |
Parameters | |
key in | |
m in | |
Returns | true |
#include <py2cpp/set.hpp>
template<typename Key>
auto py:: len(const set<Key>& m) -> size_t
Template parameters | |
---|---|
Key | |
Parameters | |
m in | |
Returns | size_t |