|
ORE Studio 0.0.4
|
Imports domain objects from their ORE XML representation. More...
#include <importer.hpp>

Static Public Member Functions | |
| static std::string | validate_currency (const refdata::domain::currency ¤cy) |
| Validates a currency against XSD schema requirements. | |
| static std::vector< refdata::domain::currency > | import_currency_config (const std::filesystem::path &path) |
| static std::string | validate_calendar_adjustment (const refdata::domain::calendar_adjustment &ca) |
| Validates a calendar adjustment entry. | |
| static std::vector< refdata::domain::calendar_adjustment > | import_calendar_adjustments (const std::filesystem::path &path) |
| Imports calendar adjustments from an ORE calendaradjustment XML file. | |
| static domain::mapped_conventions | import_conventions (const std::filesystem::path &path) |
| Imports all recognised conventions from an ORE conventions XML file. | |
| static std::string | validate_trade (const trading::domain::trade &trade) |
| Validates a trade against minimum import requirements. | |
| static std::vector< trade_import_item > | import_portfolio_with_context (const std::filesystem::path &path) |
| Imports trades from an ORE portfolio XML file with mapping context. | |
Imports domain objects from their ORE XML representation.
|
static |
Validates a currency against XSD schema requirements.
Performs lightweight validation checking required fields per assets/xsds/currencyconfig.xsd without requiring external libraries.
| currency | Currency to validate |

|
static |
Validates a calendar adjustment entry.
| ca | Calendar adjustment to validate |
|
static |
Imports calendar adjustments from an ORE calendaradjustment XML file.
Reads additional holidays and business day overrides for named ORE calendars. The file format is defined by calendaradjustment.xsd.
| path | Path to the calendaradjustment.xml file |
<Calendar> element 
|
static |
Imports all recognised conventions from an ORE conventions XML file.
Parses the ORE conventions.xml and maps the nine supported convention categories (Zero, Deposit, Swap, OIS, FRA, IborIndex, OvernightIndex, FX, CDS) to ORES refdata domain types. Additional ORE convention types (AverageOIS, TenorBasisSwap, CrossCurrencyBasis, InflationSwap, etc.) are present in the file but are not yet modelled and are silently skipped.
| path | Path to the conventions.xml file |
mapped_conventions struct containing one vector per convention type 
|
static |
Validates a trade against minimum import requirements.
Checks that the trade has at least the fields that can be directly mapped from ORE XML: external_id and trade_type. Fields that require external mapping (book_id, counterparty_id, etc.) are not validated here.
| trade | Trade to validate |

|
static |
Imports trades from an ORE portfolio XML file with mapping context.
Parses the portfolio XML, maps each trade to the ORES trading domain, and captures the raw ORE CounterParty string from each trade envelope. All UUID fields (trade.id, instrument_id, book_id, etc.) are left nil; the caller (e.g. ore_import_planner) is responsible for minting UUIDs via trading::domain::stamp_ids and populating context fields.
| path | Path to the ORE portfolio XML file |
