54Foam::functionObjects::syncObjects::syncObjects
75 <<
" root:" << root_ <<
endl;
93 for (
const int proci : pBufs.allProcs())
108 Pout<<
"** to processor " << proci
109 <<
" sendObr:" << sendObr.objectPath()
110 <<
" sending dictionary:" << sendDataDict <<
endl;
112 UOPstream
os(proci, pBufs);
117 pBufs.finishedSends();
119 for (
const int proci : pBufs.allProcs())
127 UIPstream is(proci, pBufs);
131 Pout<<
"** from processor " << proci
132 <<
" receiveObr:" << receiveObr.objectPath()
133 <<
" received dictionary:" << fromProcDict <<
endl;
138 const_cast<objectRegistry&
>(receiveObr)
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
fileName objectPath() const
The complete path + object name.
Buffers for inter-processor communications streams (UOPstream, UIPstream).
UPstream::rangeType allProcs() const noexcept
Range of ranks indices associated with PstreamBuffers.
void finishedSends(const bool wait=true)
Mark the send phase as being finished.
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Input inter-processor communications stream using MPI send/recv etc. - operating on external buffer.
Output inter-processor communications stream using MPI send/recv etc. - operating on external buffer.
static bool parRun(const bool on) noexcept
Set as parallel run on/off.
static label commWarn(const label communicator) noexcept
Alter communicator debugging setting. Warns for use of any communicator differing from specified....
static constexpr int commGlobal() noexcept
Communicator for all ranks, irrespective of any local worlds.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
A class for handling file names.
static const fileName null
An empty fileName.
Abstract base-class for Time/database function objects.
const word & name() const noexcept
Return the name of this functionObject.
virtual bool read(const dictionary &dict)
Read and set the function object if its data have changed.
static int debug
Flag to execute debug content.
virtual const word & type() const =0
Runtime type information.
functionObject(const word &name, const bool withNamePrefix=defaultUseNamePrefix)
Construct from components.
Copies content of local objectRegistry to all processors.
void sync()
Do all: synchronise all IOFields and objectRegistry.
virtual bool execute()
Execute the function-object operations (no-op).
virtual bool write()
Write the function-object results.
virtual bool read(const dictionary &)
Read the function-object dictionary.
static FOAM_NO_DANGLING_REFERENCE const objectRegistry & subRegistry(const objectRegistry &obr, const wordList &names, const label index)
Lookup (sub)objectRegistry by following names of sub registries. Creates non-existing intermediate on...
static void readDict(const dictionary &d, objectRegistry &obr)
(recursively) construct and register IOFields from dictionary
static fileName sendPath(const fileName &root, const label proci)
Helper: return path to store data to be sent to processor i.
static fileName receivePath(const fileName &root, const label proci)
Helper: return path to store data to be received from processor i.
static void writeDict(const objectRegistry &obr, dictionary &dict)
Convert objectRegistry contents into dictionary.
Registry of regIOobjects.
A class for handling words, derived from Foam::string.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
OBJstream os(runTime.globalPath()/outputName)
Namespace for handling debugging switches.
Function objects are OpenFOAM utilities to ease workflow configurations and enhance workflows.
fileName::Type type(const fileName &name, const bool followLink=true)
Return the file type: DIRECTORY or FILE, normally following symbolic links.
Ostream & endl(Ostream &os)
Add newline and flush stream.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for expressions::valueTypeCode::INVALID.
prefixOSstream Pout
OSstream wrapped stdout (std::cout) with parallel prefix.