Go to the documentation of this file.
57 "fileModificationSkew",
69 fileCheckTypesNames.read
73 "fileModificationChecking"
110 "fileModificationChecking"
125 ownedByRegistry_(false),
148 ownedByRegistry_(false),
149 watchIndex_(rio.watchIndex_),
150 eventNo_(db().getEvent()),
163 ownedByRegistry_(false),
165 eventNo_(db().getEvent()),
185 ownedByRegistry_(
false),
187 eventNo_(db().getEvent()),
205 ownedByRegistry_(
false),
207 eventNo_(db().getEvent()),
210 if (registerObject())
222 if (objectRegistry::debug)
224 Info<<
"Destroying regIOobject called " <<
name()
225 <<
" of type " <<
type()
226 <<
" in directory " <<
path()
238 if (!ownedByRegistry_)
253 registered_ = db().checkIn(*
this);
258 && readOpt() == MUST_READ_IF_MODIFIED
259 && time().runTimeModifiable()
262 if (watchIndex_ != -1)
265 <<
"Object " << objectPath()
266 <<
" already watched with index " << watchIndex_
277 watchIndex_ = time().addWatch(
f);
289 <<
"failed to register object " << objectPath()
290 <<
" the name already exists in the objectRegistry" <<
endl
291 <<
"Contents:" << db().sortedToc()
297 <<
"failed to register object " << objectPath()
298 <<
" the name already exists in the objectRegistry"
314 if (watchIndex_ != -1)
316 time().removeWatch(watchIndex_);
319 return db().checkOut(*
this);
373 return upToDate(a) && upToDate(
b);
384 return upToDate(a) && upToDate(
b) && upToDate(
c);
396 return upToDate(a) && upToDate(
b) && upToDate(
c) && upToDate(d);
403 eventNo_ = db().getEvent();
415 if (registerObject())
437 if (registerObject())
void operator=(const regIOobject &)
Dissallow assignment.
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
A class for handling words, derived from string.
addfileModificationCheckingToOpt addfileModificationCheckingToOpt_("fileModificationChecking")
A class for handling file names.
static word defaultRegion
Return the default region name.
static const NamedEnum< fileCheckTypes, 4 > fileCheckTypesNames
bool upToDate(const regIOobject &) const
Return true if up-to-date with respect to given object.
static const label labelMax
addfileModificationCheckingToOpt(const char *name)
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
bool checkIn()
Add object to registry.
regIOobject(const IOobject &, const bool isTime=false)
Construct from IOobject. Optional flag for if IOobject is the.
Ostream & endl(Ostream &os)
Add newline and flush stream.
const fileName & instance() const
const objectRegistry & db() const
Return the local objectRegistry.
bool registered_
Is this object registered with the registry.
int optimisationSwitch(const char *name, const int defaultValue=0)
Lookup optimisation switch or add default value.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
const dimensionedScalar b
Wien displacement law constant: default SI units: [m.K].
virtual void readData(Foam::Istream &is)
Read.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
bool & registerObject()
Register object created from this IOobject with registry if true.
label eventNo() const
Event number at last update.
virtual ~addfileModificationCheckingToOpt()
fileCheckTypes
Types of communications.
void operator=(const IOobject &)
static bool masterOnlyReading
To flag master-only reading of objects.
errorManip< error > abort(error &err)
virtual void rename(const word &newName)
Rename.
virtual void writeData(Foam::Ostream &os) const
Write.
void setUpToDate()
Set up to date (obviously)
static fileCheckTypes fileModificationChecking
Enum read(Istream &) const
Read a word from Istream and return the corresponding.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
bool checkOut()
Remove object from registry.
virtual void rename(const word &newName)
Rename.
fileName path(UMean.rootPath()/UMean.caseName()/"graphs"/UMean.instance())
const dimensionedScalar c
Speed of light in a vacuum.
void size(const label)
Override size to be inconsistent with allocated storage.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
virtual ~regIOobject()
Destructor.
fileName::Type type(const fileName &)
Return the file type: DIRECTORY or FILE.
dictionary & optimisationSwitches()
The OptimisationSwitches sub-dictionary in the central controlDict.
static int fileModificationSkew
defineTypeNameAndDebug(combustionModel, 0)
#define WarningInFunction
Report a warning using Foam::Warning.
const fileName & local() const
void addOptimisationObject(const char *name, simpleRegIOobject *obj)
Register optimisation switch read/write object.
Abstract base class for registered object with I/O. Used in debug symbol registration.
registerOptSwitch("fileModificationSkew", int, Foam::regIOobject::fileModificationSkew)
word name(const complex &)
Return a string representation of a complex.
Initialise the NamedEnum HashTable from the static list of names.