IFEM  90A354
Public Member Functions | Protected Attributes | List of all members
SettingMap Class Reference

A key-value store for settings. More...

#include <LinSolParams.h>

Inheritance diagram for SettingMap:
Inheritance graph
[legend]
Collaboration diagram for SettingMap:
Collaboration graph
[legend]

Public Member Functions

void addValue (const std::string &key, const std::string &value)
 Add a value to the store. More...
 
std::string getStringValue (const std::string &key) const
 Obtain a value as a string. More...
 
int getIntValue (const std::string &key) const
 Obtain a value as an integer. More...
 
double getDoubleValue (const std::string &key) const
 Obtain a value as an double. More...
 
bool hasValue (const std::string &key) const
 Checks if the store holds a value for a key. More...
 

Protected Attributes

std::map< std::string, std::string > values
 Map of key-value pairs.
 

Detailed Description

A key-value store for settings.

Member Function Documentation

◆ addValue()

void SettingMap::addValue ( const std::string &  key,
const std::string &  value 
)

Add a value to the store.

Parameters
[in]keyThe key
[in]valueThe value

References values.

Referenced by LinSolParams::BlockParams::BlockParams(), LinSolParams::LinSolParams(), LinSolParams::BlockParams::read(), and LinSolParams::read().

◆ getDoubleValue()

double SettingMap::getDoubleValue ( const std::string &  key) const

Obtain a value as an double.

Parameters
[in]keyThe key

References values.

Referenced by PETScSolParams::getDoubleValue(), PETScSchurPC::PETScSchurPC(), and setupWithPreType().

◆ getIntValue()

int SettingMap::getIntValue ( const std::string &  key) const

◆ getStringValue()

std::string SettingMap::getStringValue ( const std::string &  key) const

◆ hasValue()

bool SettingMap::hasValue ( const std::string &  key) const

Checks if the store holds a value for a key.

Parameters
[in]keyThe key

References values.

Referenced by condSetup(), ISTLMatrix::handleSolverReset(), PETScSolParams::hasValue(), LinSolParams::BlockParams::read(), setupAMG(), setupAMG2_full(), and PETScSolParams::setupPC().


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