34#ifndef Foam_readFields_H
35#define Foam_readFields_H
65 template<
class FieldType>
68 if (
io.isHeaderClass<FieldType>())
71 Log <<
" Reading " <<
io.name()
72 <<
" (" << FieldType::typeName <<
')' <<
endl;
86 typedef typename VolFieldType::Internal IntVolFieldType;
92 loadAndStore<VolFieldType>(
io)
93 || loadAndStore<IntVolFieldType>(
io)
94 || loadAndStore<SurfaceFieldType>(
io)
104 for (
const word& fieldName : fieldSet_)
107 const auto* ptr = mesh_.cfindObject<
regIOobject>(fieldName);
114 << ptr->name() <<
" (" << ptr->type()
115 <<
") already in database" <<
endl;
123 mesh_.time().timeName(),
134 loadField<scalar>(
io)
135 || loadField<vector>(
io)
136 || loadField<sphericalTensor>(
io)
137 || loadField<symmTensor>(
io)
138 || loadField<tensor>(
io)
149 <<
"readFields : failed to load " << fieldName
160 static const bool debug =
false;
177 loadFields(fieldNames);
Generic GeometricField class.
@ MUST_READ
Reading required.
@ NO_WRITE
Ignore writing from objectRegistry::writeObject().
Defines the attributes of an object for which implicit objectRegistry management is supported,...
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
Mesh data needed to do the Finite Volume discretisation.
bool execute(const UList< word > &fieldNames)
readFieldsHandler(fvMesh &mesh, bool verbose=true)
Construct.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
bool store()
Register object with its registry and transfer ownership to the registry.
A class for handling words, derived from Foam::string.
#define DebugInfo
Report an information message using Foam::Info.
Ostream & endl(Ostream &os)
Add newline and flush stream.