algotradelib 0.0.0.9000
C++ header-only library for algorithmic trading
Loading...
Searching...
No Matches
algotradelib::mock::MarketFileError Class Reference

Thrown by a kept market's Market::advance_to when its state file (MarketFile) could not record the move; the clock did not move. More...

#include <algotradelib/src/brokers/mock/market.hpp>

Inheritance diagram for algotradelib::mock::MarketFileError:
Collaboration diagram for algotradelib::mock::MarketFileError:

Public Types

enum class  Kind { NOT_WRITTEN , UNCONFIRMED }
 What became of the record. More...

Public Member Functions

 MarketFileError (Kind kind)
 Constructs the error.
Kind kind () const noexcept
 Returns what became of the record.

Detailed Description

Thrown by a kept market's Market::advance_to when its state file (MarketFile) could not record the move; the clock did not move.

Definition at line 50 of file market.hpp.

Member Enumeration Documentation

◆ Kind

What became of the record.

Enumerator
NOT_WRITTEN 

It was not written whole, or not at all: reopening the file does not make the move.

UNCONFIRMED 

It was written, and flushing it to disk failed: reopening the file may make the move.

Definition at line 53 of file market.hpp.

Constructor & Destructor Documentation

◆ MarketFileError()

algotradelib::mock::MarketFileError::MarketFileError ( Kind kind)
inlineexplicit

Constructs the error.

Parameters
kindWhat became of the record.

Definition at line 64 of file market.hpp.

Referenced by algotradelib::mock::Market::advance_to().

Member Function Documentation

◆ kind()

Kind algotradelib::mock::MarketFileError::kind ( ) const
inlinenoexcept

Returns what became of the record.

Returns
The kind.

Definition at line 76 of file market.hpp.

Referenced by MarketFileError().


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