|
PineForge unreleased
Deterministic PineScript v6 backtest runtime — C ABI reference
|
Data Structures | |
| struct | Event |
| One driving event: its kind and its time. More... | |
| struct | Point |
| One planned calculation. More... | |
Enumerations | |
| enum class | EventKind : std::uint32_t { WarmupBar = 1 , Bar = 2 , Tick = 3 , AdvanceTime = 4 } |
| The driving events of a schedule. More... | |
| enum class | Phase : std::uint32_t { Pre = 0 , Post = 1 } |
| Whether a calculation ran before the payload of its driving event was applied (a bar closed only because time reached its end) or after it. More... | |
| enum class | Finality : std::uint32_t { Provisional = 0 , Confirmed = 1 } |
| Provisional for an intrabar calculation, Confirmed for the calculation that closes a bar. More... | |
| enum class | Status : std::uint32_t { Ok = 0 , NotEngaged , BadArguments , BadCadence , UnknownEventKind , BarKeyExhausted , TraceExhausted , NoBarSlot , BarEndNotAfterEvent , PositionOutsideWindow } |
| How a derivation ended. More... | |
Functions | |
| constexpr bool | is_known (EventKind kind) noexcept |
Whether kind is in the registry: the one range check a raw number passes before the derivation treats it as an EventKind. | |
Variables | |
| constexpr std::uint32_t | kCadenceAdvanceTime = 1u << 0 |
| Which driving events make an instance calculate, as a bit set. | |
| constexpr std::uint32_t | kCadenceBarClose = 1u << 1 |
| constexpr std::uint32_t | kCadenceTick = 1u << 2 |
| constexpr std::uint32_t | kCadenceMask |
|
strong |
The driving events of a schedule.
The numbers are the event-kind registry of the named-stream boundary; zero, and every value above AdvanceTime, name no event: the derivation refuses them rather than plan nothing for them.
| Enumerator | |
|---|---|
| WarmupBar | |
| Bar | |
| Tick | |
| AdvanceTime | |
Definition at line 16 of file native_calc_point.hpp.
|
strong |
Whether a calculation ran before the payload of its driving event was applied (a bar closed only because time reached its end) or after it.
| Enumerator | |
|---|---|
| Pre | |
| Post | |
Definition at line 48 of file native_calc_point.hpp.
|
strong |
Provisional for an intrabar calculation, Confirmed for the calculation that closes a bar.
| Enumerator | |
|---|---|
| Provisional | |
| Confirmed | |
Definition at line 55 of file native_calc_point.hpp.
|
strong |
How a derivation ended.
Ok with a count of zero is a schedule that plans no calculation; every other status is a refusal and plans nothing.
Definition at line 83 of file native_calc_point.hpp.
|
constexprnoexcept |
Whether kind is in the registry: the one range check a raw number passes before the derivation treats it as an EventKind.
Definition at line 25 of file native_calc_point.hpp.
References AdvanceTime, and WarmupBar.
|
inlineconstexpr |
Which driving events make an instance calculate, as a bit set.
A cadence always contains kCadenceBarClose; the other two bits are optional.
Definition at line 40 of file native_calc_point.hpp.
|
inlineconstexpr |
Definition at line 41 of file native_calc_point.hpp.
|
inlineconstexpr |
Definition at line 42 of file native_calc_point.hpp.
|
inlineconstexpr |
Definition at line 43 of file native_calc_point.hpp.