PISM, A Parallel Ice Sheet Model stable 0.4.1779
Public Member Functions | Protected Member Functions | Protected Attributes

PCFactory< Model, Modifier > Class Template Reference

#include <PCFactory.hh>

List of all members.

Public Member Functions

 PCFactory (IceGrid &g, const NCConfigVariable &conf)
virtual ~PCFactory ()
virtual PetscErrorCode set_default (string name)
 Sets the default type name.
virtual PetscErrorCode create (Model *&result)
 Creates a boundary model. Processes command-line options.
virtual void add_model (string name, void(*func)(IceGrid &, const NCConfigVariable &, Model *&))
 Adds a boundary model to the dictionary.
virtual void add_modifier (string name, void(*func)(IceGrid &, const NCConfigVariable &, Model *, Modifier *&))
virtual void remove_model (string name)
 Removes a boundary model from the dictionary.
virtual void remove_modifier (string name)
virtual void clear_models ()
 Clears the dictionary.
virtual void clear_modifiers ()

Protected Member Functions

virtual void add_standard_types ()

Protected Attributes

string default_type
string option
map< string, void(*)(IceGrid
&, const NCConfigVariable
&, Model *&)> 
models
map< string, void(*)(IceGrid
&, const NCConfigVariable
&, Model *, Modifier *&)> 
modifiers
IceGrid & grid
const NCConfigVariable & config

Detailed Description

template<class Model, class Modifier>
class PCFactory< Model, Modifier >

Definition at line 30 of file PCFactory.hh.


Constructor & Destructor Documentation

PCFactory ( IceGrid &  g,
const NCConfigVariable &  conf 
) [inline]

Definition at line 32 of file PCFactory.hh.

virtual ~PCFactory ( ) [inline, virtual]

Definition at line 34 of file PCFactory.hh.


Member Function Documentation

virtual void add_model ( string  name,
void(*)(IceGrid &, const NCConfigVariable &, Model *&)  func 
) [inline, virtual]

Adds a boundary model to the dictionary.

Definition at line 133 of file PCFactory.hh.

Referenced by main().

virtual void add_modifier ( string  name,
void(*)(IceGrid &, const NCConfigVariable &, Model *, Modifier *&)  func 
) [inline, virtual]

Definition at line 137 of file PCFactory.hh.

virtual void add_standard_types ( ) [inline, protected, virtual]

Reimplemented in PAFactory, PSFactory, and POFactory.

Definition at line 159 of file PCFactory.hh.

virtual void clear_models ( ) [inline, virtual]

Clears the dictionary.

Definition at line 151 of file PCFactory.hh.

virtual void clear_modifiers ( ) [inline, virtual]

Definition at line 155 of file PCFactory.hh.

virtual PetscErrorCode create ( Model *&  result) [inline, virtual]

Creates a boundary model. Processes command-line options.

Definition at line 50 of file PCFactory.hh.

Referenced by main().

virtual void remove_model ( string  name) [inline, virtual]

Removes a boundary model from the dictionary.

Definition at line 142 of file PCFactory.hh.

virtual void remove_modifier ( string  name) [inline, virtual]

Definition at line 146 of file PCFactory.hh.

virtual PetscErrorCode set_default ( string  name) [inline, virtual]

Sets the default type name.

Definition at line 37 of file PCFactory.hh.

Referenced by main().


Member Data Documentation

const NCConfigVariable& config [protected]

Definition at line 164 of file PCFactory.hh.

Referenced by PCFactory< PISMOceanModel, POModifier >::create().

string default_type [protected]
IceGrid& grid [protected]

Definition at line 163 of file PCFactory.hh.

Referenced by PCFactory< PISMOceanModel, POModifier >::create().

map<string,void(*)(IceGrid&, const NCConfigVariable&, Model*&)> models [protected]
map<string,void(*)(IceGrid&, const NCConfigVariable&, Model*, Modifier*&)> modifiers [protected]
string option [protected]

Definition at line 160 of file PCFactory.hh.

Referenced by PCFactory< PISMOceanModel, POModifier >::create().


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines