用于行主序 2D span 的通用类。不符合 STL 容器语义/语法。更多...
#include <span.hpp>
公共类型 | |
using | size_type = std::pair< size_t, size_t > |
用于表示 span 维度的类型。 | |
公共成员函数 | |
constexpr | base_2dspan (RowType< T, dynamic_extent > flat_view, size_t columns) |
从 span 和每行元素数量构造。更多... | |
constexpr CUDF_HOST_DEVICE auto | data () const noexcept |
返回序列开头的指针。更多... | |
constexpr CUDF_HOST_DEVICE auto | size () const noexcept |
以 pair 返回 span 的大小。更多... | |
constexpr CUDF_HOST_DEVICE auto | count () const noexcept |
返回 span 中的元素数量。更多... | |
constexpr CUDF_HOST_DEVICE bool | is_empty () const noexcept |
检查 span 是否为空。更多... | |
constexpr CUDF_HOST_DEVICE RowType< T, dynamic_extent > | operator[] (std::size_t row) const |
返回序列中第 row 个元素的引用。更多... | |
constexpr CUDF_HOST_DEVICE RowType< T, dynamic_extent > | flat_view () const |
返回 2D span 的扁平化 span。更多... | |
template<typename OtherT , template< typename, size_t > typename OtherRowType, std::enable_if_t< std::is_convertible_v< OtherRowType< OtherT, dynamic_extent >, RowType< T, dynamic_extent >>, void > * = nullptr> | |
constexpr | base_2dspan (base_2dspan< OtherT, OtherRowType > const &other) noexcept |
从另一个可转换类型的 2D span 构造一个 2D span。更多... | |
受保护属性 | |
RowType< T, dynamic_extent > | _flat |
扁平化 2D span | |
size_type | _size {0, 0} |
行数,列数 | |
用于行主序 2D span 的通用类。不符合 STL 容器语义/语法。
索引操作符返回相应的行。
|
inlineconstexpr |
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
|
inlineconstexpr |
|
inlineconstexprnoexcept |
|
inlineconstexpr |
|
inlineconstexprnoexcept |