STK++ 0.9.13
STK::hidden::VisitorArrayImpl< Visitor, Derived, SizeRows_, UnknownSize > Struct Template Reference

Specialization of VisitorArrayImpl when the number of rows is less than MaxUnrollSlice and the number of column is unknown or greater than MaxUnrollSlice. More...

#include <STK_VisitorsImpl.h>

Static Public Member Functions

static void run (Derived const &tab, Visitor &visitor)
 
static void apply (Derived &tab, Visitor &applier)
 

Detailed Description

template<typename Visitor, typename Derived, int SizeRows_>
struct STK::hidden::VisitorArrayImpl< Visitor, Derived, SizeRows_, UnknownSize >

Specialization of VisitorArrayImpl when the number of rows is less than MaxUnrollSlice and the number of column is unknown or greater than MaxUnrollSlice.

Definition at line 206 of file STK_VisitorsImpl.h.

Member Function Documentation

◆ apply()

template<typename Visitor , typename Derived , int SizeRows_>
static void STK::hidden::VisitorArrayImpl< Visitor, Derived, SizeRows_, UnknownSize >::apply ( Derived &  tab,
Visitor applier 
)
inlinestatic

Definition at line 214 of file STK_VisitorsImpl.h.

215 {
216 VisitorArrayImpl<Visitor, Derived, SizeRows_ -1, UnknownSize>::apply(tab, applier);
217 for(int j = tab.beginCols(); j < tab.endCols(); ++j)
218 tab.setValue(Idx(SizeRows_), j, applier());
219 }
#define Idx(size)

References Idx.

◆ run()

template<typename Visitor , typename Derived , int SizeRows_>
static void STK::hidden::VisitorArrayImpl< Visitor, Derived, SizeRows_, UnknownSize >::run ( Derived const tab,
Visitor visitor 
)
inlinestatic

Definition at line 208 of file STK_VisitorsImpl.h.

209 {
210 VisitorArrayImpl<Visitor, Derived, SizeRows_ -1, UnknownSize>::run(tab, visitor);
211 for(int j = tab.beginCols(); j < tab.endCols(); ++j)
212 visitor(tab.elt(Idx(SizeRows_), j), Idx(SizeRows_), j);
213 }

References Idx.


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