Blaze  3.6
blaze::IsElements< T > Struct Template Reference

Compile time check for element selections.This type trait tests whether or not the given template parameter is an element selection (i.e. a view on elements of a dense or sparse vector). In case the type is an element selection, the value member constant is set to true, the nested type definition Type is TrueType, and the class derives from TrueType. Otherwise value is set to false, Type is FalseType, and the class derives from FalseType. More...

#include <IsElements.h>

Inherits blaze::IntegralConstant< T, N >.

Detailed Description

template<typename T>
struct blaze::IsElements< T >

Compile time check for element selections.

This type trait tests whether or not the given template parameter is an element selection (i.e. a view on elements of a dense or sparse vector). In case the type is an element selection, the value member constant is set to true, the nested type definition Type is TrueType, and the class derives from TrueType. Otherwise value is set to false, Type is FalseType, and the class derives from FalseType.

using VectorType1 = blaze::StaticVector<int,10UL>;
using VectorType2 = blaze::DynamicVector<double>;
using VectorType3 = blaze::CompressedVector<float>;
VectorType1 a;
VectorType2 b( 100UL );
VectorType3 c( 200UL );
using ElementsType1 = decltype( blaze::elements<2UL,4UL>( a ) );
using ElementsType2 = decltype( blaze::elements( b, 8UL 24UL ) );
using ElementsType3 = decltype( blaze::elements( c, 5UL, 13UL ) );
blaze::IsElements< volatile VectorType3 > // Is derived from FalseType

The documentation for this struct was generated from the following file: