algotradelib 0.0.0.9000
C++ header-only library for algorithmic trading
Loading...
Searching...
No Matches
algotradelib::runner::RunRecord Struct Reference

What a journal line says about a run budget's ledger (strategy::RiskLimits::run_budget_). More...

#include <algotradelib/src/runner/journal.hpp>

Public Attributes

std::string run_
 The run's id: the id of its RunRecordKind::OPEN line.
std::optional< RunRecordKind > kind_
 What a LEDGER line records; empty on every other line.
std::optional< Money > amount_
 A transfer's amount, an opening's budget, or what a booked fill traded for.
std::optional< Decimal64 > filled_
 A booked fill's quantity.
std::optional< Decimal64 > fee_
 A booked fill's commission and taxes together, in amount_'s currency.
bool fee_estimated_ {false}
 Whether part of fee_ was estimated from strategy::RiskLimits::run_fees_.
std::string given_
 The operator's id of a transfer, which makes it apply once.
std::string of_
 The journal id of the placement a RunRecordKind::FILL books.

Detailed Description

What a journal line says about a run budget's ledger (strategy::RiskLimits::run_budget_).

On a run's PLACE lines it names the run alone; on a CONFIRMED line it also books the fill; on a JournalAction::LEDGER line it is the whole record. A runner without a budget writes none on its own lines, which are then those of a journal from before run budgets; a line it writes to close a restored order of a run keeps that order's run, so a budgeted recovery reads the order as released without a booking.

Definition at line 456 of file journal.hpp.

Member Data Documentation

◆ amount_

std::optional<Money> algotradelib::runner::RunRecord::amount_

A transfer's amount, an opening's budget, or what a booked fill traded for.

Definition at line 462 of file journal.hpp.

◆ fee_

std::optional<Decimal64> algotradelib::runner::RunRecord::fee_

A booked fill's commission and taxes together, in amount_'s currency.

Definition at line 466 of file journal.hpp.

◆ fee_estimated_

bool algotradelib::runner::RunRecord::fee_estimated_ {false}

Whether part of fee_ was estimated from strategy::RiskLimits::run_fees_.

Definition at line 468 of file journal.hpp.

◆ filled_

std::optional<Decimal64> algotradelib::runner::RunRecord::filled_

A booked fill's quantity.

Definition at line 464 of file journal.hpp.

◆ given_

std::string algotradelib::runner::RunRecord::given_

The operator's id of a transfer, which makes it apply once.

Definition at line 470 of file journal.hpp.

◆ kind_

std::optional<RunRecordKind> algotradelib::runner::RunRecord::kind_

What a LEDGER line records; empty on every other line.

Definition at line 460 of file journal.hpp.

◆ of_

std::string algotradelib::runner::RunRecord::of_

The journal id of the placement a RunRecordKind::FILL books.

Definition at line 472 of file journal.hpp.

◆ run_

std::string algotradelib::runner::RunRecord::run_

The run's id: the id of its RunRecordKind::OPEN line.

Definition at line 458 of file journal.hpp.


The documentation for this struct was generated from the following file: