Go to the documentation of this file.
58 static bool hasReadWriteTypes(
const word& readType,
const word& writeType)
60 volatile bool good =
true;
78 int main(
int argc,
char *argv[])
82 "Convert between edgeMesh formats"
91 "The input format (default: use file extension)"
97 "The output format (default: use file extension)"
103 "Input geometry scaling factor"
113 if (importName == exportName)
116 <<
"Output file would overwrite input file."
120 const word readFileType
125 const word writeFileType
131 if (!hasReadWriteTypes(readFileType, writeFileType))
134 <<
"Unsupported file format(s)" <<
nl
140 Info<<
"\nRead edgeMesh " << importName <<
nl;
143 <<
"\nwriting " << exportName;
145 scalar scaleFactor(0);
148 Info<<
" with scaling " << scaleFactor <<
endl;
149 mesh.scalePoints(scaleFactor);
word lessExt() const
Return word without extension (part before last .)
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
A class for handling words, derived from Foam::string.
static bool canReadType(const word &fileType, bool verbose=false)
Can we read this file format?
A class for handling file names.
virtual bool write(const bool valid=true) const
Write mesh using IO settings from time.
T getOrDefault(const word &optName, const T &deflt) const
Get a value from the named option if present, or return default.
static void addNote(const string ¬e)
Add extra notes for the usage information.
Extract command arguments and options from the supplied argc and argv parameters.
Ostream & endl(Ostream &os)
Add newline and flush stream.
word ext() const
Return file name extension (part after last .)
bool readIfPresent(const word &optName, T &val) const
Read a value from the named option if present.
const fileName & rootPath() const
Return root path.
static void addArgument(const string &argName, const string &usage="")
Append a (mandatory) argument to validArgs.
messageStream Info
Information stream (uses stdout - output is on the master only)
word name(const complex &c)
Return string representation of complex.
errorManipArg< error, int > exit(error &err, const int errNo=1)
static bool canWriteType(const word &fileType, bool verbose=false)
Can we write this file format type?
const fileName & caseName() const
Return case name (parallel run) or global case (serial run)
static void noParallel()
Remove the parallel options.
static void addOption(const word &optName, const string ¶m="", const string &usage="", bool advanced=false)
Add an option to validOptions with usage information.
Foam::argList args(argc, argv)
Mesh data needed to do the Finite Area discretisation.