Logo
Reference manual - version orea_version
SimmBucketMapper Class Referenceabstract
Inheritance diagram for SimmBucketMapper:

Classes

struct  FailedMapping

Public Member Functions

virtual ~SimmBucketMapper ()
 Destructor.
virtual std::string bucket (const CrifRecord::RiskType &riskType, const std::string &qualifier) const =0
virtual bool hasBuckets (const CrifRecord::RiskType &riskType) const =0
 Check if the given SIMM RiskType has a bucket structure.
virtual bool has (const CrifRecord::RiskType &riskType, const std::string &qualifier, QuantLib::ext::optional< bool > fallback=QuantLib::ext::nullopt) const =0
 Check if the given riskType and qualifier has a mapping (which is valid, and matches the fallback flag if given).
virtual void addMapping (const CrifRecord::RiskType &riskType, const std::string &qualifier, const std::string &bucket, const std::string &validFrom="", const std::string &validTo="", bool fallback=false)=0
 Add a single bucket mapping for qualifier with risk type riskType.
virtual const std::set< FailedMapping > & failedMappings () const =0
void updateFromCrif (const QuantLib::ext::shared_ptr< ore::analytics::Crif > &crif)

Member Function Documentation

◆ bucket()

virtual std::string bucket ( const CrifRecord::RiskType & riskType,
const std::string & qualifier ) const
pure virtual

Return the SIMM bucket for a given SIMM RiskType and SIMM Qualifier (using valid mappings only)

Warning
An error is thrown if there is no bucket for the combination.

Implemented in SimmBucketMapperBase.

◆ hasBuckets()

virtual bool hasBuckets ( const CrifRecord::RiskType & riskType) const
pure virtual

Check if the given SIMM RiskType has a bucket structure.

Implemented in SimmBucketMapperBase.

◆ has()

virtual bool has ( const CrifRecord::RiskType & riskType,
const std::string & qualifier,
QuantLib::ext::optional< bool > fallback = QuantLib::ext::nullopt ) const
pure virtual

Check if the given riskType and qualifier has a mapping (which is valid, and matches the fallback flag if given).

Implemented in SimmBucketMapperBase.

◆ addMapping()

virtual void addMapping ( const CrifRecord::RiskType & riskType,
const std::string & qualifier,
const std::string & bucket,
const std::string & validFrom = "",
const std::string & validTo = "",
bool fallback = false )
pure virtual

Add a single bucket mapping for qualifier with risk type riskType.

Implemented in SimmBucketMapperBase.