ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
|
Allow structs to be accessed like std::tuple. More...
#include <array>
#include <cassert>
#include <ostream>
#include <string>
#include <tuple>
#include <utility>
Go to the source code of this file.
Namespaces | |
namespace | dfe |
namespace | dfe::namedtuple_impl |
Macros | |
#define | DFE_NAMEDTUPLE(name,...) |
Functions | |
template<std::size_t N> | |
constexpr std::array < std::string, N > | dfe::namedtuple_impl::unstringify (const char *str) |
template<typename Names , typename Values , std::size_t... I> | |
std::ostream & | dfe::namedtuple_impl::print_tuple (std::ostream &os, const Names &n, const Values &v, std::index_sequence< I...>) |
Allow structs to be accessed like std::tuple.
get<I>(named_tuple)
Definition in file dfe_namedtuple.hpp.
#define DFE_NAMEDTUPLE | ( | name, | |
... | |||
) |
Enable tuple-like access and conversion for selected class/struct members.
This allows access to the selected members via .get<I>()
or get<I>(...)
, conversion to equivalent std::tuple<...>
via implicit conversion or explicitely via .tuple()
, and assignment from equivalent tuples. The names can be accessed via ::names()
.
Definition at line 45 of file dfe_namedtuple.hpp.
View newest version in sPHENIX GitHub at line 45 of file dfe_namedtuple.hpp