33 template<
class FieldType>
36 const FieldType& field
39 word transFieldName(transformFieldName(field.name()));
58 if (mesh_.foundObject<VolFieldType>(fieldName))
61 <<
type() <<
": Field " << fieldName <<
" already in database" 64 transformField<VolFieldType>
66 mesh_.lookupObject<VolFieldType>(fieldName)
69 else if (mesh_.foundObject<SurfaceFieldType>(fieldName))
72 <<
type() <<
": Field " << fieldName <<
" already in database" 75 transformField<SurfaceFieldType>
77 mesh_.lookupObject<SurfaceFieldType>(fieldName)
85 mesh_.time().timeName(),
93 fieldHeader.typeHeaderOk<VolFieldType>(
false)
94 && fieldHeader.headerClassName() == VolFieldType::typeName
98 <<
type() <<
": Field " << fieldName <<
" read from file" 101 transformField<VolFieldType>
103 mesh_.lookupObject<VolFieldType>(fieldName)
108 fieldHeader.typeHeaderOk<SurfaceFieldType>(
false)
109 && fieldHeader.headerClassName() == SurfaceFieldType::typeName
113 <<
type() <<
": Field " << fieldName <<
" read from file" 116 transformField<SurfaceFieldType>
118 mesh_.lookupObject<SurfaceFieldType>(fieldName)
Ostream & endl(Ostream &os)
Add newline and flush stream.
Generic GeometricField class.
A class for handling words, derived from string.
dimensioned< tensor > dimensionedTensor
Dimensioned tensor obtained from generic dimensioned type.
#define DebugInfo
Report an information message using Foam::Info.
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
dimensionSet transform(const dimensionSet &)