Logo
Reference manual - version orea_version
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
OREApp Class Reference

Orchestrates the processes covered by ORE, data loading, analytics and reporting. More...

#include <orea/app/oreapp.hpp>

Public Member Functions

 OREApp (boost::shared_ptr< Parameters > params, bool console=false, const boost::filesystem::path &=boost::filesystem::path())
 Constructor that uses ORE parameters and input data from files.
 
 OREApp (const boost::shared_ptr< InputParameters > &inputs, const std::string &logFile, Size logLevel=31, bool console=false, const boost::filesystem::path &=boost::filesystem::path())
 Constructor that assumes we have already assembled input parameters via API.
 
virtual ~OREApp ()
 Destructor.
 
virtual void run ()
 Runs analytics and generates reports after using the first OREApp c'tor.
 
void run (const std::vector< std::string > &marketData, const std::vector< std::string > &fixingData)
 Runs analytics and generates reports after using the second OREApp c'tor.
 
boost::shared_ptr< InputParametersgetInputs ()
 
std::set< std::string > getAnalyticTypes ()
 
std::set< std::string > getSupportedAnalyticTypes ()
 
const boost::shared_ptr< Analytic > & getAnalytic (std::string type)
 
std::set< std::string > getReportNames ()
 
boost::shared_ptr< PlainInMemoryReportgetReport (std::string reportName)
 
std::set< std::string > getCubeNames ()
 
boost::shared_ptr< NPVCubegetCube (std::string cubeName)
 
std::set< std::string > getMarketCubeNames ()
 
boost::shared_ptr< AggregationScenarioDatagetMarketCube (std::string cubeName)
 
std::vector< std::string > getErrors ()
 
Real getRunTime ()
 time for executing run(...) in seconds
 
std::string version ()
 

Protected Member Functions

virtual void analytics ()
 
void buildInputParameters (boost::shared_ptr< InputParameters > inputs, const boost::shared_ptr< Parameters > &params)
 Populate InputParameters object from classic ORE key-value pairs in Parameters.
 
vector< string > getFileNames (const string &fileString, const string &path)
 
boost::shared_ptr< CSVLoaderbuildCsvLoader (const boost::shared_ptr< Parameters > &params)
 
void setupLog (const std::string &path, const std::string &file, QuantLib::Size mask, const boost::filesystem::path &logRootPath, const std::string &progressLogFile="", QuantLib::Size progressLogRotationSize=100 *1024 *1024, bool progressLogToConsole=false, const std::string &structuredLogFile="", QuantLib::Size structuredLogRotationSize=100 *1024 *1024)
 set up logging
 
void closeLog ()
 remove logs
 

Protected Attributes

boost::shared_ptr< Parametersparams_
 ORE Input parameters.
 
boost::shared_ptr< InputParametersinputs_
 
boost::shared_ptr< OutputParametersoutputs_
 
boost::shared_ptr< AnalyticsManageranalyticsManager_
 
boost::shared_ptr< FilteredBufferedLoggerGuardfbLogger_
 
boost::timer::cpu_timer runTimer_
 

Detailed Description

Orchestrates the processes covered by ORE, data loading, analytics and reporting.