diff --git a/src/OpenFOAM/db/functionObjects/writeFile/writeFile.C b/src/OpenFOAM/db/functionObjects/writeFile/writeFile.C index 3d7b6d707a3d4e80189d7588f12450435a635ef1..02a7261bfa5ea65e11c021b1ac6698e7f216e397 100644 --- a/src/OpenFOAM/db/functionObjects/writeFile/writeFile.C +++ b/src/OpenFOAM/db/functionObjects/writeFile/writeFile.C @@ -182,7 +182,7 @@ Foam::functionObjects::writeFile::~writeFile() // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // -void Foam::functionObjects::writeFile::read(const dictionary& dict) +bool Foam::functionObjects::writeFile::read(const dictionary& dict) { writePrecision_ = dict.lookupOrDefault("writePrecision", IOstream::defaultPrecision()); @@ -190,6 +190,8 @@ void Foam::functionObjects::writeFile::read(const dictionary& dict) // Only write on master process writeToFile_ = dict.lookupOrDefault("writeToFile", true); writeToFile_ = writeToFile_ && Pstream::master(); + + return true; } diff --git a/src/OpenFOAM/db/functionObjects/writeFile/writeFile.H b/src/OpenFOAM/db/functionObjects/writeFile/writeFile.H index 269504d9c9f121810db62d81a8cf8ed81f576f97..c05a1ffe4de3cb0ee3e22552de5a2b8f58fd3ab5 100644 --- a/src/OpenFOAM/db/functionObjects/writeFile/writeFile.H +++ b/src/OpenFOAM/db/functionObjects/writeFile/writeFile.H @@ -148,28 +148,28 @@ public: // Member Functions //- Read - void read(const dictionary& dict); + virtual bool read(const dictionary& dict); //- Return access to the file (if only 1) - OFstream& file(); + virtual OFstream& file(); //- Flag to allow writing to file - bool writeToFile() const; + virtual bool writeToFile() const; //- Return width of character stream output - label charWidth() const; + virtual label charWidth() const; //- Write a commented string to stream - void writeCommented(Ostream& os, const string& str) const; + virtual void writeCommented(Ostream& os, const string& str) const; //- Write a tabbed string to stream - void writeTabbed(Ostream& os, const string& str) const; + virtual void writeTabbed(Ostream& os, const string& str) const; //- Write a commented header to stream - void writeHeader(Ostream& os, const string& str) const; + virtual void writeHeader(Ostream& os, const string& str) const; //- Write the current time to stream - void writeTime(Ostream& os) const; + virtual void writeTime(Ostream& os) const; //- Write a (commented) header property and value pair template<class Type>