26 #include "phaseModel.H" 33 const phaseSystem& fluid,
34 const word& phaseName,
38 word phaseModelType(fluid.subDict(phaseName).lookup(
"type"));
40 Info<<
"Selecting phaseModel for " 41 << phaseName <<
": " << phaseModelType <<
endl;
43 phaseSystemConstructorTable::iterator cstrIter =
44 phaseSystemConstructorTablePtr_->find(phaseModelType);
46 if (cstrIter == phaseSystemConstructorTablePtr_->end())
49 <<
"Unknown phaseModelType type " 50 << phaseModelType << endl << endl
51 <<
"Valid phaseModel types are : " << endl
52 << phaseSystemConstructorTablePtr_->sortedToc()
label index() const
Return the index of the phase.
static autoPtr< phaseModel > New(const phaseSystem &fluid, const word &phaseName, const label index)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
errorManipArg< error, int > exit(error &err, const int errNo=1)
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
Ostream & endl(Ostream &os)
Add newline and flush stream.
const phaseSystem & fluid() const
Return the system to which this phase belongs.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...