xtensor_adaptor
Defined in xtensor/xtensor.hpp
-
template<class EC, std::size_t N, layout_type L, class Tag>
class xtensor_adaptor : public xt::xstrided_container<xtensor_adaptor<EC, N, L, Tag>>, public xt::xcontainer_semantic<xtensor_adaptor<EC, N, L, Tag>>, public extension::xtensor_adaptor_base_t<EC, N, L, Tag> Dense multidimensional container adaptor with tensor semantics and fixed dimension.
The xtensor_adaptor class implements a dense multidimensional container adaptor with tensor semantics and fixed dimension. It is used to provide a multidimensional container semantic and a tensor semantic to stl-like containers.
See also
- Template Parameters:
EC – The closure for the container type to adapt.
N – The dimension of the adaptor.
L – The layout_type of the adaptor.
Tag – The expression tag.
Constructors
-
inline xtensor_adaptor(storage_type &&storage)
Constructs an xtensor_adaptor of the given stl-like container.
- Parameters:
storage – the container to adapt
-
inline xtensor_adaptor(const storage_type &storage)
Constructs an xtensor_adaptor of the given stl-like container.
- Parameters:
storage – the container to adapt
-
template<class D>
inline xtensor_adaptor(D &&storage, const shape_type &shape, layout_type l = L) Constructs an xtensor_adaptor of the given stl-like container, with the specified shape and layout_type.
- Parameters:
storage – the container to adapt
shape – the shape of the xtensor_adaptor
l – the layout_type of the xtensor_adaptor
-
template<class D>
inline xtensor_adaptor(D &&storage, const shape_type &shape, const strides_type &strides) Constructs an xtensor_adaptor of the given stl-like container, with the specified shape and strides.
- Parameters:
storage – the container to adapt
shape – the shape of the xtensor_adaptor
strides – the strides of the xtensor_adaptor
Extended copy semantic
-
template<class E>
inline auto operator=(const xexpression<E> &e) -> self_type& The extended assignment operator.