STK++ 0.9.13
STK::hidden::VisitorLowerImpl< Visitor, Derived, Arrays::by_col_ > Struct Template Reference

specialization for the general case with column oriented arrays 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>
struct STK::hidden::VisitorLowerImpl< Visitor, Derived, Arrays::by_col_ >

specialization for the general case with column oriented arrays

Definition at line 503 of file STK_VisitorsImpl.h.

Member Function Documentation

◆ apply()

template<typename Visitor , typename Derived >
static void STK::hidden::VisitorLowerImpl< Visitor, Derived, Arrays::by_col_ >::apply ( Derived &  tab,
Visitor applier 
)
inlinestatic

Definition at line 511 of file STK_VisitorsImpl.h.

512 {
513 for(int j = tab.beginCols(); j < tab.endCols(); ++j)
514 for(int i = std::max(j, tab.beginRows()); i < tab.endRows(); ++i)
515 tab.setValue(i, j, applier());
516 }

◆ run()

template<typename Visitor , typename Derived >
static void STK::hidden::VisitorLowerImpl< Visitor, Derived, Arrays::by_col_ >::run ( Derived const tab,
Visitor visitor 
)
inlinestatic

Definition at line 505 of file STK_VisitorsImpl.h.

506 {
507 for(int j = tab.beginCols(); j < tab.endCols(); ++j)
508 for(int i = std::max(j, tab.beginRows()); i < tab.endRows(); ++i)
509 visitor(tab.elt(i, j), i, j);
510 }

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