46 os <<
"POINT_DATA" <<
' ' << count <<
nl;
54 os << dataName <<
' ' << count <<
nl;
55 os <<
"# " << axisName;
71 os <<
' ' << fieldName
77 os <<
' ' << fieldName;
89 const word& fieldName,
93 if (
coords_.size() != fieldPtrs.size())
96 <<
"Attempted to write field: " << fieldName
97 <<
" (" << fieldPtrs.size() <<
" entries) for "
103 for (
const auto& pts :
coords_)
115 Info<<
"Writing field " << fieldName;
116 Info<<
" to " << outputFile <<
endl;
131 os <<
"# " << fieldName <<
" ";
134 writeHeader<Type>(
os, fieldName);
Istream and Ostream manipulators taking arguments.
Functions used by OpenFOAM that are specific to POSIX compliant operating systems and need to be repl...
Generic templated field type.
Output to file stream, using an OSstream.
virtual int precision() const
Get precision of output field.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
A list of pointers to objects of type <T>, without allocation/deallocation management of the pointers...
bool wroteGeom_
Track if geometry has been written since the last open.
static void writeTable(Ostream &os, const coordSet &coords, const UList< Type > &values, const char *sep)
Write coordinates and values.
bool verbose_
Additional output verbosity.
UPtrList< const coordSet > coords_
Reference to coordinate set(s)
fileName getFieldPrefixedPath(const word &fieldName, const word &fileExt=word::null) const
Get field-prefixed output file name.
Holds list of sampling positions.
const word & axis() const
The sort axis name.
bool hasVectorAxis() const noexcept
True if axis specification is a vector.
A class for handling file names.
static std::string path(const std::string &str)
Return directory path name (part before last /)
A traits class, which is primarily used for primitives.
A class for handling words, derived from Foam::string.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
OBJstream os(runTime.globalPath()/outputName)
string upper(const std::string &s)
Return string copy transformed with std::toupper on each character.
bool mkDir(const fileName &pathName, mode_t mode=0777)
Make a directory and return an error if it could not be created.
static void writeHeader(Ostream &os, const word &fieldName)
messageStream Info
Information stream (stdout output on master, null elsewhere)
Ostream & endl(Ostream &os)
Add newline and flush stream.
errorManipArg< error, int > exit(error &err, const int errNo=1)
static void writeCoordHeader(Ostream &os, const coordSet &coords, const label count)
bool isDir(const fileName &name, const bool followLink=true)
Does the name exist as a DIRECTORY in the file system?
constexpr char nl
The newline '\n' character (0x0a)
#define forAll(list, i)
Loop across all elements in list.