GridFire v0.7.1_rc2 General Purpose Nuclear Network

Loading...
Searching...
No Matches
Public Member Functions | List of all members
gridfire::solver::SolverContextBase Struct Referenceabstract

Base class for solver callback contexts. More...

`#include <strategy_abstract.h>`

Inheritance diagram for gridfire::solver::SolverContextBase:
[legend]

## Public Member Functions
virtual | ~SolverContextBase ()=default
virtual std::vector< std::tuple< std::string, std::string > > | describe () const =0
| Describe the context for callback functions.

## Detailed Description

Base class for solver callback contexts.

This struct serves as a base class for contexts that can be passed to solver callbacks, it enforces that derived classes implement a `describe` method that returns a vector of tuples describing the context that a callback will receive when called.

## Constructor & Destructor Documentation

## ◆ ~SolverContextBase()

virtual gridfire::solver::SolverContextBase::~SolverContextBase | ( |  | ) |
| virtual default

## Member Function Documentation

## ◆ describe()

virtual std::vector< std::tuple< std::string, std::string > > gridfire::solver::SolverContextBase::describe | ( |  | ) | const
| pure virtual

Describe the context for callback functions.

Returns
  A vector of tuples, each containing a string for the parameters name and a string for its type.

This method should be overridden by derived classes to provide a description of the context that will be passed to the callback function. The intent of this method is that an end user can investigate the context that will be passed to the callback function, and use this information to craft their own callback function.

Implemented in gridfire::solver::CVODESolverStrategy::TimestepContext, and PySolverContextBase.

The documentation for this struct was generated from the following file:

- src/include/gridfire/solver/strategies/strategy_abstract.h