IFPACK  Development
 All Classes Namespaces Files Functions Variables Enumerations Friends Pages
Public Types | Public Member Functions | Static Public Member Functions | List of all members
Ifpack_DynamicFactory Class Reference

Ifpack_DynamicFactory. More...

#include <Ifpack_DynamicFactory.h>

Public Types

typedef Ifpack_Preconditioner *(* builderFunction )(Epetra_RowMatrix *, int, bool, bool)
 

Public Member Functions

Ifpack_PreconditionerCreate (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_PreconditionerbuildPreconditioner (Epetra_RowMatrix *Matrix, int Overlap, bool Serial, bool OverrideSerialDefault)
 

Detailed Description

Ifpack_DynamicFactory.

TODO: write class description

Author
Radu Popescu radu..nosp@m.pope.nosp@m.scu@e.nosp@m.pfl..nosp@m.ch
Date
2013-05-02

Definition at line 63 of file Ifpack_DynamicFactory.h.

Member Function Documentation

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).

Parameters
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().

bool Ifpack_DynamicFactory::Initialize ( )
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.

void Ifpack_DynamicFactory::Print ( std::ostream &  os = std::cout)
static

Prints the current list of registered preconditioners.

Definition at line 171 of file Ifpack_DynamicFactory.cpp.

int Ifpack_DynamicFactory::RegisterPreconditioner ( const std::string  PrecName,
Ifpack_DynamicFactory::builderFunction  PrecBuilder 
)
static

Register a new preconditioner with the factory.

Parameters
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.


The documentation for this class was generated from the following files: