12#ifndef EIGEN_VECTORBLOCK_H
13#define EIGEN_VECTORBLOCK_H
16#include "./InternalHeaderCheck.h"
21template <
typename VectorType,
int Size>
22struct traits<VectorBlock<VectorType, Size> >
23 :
public traits<Block<VectorType, traits<VectorType>::Flags & RowMajorBit ? 1 : Size,
24 traits<VectorType>::Flags & RowMajorBit ? Size : 1> > {};
57template <
typename VectorType,
int Size>
58class VectorBlock :
public Block<VectorType, internal::traits<VectorType>::Flags & RowMajorBit ? 1 : Size,
59 internal::traits<VectorType>::Flags & RowMajorBit ? Size : 1> {
61 internal::traits<VectorType>::Flags &
RowMajorBit ? Size : 1>;
62 enum { IsColVector = !(internal::traits<VectorType>::Flags &
RowMajorBit) };
71 EIGEN_DEVICE_FUNC constexpr EIGEN_STRONG_INLINE
VectorBlock(VectorType& vector, Index start, Index size)
72 : Base(vector, IsColVector ? start : 0, IsColVector ? 0 : start, IsColVector ? size : 1, IsColVector ? 1 : size) {
77 EIGEN_DEVICE_FUNC
constexpr EIGEN_STRONG_INLINE
VectorBlock(VectorType& vector, Index start)
78 : Base(vector, IsColVector ? start : 0, IsColVector ? 0 : start) {}
constexpr Block(VectorType &xpr, Index i)
Definition Block.h:125
constexpr VectorBlock(VectorType &vector, Index start)
Definition VectorBlock.h:77
constexpr VectorBlock(VectorType &vector, Index start, Index size)
Definition VectorBlock.h:71
constexpr unsigned int RowMajorBit
Definition Constants.h:71