Hyperiso 1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
Loading...
Searching...
No Matches
IDependency Class Referenceabstract

Interface for managing dependencies between parameter blocks or parameters. More...

#include <IDependency.h>

Inheritance diagram for IDependency:

Public Member Functions

virtual ~IDependency ()=default
 Virtual destructor for proper polymorphic cleanup.
 
virtual void add_block_dependency (const BlockName &name, const std::unordered_map< ParameterType, std::vector< std::string > > &source_names, ParameterType dest, DepUpdateFunc recalculateFunc)=0
 Adds a dependent block.
 
virtual void add_param_dependency (const ParamId &pid, const std::unordered_set< ParamId > &source_pids, DepParamUpdateFunc recalculateFunc)=0
 Adds a dependent parameter.
 
virtual void remove_dependency (const BlockName &name, ParameterType src)=0
 Removes a dependency by name and parameter type.
 
virtual void update_dependency (const BlockName &name, ParameterType src)=0
 Updates a dependency by name and parameter type.
 

Detailed Description

Interface for managing dependencies between parameter blocks or parameters.

Provides an abstraction layer for adding, removing, and updating dependencies. Typical implementations (such as CompositeParamAdapter) internally rely on DependentBlock and DependentParameter, and orchestrate them via helper managers (e.g. DependentBlockManager).

Definition at line 43 of file IDependency.h.

Constructor & Destructor Documentation

◆ ~IDependency()

virtual IDependency::~IDependency ( )
virtualdefault

Virtual destructor for proper polymorphic cleanup.

Member Function Documentation

◆ add_block_dependency()

virtual void IDependency::add_block_dependency ( const BlockName name,
const std::unordered_map< ParameterType, std::vector< std::string > > &  source_names,
ParameterType  dest,
DepUpdateFunc  recalculateFunc 
)
pure virtual

Adds a dependent block.

Creates a new logical block whose contents are derived from other blocks.

Parameters
nameName of the dependent block.
source_namesMap of source blocks per parameter type.
destDestination parameter type where the new block will be stored.
recalculateFuncFunction used to recalculate the dependent block.

Implemented in CompositeParamAdapter.

◆ add_param_dependency()

virtual void IDependency::add_param_dependency ( const ParamId pid,
const std::unordered_set< ParamId > &  source_pids,
DepParamUpdateFunc  recalculateFunc 
)
pure virtual

Adds a dependent parameter.

Registers a new parameter whose value is computed from one or more source parameters.

Parameters
pidID of the new dependent parameter.
source_pidsSet of source parameter IDs the new parameter depends on.
recalculateFuncFunction used to recalculate the dependent parameter.

Implemented in CompositeParamAdapter.

◆ remove_dependency()

virtual void IDependency::remove_dependency ( const BlockName name,
ParameterType  src 
)
pure virtual

Removes a dependency by name and parameter type.

Usually targets a dependent block that should be removed (and unlinked from its sources/observers).

Parameters
nameName of the dependency block.
srcSource parameter type.

Implemented in CompositeParamAdapter.

◆ update_dependency()

virtual void IDependency::update_dependency ( const BlockName name,
ParameterType  src 
)
pure virtual

Updates a dependency by name and parameter type.

Typically forces a recomputation of a dependent block.

Parameters
nameName of the dependency block.
srcSource parameter type.

Implemented in CompositeParamAdapter.


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