PineForge v1.4.0-4-g873b25da
Deterministic PineScript v6 backtest runtime — C ABI reference
Loading...
Searching...
No Matches
pineforge::native_order::native_order_v7::ActivationGrid Struct Reference

What the consumer hands to prepare_trigger under an opted-in price grid (NativeRunSpec::price_grid == QuantizeFillsAndTriggers), the way acceptance receives CommandContext::price_tick: the tick ladder and the rounding the matcher tested the activation on. More...

#include <native_order.hpp>

Data Fields

double price_tick = 0.0
 
bool half_up = true
 
double ladder_tick = 0.0
 

Detailed Description

What the consumer hands to prepare_trigger under an opted-in price grid (NativeRunSpec::price_grid == QuantizeFillsAndTriggers), the way acceptance receives CommandContext::price_tick: the tick ladder and the rounding the matcher tested the activation on.

The core then re-validates the reached print with the same grid arithmetic (L8b ruling: under that grid the tick-quantized print IS the reached price, so a hit the matcher reports is never refused), records the quantized print as the activation's reached price, and keeps a trail's running best on the ladder. A default-constructed value (no ladder) is exactly the raw compare and the raw print every activation used before. Host-free: values only.

ladder_tick is a different question, appended last so every existing aggregate initializer keeps its meaning: the run's DECLARED price tick (NativeRunSpec::price_tick), whatever the quantization mode. Nothing is tested or rounded on it; it is the ladder a level spelled in ticks names, so a trailing stop a whole number of ticks from a best on that ladder is the ladder point it names rather than the subtraction's ULP-off neighbour (native_matching::ladder_trail_stop, R5 lane E16). Zero leaves the raw arithmetic, which is what a run with no declared tick has.

Definition at line 1548 of file native_order.hpp.

Field Documentation

◆ price_tick

double pineforge::native_order::native_order_v7::ActivationGrid::price_tick = 0.0

Definition at line 1549 of file native_order.hpp.

◆ half_up

bool pineforge::native_order::native_order_v7::ActivationGrid::half_up = true

Definition at line 1550 of file native_order.hpp.

◆ ladder_tick

double pineforge::native_order::native_order_v7::ActivationGrid::ladder_tick = 0.0

Definition at line 1551 of file native_order.hpp.


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