template<typename Type, typename Map, typename FSched, typename... Uid>
gtopt::ArrayIndexTraits struct

Base classes

struct InputTraits
Input data access traits.
struct ArrayIndexBase

Public types

template<typename... Uid>
using array_table_vector_uid_idx_t = std::tuple<array_uid_idx_map_t<Uid...>, table_uid_idx_map_t<Uid...>, vector_uid_idx_t<Uid...>>
template<typename... Uid>
using array_uid_idx_map_t = base_map_t<CFNameUid, arrow_array_uid_idx_t<Uid...>>
using array_vector_uid_idx_v = InputTraits::array_vector_uid_idx_v<Uid...>
template<typename... Uid>
using arrow_array_uid_idx_t = std::tuple<ArrowChunkedArray, ArrowUidIdx<Uid...>, PresentMask>
template<typename... Uid>
using arrow_table_uid_idx_t = std::tuple<ArrowTable, ArrowUidIdx<Uid...>, PresentMask>
template<typename... Uid>
using ArrowUidIdx = UidToArrowIdx<Uid...>::UidIdx
template<typename Key, typename Value>
using base_map_t = gtopt::flat_map<Key, Value>
using CFName = std::tuple<ClassNameType, FieldNameType>
using CFNameUid = std::tuple<ClassNameType, FieldNameType, Uid>
using ClassNameType = std::string_view
using FieldNameType = std::string_view
using file_sched = FileSched
template<typename... Uid>
using idx_key_t = UidToVectorIdx<Uid...>::IndexKey
template<typename value_type, typename... Uid>
using idx_vector_t = mvector_traits<value_type, idx_key_t<Uid...>>::vector_type
using PresentMask = ArrowPresentMask
template<typename... Uid>
using table_uid_idx_map_t = base_map_t<CFName, arrow_table_uid_idx_t<Uid...>>
using uid_tuple = std::tuple<Uid...>
using value_type = Type
enum class ValueKind: std::uint8_t { integer, real, other }
C++ value kind a schedule reads from a long table's value column.
using vector_type = InputTraits::idx_vector_t<value_type, Uid...>
template<typename... Uid>
using vector_uid_idx_t = VectorUidIdx<Uid...>
template<typename... Uid>
using VectorUidIdx = UidToVectorIdx<Uid...>::UidIdx

Public static variables

template<typename Type>
static ValueKind value_kind_v
Mirrors the int32 / double dispatch of InputTraits::access_sched.

Public static functions

template<typename Type, typename RType = Type, typename FSched, typename UidIdx UidIdx, typename AccessOper, typename... Uid>
static auto access_sched(const FSched& sched, const UidIdx& uid_idx, AccessOper access_oper, Uid... uid) -> RType
template<typename Type, typename FSched, typename UidIdx UidIdx, typename... Uid>
static auto at_sched(const FSched& sched, const UidIdx& uid_idx, Uid... uid) -> Type
template<typename Type, typename... Uid>
static auto get_arrow_index(const SystemContext& system_context, std::string_view cname, std::string_view fname, const Id& id, auto& array_map, auto& table_map) -> auto
static auto make_array_index(const auto& system_context, std::string_view class_name, Map& array_table_map, const FSched& sched, const Id& id) -> array_vector_uid_idx_v
template<typename Type, typename FSched, typename UidIdx UidIdx, typename... Uid>
static auto optval_sched(const FSched& sched, const UidIdx& uid_idx, Uid... uid) -> std::optional<Type>
template<typename Tuple>
static auto project_key(const Tuple& key, PresentMask mask) -> Tuple noexcept
template<typename Tuple, std::size_t... I>
static auto project_key_impl(const Tuple& key, PresentMask mask, std::index_sequence<I...>) -> Tuple noexcept
static auto read_arrow_table(const SystemContext& sc, std::string_view cname, std::string_view fname) -> ArrowTable

Typedef documentation

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::array_table_vector_uid_idx_t = std::tuple<array_uid_idx_map_t<Uid...>, table_uid_idx_map_t<Uid...>, vector_uid_idx_t<Uid...>>

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::array_uid_idx_map_t = base_map_t<CFNameUid, arrow_array_uid_idx_t<Uid...>>

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::arrow_array_uid_idx_t = std::tuple<ArrowChunkedArray, ArrowUidIdx<Uid...>, PresentMask>

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::arrow_table_uid_idx_t = std::tuple<ArrowTable, ArrowUidIdx<Uid...>, PresentMask>

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::ArrowUidIdx = UidToArrowIdx<Uid...>::UidIdx

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename Key, typename Value>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::base_map_t = gtopt::flat_map<Key, Value>

template<typename Type, typename Map, typename FSched, typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::CFName = std::tuple<ClassNameType, FieldNameType>

template<typename Type, typename Map, typename FSched, typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::CFNameUid = std::tuple<ClassNameType, FieldNameType, Uid>

template<typename Type, typename Map, typename FSched, typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::ClassNameType = std::string_view

template<typename Type, typename Map, typename FSched, typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::FieldNameType = std::string_view

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::idx_key_t = UidToVectorIdx<Uid...>::IndexKey

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename value_type, typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::idx_vector_t = mvector_traits<value_type, idx_key_t<Uid...>>::vector_type

template<typename Type, typename Map, typename FSched, typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::PresentMask = ArrowPresentMask

Bitmask describing which UID dimensions are present in an input table. Bit i corresponds to the i-th UID in the parameter pack. When a bit is 0, the underlying column was absent from the table and the loader has built / will look up the index with a default-constructed UID in that slot — i.e. the value is broadcast across that dimension. See UidToArrowIdx<...>::make_arrow_uids_idx.

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::table_uid_idx_map_t = base_map_t<CFName, arrow_table_uid_idx_t<Uid...>>

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::vector_uid_idx_t = VectorUidIdx<Uid...>

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename... Uid>
using gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::VectorUidIdx = UidToVectorIdx<Uid...>::UidIdx

Function documentation

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename Type, typename RType = Type, typename FSched, typename UidIdx UidIdx, typename AccessOper, typename... Uid>
static RType gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::access_sched(const FSched& sched, const UidIdx& uid_idx, AccessOper access_oper, Uid... uid)

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename Type, typename FSched, typename UidIdx UidIdx, typename... Uid>
static Type gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::at_sched(const FSched& sched, const UidIdx& uid_idx, Uid... uid)

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename Type, typename FSched, typename UidIdx UidIdx, typename... Uid>
static std::optional<Type> gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::optval_sched(const FSched& sched, const UidIdx& uid_idx, Uid... uid)

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename Tuple>
static Tuple gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::project_key(const Tuple& key, PresentMask mask) noexcept

template<typename Type, typename Map, typename FSched, typename... Uid> template<typename Tuple, std::size_t... I>
static Tuple gtopt::ArrayIndexTraits<Type, Map, FSched, Uid>::project_key_impl(const Tuple& key, PresentMask mask, std::index_sequence<I...>) noexcept

Project a UID tuple onto the dimensions present in mask. Slots whose corresponding bit is zero are replaced by a default-constructed UID — this is the same sentinel that the loader stored in the row index when the column was absent, so the projected key always finds the row that the file intends to broadcast.