22 int run_opal(
char *
arg[], std::string inputfile,
int restartStep,
25 std::string::size_type startExtension = inputfile.find_last_of(
'.');
31 std::string outputFileName = inputfile.substr(0,startExtension) +
".out";
32 std::ofstream output(outputFileName.c_str());
37 gmsg =
new Inform(
"OPAL ", output);
43 amrex::Initialize(comm);
57 throw new OpalException(
"run_opal",
"Could not open inputfile: " + inputfile);
69 if(is) parser->
run(is);
85 amrex::Finalize(
true);
static void deleteInstance()
The global OPAL structure.
int run_opal(char *arg[], std::string inputfile, int restartStep, int infoLevel, int warnLevel, MPI_Comm comm)
static void clearDictionary()
void setRestartRun(const bool &value=true)
set OPAL in restart mode
The base class for all OPAL exceptions.
void storeInputFn(const std::string &fn)
store opals input filename
The default parser for OPAL-9.
void setDestination(std::ostream &dest)
static OpalData * getInstance()
void configure()
Configure all commands.
virtual void run() const
Read current stream.
A stream of input tokens.
void setRestartFileName(std::string s)
store opals restart h5 format filename
static Communicate * Comm
T::PETE_Expr_t::PETE_Return_t min(const PETE_Expr< T > &expr, NDIndex< D > &loc)
void setRestartStep(int s)
store the location where to restart