Field3D
detail::LoadFields< 1 > Struct Reference

#include <FieldGroup.h>

Public Member Functions

 LoadFields (LoadFieldsParams &params)
 
template<typename T >
void operator() (T)
 

Public Attributes

LoadFieldsParamsm_p
 

Detailed Description

Definition at line 133 of file FieldGroup.h.

Constructor & Destructor Documentation

◆ LoadFields()

detail::LoadFields< 1 >::LoadFields ( LoadFieldsParams & params)
inline

Definition at line 136 of file FieldGroup.h.

137 : m_p(params)
138 { }
LoadFieldsParams & m_p
Definition FieldGroup.h:166

Member Function Documentation

◆ operator()()

template<typename T >
void detail::LoadFields< 1 >::operator() ( T )
inline

Definition at line 141 of file FieldGroup.h.

142 {
143 // Load all fields of type T
144 typename Field3D::Field<T>::Vec fields =
145 m_p.in.readScalarLayers<T>(m_p.name, m_p.attribute);
146 // Add the fields to the result
147 BOOST_FOREACH (const typename Field3D::Field<T>::Ptr &ptr, fields) {
148 m_p.results.push_back(ptr);
149 }
150 // Load 'min' fields
151 typename Field3D::Field<T>::Vec minFields =
152 m_p.in.readScalarLayers<T>(m_p.name, m_p.attribute + k_minSuffix);
153 // Add the fields to the result
154 BOOST_FOREACH (const typename Field3D::Field<T>::Ptr &ptr, minFields) {
155 m_p.minResults.push_back(ptr);
156 }
157 // Load 'max' fields
158 typename Field3D::Field<T>::Vec maxFields =
159 m_p.in.readScalarLayers<T>(m_p.name, m_p.attribute + k_maxSuffix);
160 // Add the fields to the result
161 BOOST_FOREACH (const typename Field3D::Field<T>::Ptr &ptr, maxFields) {
162 m_p.maxResults.push_back(ptr);
163 }
164 }
static const char * k_minSuffix
Definition FieldGroup.h:61
static const char * k_maxSuffix
Definition FieldGroup.h:62
Field3D::Field3DInputFile & in
Definition FieldGroup.h:124
Field3D::FieldRes::Vec & minResults
Definition FieldGroup.h:128
Field3D::FieldRes::Vec & maxResults
Definition FieldGroup.h:129
Field3D::FieldRes::Vec & results
Definition FieldGroup.h:127
const std::string & attribute
Definition FieldGroup.h:126
const std::string & name
Definition FieldGroup.h:125

References detail::k_maxSuffix, and detail::k_minSuffix.

Member Data Documentation

◆ m_p

Definition at line 166 of file FieldGroup.h.


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