@@ -57,7 +57,7 @@ std::ostream& operator<<(std::ostream& out, CollateralExposureHelper::Calculatio
5757 return out;
5858}
5959
60- Real CollateralExposureHelper::marginRequirementCalc (const boost ::shared_ptr<CollateralAccount>& collat,
60+ Real CollateralExposureHelper::marginRequirementCalc (const QuantLib::ext ::shared_ptr<CollateralAccount>& collat,
6161 const Real& uncollatValue, const Date& simulationDate) {
6262 // first step, make sure collateral balance is up to date.
6363 // collat->updateAccountBalance(simulationDate);
@@ -80,7 +80,7 @@ Real CollateralExposureHelper::marginRequirementCalc(const boost::shared_ptr<Col
8080}
8181
8282 Real CollateralExposureHelper::creditSupportAmount (
83- const boost ::shared_ptr<ore::data::NettingSetDefinition>& nettingSet,
83+ const QuantLib::ext ::shared_ptr<ore::data::NettingSetDefinition>& nettingSet,
8484 const Real& uncollatValueCsaCur) {
8585
8686 Real ia = nettingSet->csaDetails ()->independentAmountHeld ();
@@ -152,7 +152,7 @@ Real CollateralExposureHelper::estimateUncollatValue(const Date& simulationDate,
152152 return newPv;
153153}
154154
155- void CollateralExposureHelper::updateMarginCall (const boost ::shared_ptr<CollateralAccount>& collat,
155+ void CollateralExposureHelper::updateMarginCall (const QuantLib::ext ::shared_ptr<CollateralAccount>& collat,
156156 const Real& uncollatValue, const Date& simulationDate,
157157 const Real& annualisedZeroRate, const CalculationType& calcType,
158158 const bool & eligMarginReqDateUs, const bool & eligMarginReqDateCtp) {
@@ -186,12 +186,12 @@ void CollateralExposureHelper::updateMarginCall(const boost::shared_ptr<Collater
186186 }
187187}
188188
189- boost:: shared_ptr<vector<boost ::shared_ptr<CollateralAccount>>> CollateralExposureHelper::collateralBalancePaths (
190- const boost ::shared_ptr<NettingSetDefinition>& csaDef, const Real& nettingSetPv, const Date& date_t0,
189+ QuantLib::ext:: shared_ptr<vector<QuantLib::ext ::shared_ptr<CollateralAccount>>> CollateralExposureHelper::collateralBalancePaths (
190+ const QuantLib::ext ::shared_ptr<NettingSetDefinition>& csaDef, const Real& nettingSetPv, const Date& date_t0,
191191 const vector<vector<Real>>& nettingSetValues, const Date& nettingSet_maturity, const vector<Date>& dateGrid,
192192 const Real& csaFxTodayRate, const vector<vector<Real>>& csaFxScenarioRates, const Real& csaTodayCollatCurve,
193193 const vector<vector<Real>>& csaScenCollatCurves, const CalculationType& calcType,
194- const boost ::shared_ptr<CollateralBalance>& balance) {
194+ const QuantLib::ext ::shared_ptr<CollateralBalance>& balance) {
195195
196196 try {
197197 // step 1; build a collateral account object, assuming t0 VM balance from the balance object (zero balance if missing),
@@ -206,7 +206,7 @@ boost::shared_ptr<vector<boost::shared_ptr<CollateralAccount>>> CollateralExposu
206206 DLOG (" initial collateral balance not found" );
207207 }
208208
209- boost ::shared_ptr<CollateralAccount> tmpAcc (new CollateralAccount (csaDef, initialBalance, date_t0));
209+ QuantLib::ext ::shared_ptr<CollateralAccount> tmpAcc (new CollateralAccount (csaDef, initialBalance, date_t0));
210210 DLOG (" tmp initial collateral balance: " << tmpAcc->balance_t0 ());
211211 DLOG (" tmp current collateral balance: " << tmpAcc->accountBalance ());
212212
@@ -218,15 +218,15 @@ boost::shared_ptr<vector<boost::shared_ptr<CollateralAccount>>> CollateralExposu
218218 DLOG (" base current collateral balance: " << bal_t0 << " , " << baseAcc.accountBalance ());
219219
220220 // step 3; build an empty container for the return value(s)
221- boost:: shared_ptr<vector<boost ::shared_ptr<CollateralAccount>>> scenarioCollatPaths (
222- new vector<boost ::shared_ptr<CollateralAccount>>());
221+ QuantLib::ext:: shared_ptr<vector<QuantLib::ext ::shared_ptr<CollateralAccount>>> scenarioCollatPaths (
222+ new vector<QuantLib::ext ::shared_ptr<CollateralAccount>>());
223223
224224 // step 4; start loop over scenarios
225225 Size numScenarios = nettingSetValues.front ().size ();
226226 QL_REQUIRE (numScenarios == csaFxScenarioRates.front ().size (), " netting values -v- scenario FX rate mismatch" );
227227 Date simEndDate = std::min (nettingSet_maturity, dateGrid.back ()) + csaDef->csaDetails ()->marginPeriodOfRisk ();
228228 for (unsigned i = 0 ; i < numScenarios; i++) {
229- boost ::shared_ptr<CollateralAccount> collat (new CollateralAccount (baseAcc));
229+ QuantLib::ext ::shared_ptr<CollateralAccount> collat (new CollateralAccount (baseAcc));
230230 Date tmpDate = date_t0; // the date which gets evolved
231231 Date nextMarginReqDateUs = date_t0;
232232 Date nextMarginReqDateCtp = date_t0;
0 commit comments