Package com.opengamma.strata.report
Reporting Framework
This package and its sub-packages define a reporting framework used to format and report the results of calculations.Reports are generated using a report template and a set of calculation results. A report contains a table of data where the rows are the inputs to the calculations, for example trades, and the columns contain data from the calculation results or the trades.
Report templates
Report templates specify the type of the report and the columns included in the report. A report template is defined using an .ini file.The first section of the .ini file defines the settings for the report. Currently this only contains the type of the report:
[Settings] reportType = tradeThe report columns are defined by the remaining sections in the .ini file. The section header defines the column name and the
value
attribute is an expression defining the value in the column. The following
snippet from a trade report for FRA trades defines three columns: Settlement Date, Index and Par Rate.
[Settlement Date] value = Trade.settlementDate [Index] value = Product.index.name [Par Rate] value = Measures.ParRateThe
value
expression is consists of multiple sections separated by dots. The first section specifies
the object which is the source of the data in the column. The supported values are:
- Trade - the data is taken from the
trade
ortrade info
- Security - the data is taken from the
security
orsecurity info
- Position - the data is taken from the
position
orposition info
- Target - the data is taken from the
calculation target
- Measure - the data is taken from the results of the calculations
- Product - the data is taken from the
product
associated with the trade. This is only applicable if the trade implementsProductTrade
Product.index.name
' and the results contain
FraTrade
instances
the following calls will be made for each trade in the results:
The cell in the report will contain name of the index referenced by the FRA.-
Interface Summary Interface Description Report Represents a business report.ReportRunner<T extends ReportTemplate> Runs a report for a specific template type.ReportTemplate Marker interface for report templates.ReportTemplateIniLoader<T extends ReportTemplate> Loads a report template from an ini-based file format. -
Class Summary Class Description ReportCalculationResults Stores a set of engine calculation results along with the context required to run reports.ReportCalculationResults.Meta The meta-bean forReportCalculationResults
.ReportRequirements Describes the requirements for a report to be run in terms of trade-level measures that can be separately obtained by the calculation engine.ReportRequirements.Meta The meta-bean forReportRequirements
.