Go to the documentation of this file.
92 #ifndef externalFileCoupler_H
93 #define externalFileCoupler_H
137 unsigned waitInterval_;
virtual void writeDataSlave() const
Write data files from slave (external program)
A class for handling words, derived from Foam::string.
virtual void removeDataMaster() const
Remove data files written by master (OpenFOAM)
A class for handling file names.
bool slaveFirst() const
External application provides initial values.
virtual void writeDataMaster() const
Write data files from master (OpenFOAM)
const fileName & commDirectory() const
Return the file path to the base communications directory.
enum Time::stopAtControls useMaster(const bool wait=false) const
Create lock file to indicate that OpenFOAM is in charge.
enum Time::stopAtControls waitForMaster() const
Wait for master to complete.
bool initialized() const
True if state has been initialized.
virtual void readDataMaster()
Read data files on master (OpenFOAM).
runState
The run state (ie, who is currently in charge)
TypeName("externalFileCoupler")
Runtime type information.
virtual void removeDataSlave() const
Remove data files written by slave (external program)
virtual ~externalFileCoupler()
Destructor.
virtual void readDataSlave()
Read data files on slave (external program).
static word lockName
Name of the lock file.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
fileName resolveFile(const word &file) const
Return the file path in the communications directory.
enum Time::stopAtControls useSlave(const bool wait=false) const
Remove lock file to indicate that the external program is in charge.
Encapsulates the logic for coordinating between OpenFOAM and an external application.
void removeDirectory() const
Remove files written by OpenFOAM.
enum Time::stopAtControls waitForSlave() const
Wait for slave to complete.
void shutdown() const
Generate status=done in lock (only when run-state = master)
bool readDict(const dictionary &dict)
Read communication settings from dictionary.
The slave (external program) is in charge.
externalFileCoupler()
Construct using standard defaults.
fileName lockFile() const
Return the file path to the lock file.
The master (OpenFOAM) is in charge.