71#ifndef Foam_vtk_vtmWriter_H
72#define Foam_vtk_vtmWriter_H
116 vtmEntry(
const vtmEntry&) =
default;
117 vtmEntry(vtmEntry&&) =
default;
118 vtmEntry& operator=(
const vtmEntry&) =
default;
119 vtmEntry& operator=(vtmEntry&&) =
default;
128 vtmEntry(
int what,
const string&
name,
const fileName& file)
130 type_(what), name_(
name), file_(file)
136 static vtmEntry
block(
const string&
name)
138 return vtmEntry(BEGIN_BLOCK,
name,
"");
141 static vtmEntry endblock()
143 return vtmEntry(END_BLOCK,
"",
"");
148 return vtmEntry(DATA,
"", file);
153 return vtmEntry(DATA,
name, file);
160 bool isType(Type what)
const noexcept
162 return type_ == what;
169 bool good()
const noexcept;
200 bool pruneEmptyBlocks();
203 bool collapseBlocks();
239 void setTime(scalar timeValue);
296 void repair(
bool collapse=
false);
306 const word& blockName,
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Creates a single block of cells from point coordinates, numbers of cells in each direction and an exp...
A keyword and a list of tokens is an 'entry'.
A class for handling file names.
Provides a means of accumulating file entries for generating a vtkMultiBlockDataSet (....
vtmWriter()
Default construct, with autoName on.
bool append(const fileName &file)
Add a file. The name is either empty or created with autoName.
void repair(bool collapse=false)
Sanity fixes on the data.
void dump(Ostream &os) const
Print debug view of block and dataset contents.
static word ext()
File extension (always "vtm")
label endBlock(const word &blockName=word::null)
End the previous block, optionally with name checking.
label size() const
The number of data sets.
~vtmWriter()=default
Destructor.
bool empty() const
If there are no data sets.
void setTime(scalar timeValue)
Define "TimeValue" for FieldData (name as per Catalyst output)
void add(const word &blockName, const vtmWriter &other)
void clear()
Clear all entries and reset output.
bool append_vtp(const fileName &file)
Add a (.vtp) file.
label beginBlock(const word &blockName=word::null)
Start a new block, optionally with a name.
bool append_vtu(const fileName &file)
Add a (.vtu) file.
A class for handling words, derived from Foam::string.
OBJstream os(runTime.globalPath()/outputName)
fileTag
Some common XML tags for vtk files.
bool isType(const Type &t)
Check is typeid is identical to the TargetType.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
word format(conversionProperties.get< word >("format"))