Skip to content
Snippets Groups Projects
Commit 3d396738 authored by Carsten Gräser's avatar Carsten Gräser
Browse files

Extend ISTLMatrixBackend

* Provide const and mutable access to wrapped matrix.
* Provide `assign(v)` method to assign value to wrapped matrix.
parent be3fc665
No related branches found
No related tags found
1 merge request!100[bugfix] Zero-initialize matrix before assembling entries
......@@ -311,6 +311,31 @@ public:
return i(*matrix_);
}
/**
* \brief Const access to wrapped matrix
*/
const Matrix& matrix() const
{
return *matrix_;
}
/**
* \brief Mutable access to wrapped matrix
*/
Matrix& matrix()
{
return *matrix_;
}
/**
* \brief Assign value to wrapped matrix
*/
template<class Value>
void assign(const Value& value)
{
matrix() = value;
}
protected:
Matrix* matrix_;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment