26#include <ql/time/date.hpp>
55 virtual bool has(
const CrifRecord::RiskType& riskType,
const std::string& qualifier, boost::optional<bool> fallback = boost::none)
const = 0;
63 const std::string&
bucket,
const std::string& validFrom =
"",
const std::string& validTo =
"",
bool fallback =
false) = 0;
68 for (
const auto& cr : crif) {
69 if (!cr.isSimmParameter() &&
hasBuckets(cr.riskType)) {
70 addMapping(cr.riskType, cr.qualifier, cr.bucket);
void updateFromCrif(const ore::analytics::Crif &crif)
virtual const std::set< FailedMapping > & failedMappings() const =0
virtual bool hasBuckets(const CrifRecord::RiskType &riskType) const =0
Check if the given SIMM RiskType has a bucket structure.
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 std::string bucket(const CrifRecord::RiskType &riskType, const std::string &qualifier) const =0
virtual bool has(const CrifRecord::RiskType &riskType, const std::string &qualifier, boost::optional< bool > fallback=boost::none) const =0
Check if the given riskType and qualifier has a mapping (which is valid, and matches the fallback fla...
virtual ~SimmBucketMapper()
Destructor.
Struct for holding CRIF records.
bool operator<(const Dividend &d1, const Dividend &d2)
CrifRecord::RiskType riskType
CrifRecord::RiskType lookupRiskType