Ifpack_DynamicFactory. More...
#include <Ifpack_DynamicFactory.h>
Public Types | |
typedef Ifpack_Preconditioner *(* | builderFunction )(Epetra_RowMatrix *, int, bool, bool) |
Public Member Functions | |
Ifpack_Preconditioner * | Create (const std::string PrecType, Epetra_RowMatrix *Matrix, const int overlap=0, bool overrideSerialDefault=false) |
Creates an instance of Ifpack_Preconditioner given the std::string name of the preconditioner type (can fail with bad input). More... | |
Static Public Member Functions | |
static bool | Initialize () |
Initializes the static data of the Ifpac_DynamicFactory class. More... | |
static int | RegisterPreconditioner (const std::string PrecName, builderFunction PrecBuilder) |
Register a new preconditioner with the factory. More... | |
static void | Print (std::ostream &os=std::cout) |
Prints the current list of registered preconditioners. More... | |
template<typename PrecType , bool StandAlone> | |
static Ifpack_Preconditioner * | buildPreconditioner (Epetra_RowMatrix *Matrix, int Overlap, bool Serial, bool OverrideSerialDefault) |
Ifpack_Preconditioner * Ifpack_DynamicFactory::Create | ( | const std::string | PrecType, |
Epetra_RowMatrix * | Matrix, | ||
const int | overlap = 0 , |
||
bool | overrideSerialDefault = false |
||
) |
Creates an instance of Ifpack_Preconditioner given the std::string name of the preconditioner type (can fail with bad input).
PrecType | (In) - String name of preconditioner type to be created. |
Matrix | (In) - Matrix used to define the preconditioner |
overlap | (In) - specified overlap, defaulted to 0. |
Returns 0
if the preconditioner with that input name does not exist. Otherwise, return a newly created preconditioner object. Note that the client is responsible for calling delete
on the returned object once it is finished using it!
Definition at line 181 of file Ifpack_DynamicFactory.cpp.
References Epetra_Operator::Comm(), and Epetra_Comm::NumProc().
|
static |
Initializes the static data of the Ifpac_DynamicFactory class.
Returns true if initialization succeeded, otherwise false or FILE_NOT_FOUND
Definition at line 65 of file Ifpack_DynamicFactory.cpp.
|
static |
Prints the current list of registered preconditioners.
Definition at line 171 of file Ifpack_DynamicFactory.cpp.
|
static |
Register a new preconditioner with the factory.
PrecName | - String name of the new preconditioner |
PrecBuilder | - function pointer to the builder function |
Returns 0
if ok, otherwise 1
Definition at line 159 of file Ifpack_DynamicFactory.cpp.