WARPXM v1.10.0
Loading...
Searching...
No Matches
WmSubSolver Class Referenceabstract

Base class for sub-solvers in WARPXM compute kernel system. More...

#include <wmsubsolver.h>

Inheritance diagram for WmSubSolver:
WxObject

Detailed Description

Base class for sub-solvers in WARPXM compute kernel system.

A subsolver is an object which encodes algorithms to transform input variables into output variables. It is like a subroutine in a programming langauge.

Public Types

typedef std::vector< std::string > subsolver_crypt_args_t
 Arguments to subsolver calls that appear in the crypt set sequence E.g.
 

Public Member Functions

virtual ~WmSubSolver ()
 Destroy subsolver.
 
virtual void setup (const WxCryptSet &wxc)
 Setup subsolver object using supplied cryptset.
 
const WmSolverBasegetParent () const
 Get parent solver object.
 
wxm::variable::variable_tgetVariableByName (const std::string &variableName) const
 Retrieves a variable registered with the parent solver that matches the specified name.
 
const WmDomaingetDomain () const
 Get the domain for the system.
 
- Public Member Functions inherited from WxObject
virtual ~WxObject ()
 Dtor: destroy object.
 
void setIo (WxIoBase &io)
 Set the I/O pointer for use in object.
 
void setMsg (WxMsgBase &msg)
 Set the msg pointer for use in object.
 
WxIoBasegetIo ()
 Return reference to I/O object.
 
const WxIoBasegetIo () const
 Return constant reference to I/O object.
 
WxMsgBasegetMsg ()
 Return reference to msg object.
 
const WxMsgBasegetMsg () const
 Return const reference to msg object.
 
virtual void setup (const WxCryptSet &wxc)
 Setup object using supplied crypset.
 
virtual void init ()
 Initialize the object.
 
virtual void finishBuild ()
 Finish building the object.
 
virtual void load (WxIoBase &io, const WxIoNodeType &grpNode)
 Load object from file.
 
virtual void dump (WxIoBase &io, WxIoNodeType &grpNode) const
 Dump object to file.
 
virtual std::string name () const
 Get name of object.
 
void setName (const std::string &nm)
 Set object's name.
 

Protected Member Functions

 WmSubSolver (const WmConstOpaquePtr &parent_solver)
 Create new subsolver.
 
virtual void typeCheck ()=0
 Check that the provided variables meet the expected variable types for this subsolver.
 
- Protected Member Functions inherited from WxObject
 WxObject ()
 Create object, that will be initialized subsequently.
 
 WxObject (const std::string &name)
 Create object with given name bypassing object setup phase Protected because there is no reason to have a WxObject directly, as it is meant to be a parent class.
 

Member Typedef Documentation

◆ subsolver_crypt_args_t

typedef std::vector<std::string> WmSubSolver::subsolver_crypt_args_t

Arguments to subsolver calls that appear in the crypt set sequence E.g.

subsolver_name(argument)

Constructor & Destructor Documentation

◆ ~WmSubSolver()

virtual WmSubSolver::~WmSubSolver ( )
virtual

Destroy subsolver.

◆ WmSubSolver()

WmSubSolver::WmSubSolver ( const WmConstOpaquePtr parent_solver)
protected

Create new subsolver.

Parameters
parent_solvertype opaque wrapper to parent solver

Member Function Documentation

◆ getDomain()

const WmDomain & WmSubSolver::getDomain ( ) const

Get the domain for the system.

Returns
Reference to domain object

◆ getParent()

const WmSolverBase & WmSubSolver::getParent ( ) const

Get parent solver object.

Returns
reference to parent

◆ getVariableByName()

wxm::variable::variable_t & WmSubSolver::getVariableByName ( const std::string &  variableName) const

Retrieves a variable registered with the parent solver that matches the specified name.

Parameters
variableNameuniquely identifies existing registered WmVariable instance
Returns
reference to variable matching supplied name

◆ setup()

virtual void WmSubSolver::setup ( const WxCryptSet wxc)
virtual

Setup subsolver object using supplied cryptset.

Parameters
wxcCryptset to use for setting

Reimplemented from WxObject.

◆ typeCheck()

virtual void WmSubSolver::typeCheck ( )
protectedpure virtual

Check that the provided variables meet the expected variable types for this subsolver.

This is a pure virtual function to ensure that derived sub solvers implement it.


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