Template Struct LayoutTraits< T, true >
Defined in File layout_traits.hpp
Struct Documentation
-
template<typename
T
>
structripple
::
LayoutTraits
<T, true> Specialization of the layout traits for caset that the template type T implements the PolymorphicLayout interface, and when the layout kind for the type is a view type, which means that it does not own the data, and the data is therefore allocated somewhere else the the storage points to it.
- Note
This should be used as layout_traits_t<T>, since that aliases the correct specializtion.
- Template Parameters
T
: The type to get the layout traits for.
Public Types
-
using
IterStorage
= std::conditional_t<is_strided_view, StridedView, ContigView> Defines the type to use when storing in an iterator.
-
using
Allocator
= typename IterStorage::Allocator Defines the type of the allocator for type T.
-
using
Value
= std::decay_t<T> Defines the value type for the layout.
-
using
IterRef
= Value Defines the type when referencing from an iterator.
-
using
IterConstRef
= const Value Defines the type of a const reference for an iterator.
-
using
IterPtr
= PointerWrapper<Value> Defines the type of a pointer for an iterator.
-
using
IterConstPtr
= const IterPtr Defines thet type of a const pointer for an iterator.
Public Static Attributes
-
constexpr LayoutKind
layout_kind
= detail::StorageLayoutKind<T>::value Defines the type of the layout for T.
-
constexpr bool
is_strided_view
= is_strided_view_v<layout_kind> True if the Layout is a strided view kind.
-
constexpr bool
is_contiguous_view
= is_contig_view_v<layout_kind> True if the Layout is a contiguous view kind.
-
constexpr bool
is_polymorphic_layout
= true Defines if the type T is a PolymorphicLayout type.
-
constexpr size_t
alignment
= Allocator::alignment Defines the alignment required for allocation of the type.