21 std::ostringstream errStr;
22 errStr <<
"LevelID = " << requestedLevel.
GetLevelID();
31#ifdef HAVE_MUELU_DEBUG
33 TEUCHOS_TEST_FOR_EXCEPTION((multipleCallCheck_ == ENABLED) && (multipleCallCheckGlobal_ == ENABLED) && (lastLevelID_ == levelID),
35 this->
ShortClassName() <<
"::Build() called twice for the same level (levelID=" << levelID
36 <<
"). This is likely due to a configuration error, or calling hierarchy setup multiple times "
37 <<
"without resetting debug info through FactoryManager::ResetDebugData().");
38 if (multipleCallCheck_ == FIRSTCALL)
39 multipleCallCheck_ = ENABLED;
41 lastLevelID_ = levelID;
45 RCP<const Teuchos::Comm<int> > comm = requestedLevel.
GetComm();
51 if (!prevLevel.is_null())
52 comm = prevLevel->GetComm();
virtual std::string ShortClassName() const
Return the class name of the object, without template parameters and without namespace.
Exception throws to report data dependency problems between factories.
Exception throws to report errors in the internal logical of the program.
RCP< ParameterList > RemoveFactoriesFromList(const ParameterList &list) const
Class that holds all level-specific information.
RCP< Level > & GetPreviousLevel()
Previous level.
RCP< const Teuchos::Comm< int > > GetComm() const
int GetLevelID() const
Return level number.
virtual const Teuchos::ParameterList & GetParameterList() const
Integrates Teuchos::TimeMonitor with MueLu verbosity system.
virtual void CallDeclareInput(Level &requestedLevel) const
virtual void CallBuild(Level &requestedLevel) const
virtual void Build(Level &fineLevel, Level &coarseLevel) const =0
Build an object with this factory.
TwoLevelFactoryBase()
Constructor.
virtual void DeclareInput(Level &fineLevel, Level &coarseLevel) const =0
Input.
virtual ~TwoLevelFactoryBase()
Destructor.
Teuchos::FancyOStream & GetOStream(MsgType type, int thisProcRankOnly=0) const
Get an output stream for outputting the input message type.
int SetProcRankVerbose(int procRank) const
Set proc rank used for printing.
bool IsPrint(MsgType type, int thisProcRankOnly=-1) const
Find out whether we need to print out information for a specific message type.
Namespace for MueLu classes and methods.
@ Test0
Print factory calls.
@ Test1
Print used parameters.
std::string toString(const T &what)
Little helper function to convert non-string types to strings.