20#ifndef ORES_TRADING_DOMAIN_TRADE_INSTRUMENT_HPP
21#define ORES_TRADING_DOMAIN_TRADE_INSTRUMENT_HPP
24#include "ores.trading.api/domain/instrument.hpp"
25#include "ores.trading.api/domain/fx_instrument_variant.hpp"
26#include "ores.trading.api/domain/equity_instrument_variant.hpp"
27#include "ores.trading.api/domain/bond_instrument.hpp"
28#include "ores.trading.api/domain/credit_instrument.hpp"
29#include "ores.trading.api/domain/commodity_instrument.hpp"
30#include "ores.trading.api/domain/scripted_instrument.hpp"
32namespace ores::trading::domain {
42using trade_instrument = std::variant<
45 fx_instrument_variant,
48 equity_instrument_variant,
50 composite_instrument_data,
54inline void stamp_ids(trade_instrument& ti,
55 boost::uuids::uuid instrument_id,
56 boost::uuids::uuid trade_id) {
57 std::visit([&]<
typename T>(T& v) {
58 if constexpr (!std::is_same_v<T, std::monostate>)
59 stamp_ids(v, instrument_id, trade_id);