#include <ored/portfolio/nettingsetdefinition.hpp>
|
| CSA (const Type &type, const string &csaCurrency, const string &index, const Real &thresholdPay, const Real &thresholdRcv, const Real &mtaPay, const Real &mtaRcv, const Real &iaHeld, const string &iaType, const Period &marginCallFreq, const Period &marginPostFreq, const Period &mpr, const Real &collatSpreadPay, const Real &collatSpreadRcv, const vector< string > &eligCollatCcys, bool applyInitialMargin, Type initialMarginType, const bool calculateIMAmount, const bool calculateVMAmount, const string &nonExemptIMRegulations) |
|
const Type & | type () const |
| Inspectors. More...
|
|
const string & | csaCurrency () const |
|
const string & | index () const |
|
Real | thresholdPay () const |
|
Real | thresholdRcv () const |
|
Real | mtaPay () const |
|
Real | mtaRcv () const |
|
Real | independentAmountHeld () const |
|
const string & | independentAmountType () const |
|
const Period & | marginCallFrequency () const |
|
const Period & | marginPostFrequency () const |
|
const Period & | marginPeriodOfRisk () const |
|
Real | collatSpreadRcv () const |
|
Real | collatSpreadPay () const |
|
vector< string > | eligCollatCcys () const |
|
bool | applyInitialMargin () |
|
Type | initialMarginType () |
|
bool | calculateIMAmount () |
|
bool | calculateVMAmount () |
|
const string & | nonExemptIMRegulations () |
|
void | invertCSA () |
|
void | validate () |
|
Definition at line 38 of file nettingsetdefinition.hpp.
◆ Type
Enumeration 'Type' specifies what type of collateral agreement is in place.
- 'Bilateral' => both sides can request collateral margins
- 'PostOnly' => only the counterparty is allowed to issue a call for additional collateral
- 'CallOnly' => only WE are allowed to issue a margin call for additional collateral
Enumerator |
---|
Bilateral | |
CallOnly | |
PostOnly | |
Definition at line 47 of file nettingsetdefinition.hpp.
◆ CSA()
CSA |
( |
const Type & |
type, |
|
|
const string & |
csaCurrency, |
|
|
const string & |
index, |
|
|
const Real & |
thresholdPay, |
|
|
const Real & |
thresholdRcv, |
|
|
const Real & |
mtaPay, |
|
|
const Real & |
mtaRcv, |
|
|
const Real & |
iaHeld, |
|
|
const string & |
iaType, |
|
|
const Period & |
marginCallFreq, |
|
|
const Period & |
marginPostFreq, |
|
|
const Period & |
mpr, |
|
|
const Real & |
collatSpreadPay, |
|
|
const Real & |
collatSpreadRcv, |
|
|
const vector< string > & |
eligCollatCcys, |
|
|
bool |
applyInitialMargin, |
|
|
Type |
initialMarginType, |
|
|
const bool |
calculateIMAmount, |
|
|
const bool |
calculateVMAmount, |
|
|
const string & |
nonExemptIMRegulations |
|
) |
| |
Definition at line 49 of file nettingsetdefinition.hpp.
const Type & type() const
Inspectors.
Real thresholdPay() const
string nonExemptIMRegulations_
const string & csaCurrency() const
const string & index() const
bool applyInitialMargin()
Real collatSpreadPay() const
vector< string > eligCollatCcys() const
Real collatSpreadRcv() const
const string & nonExemptIMRegulations()
vector< string > eligCollatCcys_
Real thresholdRcv() const
◆ type()
const Type & type |
( |
| ) |
const |
◆ csaCurrency()
const string & csaCurrency |
( |
| ) |
const |
◆ index()
const string & index |
( |
| ) |
const |
◆ thresholdPay()
Real thresholdPay |
( |
| ) |
const |
◆ thresholdRcv()
Real thresholdRcv |
( |
| ) |
const |
◆ mtaPay()
◆ mtaRcv()
◆ independentAmountHeld()
Real independentAmountHeld |
( |
| ) |
const |
◆ independentAmountType()
const string & independentAmountType |
( |
| ) |
const |
◆ marginCallFrequency()
const Period & marginCallFrequency |
( |
| ) |
const |
Margining Frequency when requesting collateral from counterparty (e.g. "1D", "1W")
Definition at line 86 of file nettingsetdefinition.hpp.
◆ marginPostFrequency()
const Period & marginPostFrequency |
( |
| ) |
const |
Margining Frequency when counterparty is requesting collateral (e.g. "1D", "1W")
Definition at line 88 of file nettingsetdefinition.hpp.
◆ marginPeriodOfRisk()
const Period & marginPeriodOfRisk |
( |
| ) |
const |
◆ collatSpreadRcv()
Real collatSpreadRcv |
( |
| ) |
const |
◆ collatSpreadPay()
Real collatSpreadPay |
( |
| ) |
const |
◆ eligCollatCcys()
vector< string > eligCollatCcys |
( |
| ) |
const |
◆ applyInitialMargin()
bool applyInitialMargin |
( |
| ) |
|
◆ initialMarginType()
Type initialMarginType |
( |
| ) |
|
◆ calculateIMAmount()
bool calculateIMAmount |
( |
| ) |
|
◆ calculateVMAmount()
bool calculateVMAmount |
( |
| ) |
|
◆ nonExemptIMRegulations()
const string & nonExemptIMRegulations |
( |
| ) |
|
IM regulations (whose trade sensitivities are usually exempt from margin/sensi calc) that we wish to include (currently used only for SA-CCR)
Definition at line 108 of file nettingsetdefinition.hpp.
◆ invertCSA()
◆ validate()
Definition at line 68 of file nettingsetdefinition.cpp.
68 {
69 QL_REQUIRE(
csaCurrency_.size() == 3,
"NettingSetDefinition build error;"
70 << " CSA currency should be a three-letter ISO code");
71
72 QL_REQUIRE(
thresholdPay_ >= 0,
"NettingSetDefinition build error; negative thresholdPay");
73 QL_REQUIRE(
thresholdRcv_ >= 0,
"NettingSetDefinition build error; negative thresholdRcv");
74 QL_REQUIRE(
mtaPay_ >= 0,
"NettingSetDefinition build error; negative mtaPay");
75 QL_REQUIRE(
mtaRcv_ >= 0,
"NettingSetDefinition build error; negative mtaRcv");
76 QL_REQUIRE(
iaType_ ==
"FIXED",
"NettingSetDefinition build error;"
77 <<
" unsupported independent amount type; " <<
iaType_);
78
80 "NettingSetDefinition build error;"
81 << " non-positive margining frequency");
82 QL_REQUIRE(
mpr_ >= Period(0, Days),
"NettingSetDefinition build error;"
83 << " negative margin period of risk");
85 LOG(
"NettingSetDefinition has CSA margining frequency ("
87 }
88
91 "NettingSetDefinition build error;"
92 << "EligibleCollaterals currency should be a three-letter ISO code");
93 }
94
95
99 break;
100 }
103 }
104 default:
105 break;
106 }
107}
#define LOG(text)
Logging Macro (Level = Notice)
Size size(const ValueType &v)
◆ type_
◆ csaCurrency_
◆ index_
◆ thresholdPay_
◆ thresholdRcv_
◆ mtaPay_
◆ mtaRcv_
◆ iaHeld_
◆ iaType_
◆ marginCallFreq_
◆ marginPostFreq_
◆ mpr_
◆ collatSpreadPay_
◆ collatSpreadRcv_
◆ eligCollatCcys_
vector<string> eligCollatCcys_ |
|
private |
◆ applyInitialMargin_
◆ initialMarginType_
◆ calculateIMAmount_
◆ calculateVMAmount_
◆ nonExemptIMRegulations_
string nonExemptIMRegulations_ |
|
private |