Logo
Reference manual - version orea_version
Public Types | Public Member Functions | Protected Attributes | List of all members
PNLCalculator Class Reference
+ Inheritance diagram for PNLCalculator:

Public Types

using TradePnLStore = std::vector< std::vector< QuantLib::Real > >
 

Public Member Functions

 PNLCalculator (ore::data::TimePeriod pnlPeriod)
 
virtual void writePNL (QuantLib::Size scenarioIdx, bool isCall, const RiskFactorKey &key_1, QuantLib::Real shift_1, QuantLib::Real delta, QuantLib::Real gamma, QuantLib::Real deltaPnl, Real gammaPnl, const RiskFactorKey &key_2=RiskFactorKey(), QuantLib::Real shift_2=0.0, const std::string &tradeId="")
 
const bool isInTimePeriod (QuantLib::Date startDate, QuantLib::Date endDate)
 
void populatePNLs (const std::vector< QuantLib::Real > &allPnls, const std::vector< QuantLib::Real > &foPnls, const std::vector< QuantLib::Date > &startDates, const std::vector< QuantLib::Date > &endDates)
 
void populateTradePNLs (const TradePnLStore &allPnls, const TradePnLStore &foPnls)
 
const std::vector< QuantLib::Real > & pnls ()
 
const std::vector< QuantLib::Real > & foPnls ()
 
const TradePnLStore & tradePnls ()
 
const TradePnLStore & foTradePnls ()
 
void clear ()
 

Protected Attributes

std::vector< QuantLib::Real > pnls_
 
std::vector< QuantLib::Real > foPnls_
 
ore::data::TimePeriod pnlPeriod_
 
TradePnLStore tradePnls_
 
TradePnLStore foTradePnls_