Loading...
Searching...
No Matches
ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings > Class Template Reference

Author-facing entry points for the heatmap indicator API. The non-generic HeatmapIndicator coexists with the generic HeatmapIndicator<TSettings> base class — different arities disambiguate them at the type system level. More...

Inheritance diagram for ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >:
[legend]
Collaboration diagram for ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >:
[legend]

Public Member Functions

virtual ValueTask ConfigureAsync (TSettings settings, CancellationToken cancellationToken)
 Apply user-edited settings. The base class has already stored settings in the inherited Settings property by the time this runs, so the default implementation does nothing. Override only when the indicator needs to react to a settings change — e.g. invalidate an accumulator, request a state reset on calc-mode change, or rebuild visual presentation under a lease. Implementations do not need to assign the supplied settings to a private field; read them via Settings.
 
ValueTask ConfigureAsync (object settings, CancellationToken cancellationToken)
 Apply user-edited settings. The runtime type of settings must be assignable to SettingsType.
 
ValueTask OnStateResetNotificationAsync (IHeatmapIndicatorContext context, IHeatmapIndicatorRuntime runtime, CancellationToken cancellationToken)
 Notify the indicator that the platform has cleared State. Called when the active context changes (instrument, session, time zone) or when the indicator itself called IHeatmapIndicatorRuntime.RequestStateResetAsync.
 

Static Public Member Functions

static HeatmapIndicatorDescriptorBuilder Describe (string indicatorId, string? label=null)
 Begin describing a heatmap indicator. The returned builder yields visual and series handles that the author captures into static readonly fields; the runtime IHeatmapVisualState that backs the indicator is materialised lazily by the base class.
 
static HeatmapIndicatorDescriptorBuilder Describe< TSelf > (string? labelOverride=null)
 Typed overload that resolves the indicator id and label from the HeatmapIndicatorAttribute applied to TSelf . Equivalent to HeatmapIndicator<TSettings>.Describe<TSelf> but callable from any context (tests, factories) — author code inside the static constructor of an indicator should prefer the inherited base-class helper, which yields the shorter Describe<Self>() spelling.
 

Protected Member Functions

virtual ValueTask OnStateResetCoreAsync (IHeatmapIndicatorContext context, IHeatmapIndicatorRuntime runtime, CancellationToken cancellationToken)
 Override to react to a state-reset notification. The base class has already saved context and runtime into Context / Runtime by the time this runs, so most overrides only need to clear their own indicator-internal accumulators (fields, dictionaries, etc.) and don't need either argument. The arguments are still surfaced for indicators that want to drive a re-warm or capture context-derived state synchronously.
 
void UpdateVisual (HeatmapIndicatorVisualHandle visual, Action< IHeatmapVisualLease > update)
 Mutate one visual under a short-lived state lease. Use this for style/presentation-only updates or when a callback needs one visual lease and no cross-visual coordination.
 
void UpdateSeries< TValue > (HeatmapIndicatorSeriesHandle< TValue > series, Action< IHeatmapSeriesLease< TValue > > update)
 Mutate one series under a short-lived state lease. Use this for simple append/clear/trim operations where the visual style and presentation do not need to change in the same transaction.
 
void ClearSeries< TValue > (params HeatmapIndicatorSeriesHandle< TValue >[] series)
 Clear a homogeneous set of series under a short-lived state lease.
 

Static Protected Member Functions

static void ClearSeries< TValue > (IHeatmapVisualLease visualLease, params HeatmapIndicatorSeriesHandle< TValue >[] series)
 Clear a homogeneous set of series inside an existing visual lease. Useful for rebuilds that clear and refill multiple related series in one commit.
 
static HeatmapIndicatorDescriptorBuilder Describe< TSelf > (string? labelOverride=null)
 Begin describing the indicator using metadata from the HeatmapIndicatorAttribute applied to TSelf . Authors call this from the static constructor of the deriving type, which keeps the type id declared exactly once (in the attribute) and removes the typo-mismatch risk between discovery metadata and the descriptor.
 
static List< HeatmapTradeTick > OrderedTicks (HeatmapTickBatch ticks)
 Return eligible ticks from a pooled batch ordered by timestamp. The returned list is detached from the batch and may be kept after the callback returns.
 
static List< HeatmapTradeTick > OrderedTicks (HeatmapTickBatch ticks, Predicate< HeatmapTradeTick > predicate)
 Return eligible ticks from a pooled batch ordered by timestamp. The returned list is detached from the batch and may be kept after the callback returns.
 
static List< HeatmapTradeTick > OrderedTicks (IEnumerable< HeatmapTradeTick > ticks)
 Return eligible ticks from an enumerable ordered by timestamp.
 
static List< HeatmapTradeTick > OrderedTicks (IEnumerable< HeatmapTradeTick > ticks, Predicate< HeatmapTradeTick > predicate)
 Return eligible ticks from an enumerable ordered by timestamp.
 
static bool HasValidTimestampPriceVolume (HeatmapTradeTick tick)
 Common filter for price/volume indicators: timestamp, price, and volume must all be positive.
 
static bool HasValidBuySellVolume (HeatmapTradeTick tick)
 Common filter for buy/sell volume indicators: timestamp and volume must be positive and direction must be buy or sell.
 

Properties

abstract HeatmapIndicatorDescriptor Descriptor [get]
 Static type-level metadata. Identifies the indicator type, declares its placement (overlay vs sub-panel), visual roles, and series shape. Must not change between calls.
 
Type SettingsType [get]
 CLR type of the settings DTO this indicator accepts. Used by the catalogue to materialise persisted settings into the right shape before calling ConfigureAsync.
 
TSettings Settings [get]
 Most recent settings DTO applied through ConfigureAsync. The base class assigns this property before invoking the typed ConfigureAsync(TSettings, CancellationToken) override, so derived indicators can read the current settings directly without caching them into a private field. Defaults to a fresh TSettings instance until the platform calls ConfigureAsync for the first time.
 
IHeatmapVisualState State [get]
 Persistent visual state. Lazily created on first access from the indicator's own Descriptor; the platform may pre-create it via IHeatmapIndicator.State at instance construction time so the reference is stable from the first lifecycle callback onward.
 
IHeatmapIndicatorContextContext [get]
 Most recent context handed in by the platform via IHeatmapIndicator.OnStateResetNotificationAsync. Null only before the very first reset notification — the platform always emits a reset before any data callback, so by the time IHeatmapTradeTickConsumer.ProcessTicksAsync / IHeatmapWarmupIndicator.WarmUpAsync / IHeatmapProfileConsumer.ProcessProfileAsync fires this is non-null.
 
IHeatmapIndicatorRuntimeRuntime [get]
 Most recent runtime handed in by the platform via IHeatmapIndicator.OnStateResetNotificationAsync. Use to call IHeatmapIndicatorRuntime.RequestReWarmAsync / IHeatmapIndicatorRuntime.RequestStateResetAsync. The reference is rebound on every reset, so do not cache it across reset boundaries — read this property each time.
 
- Properties inherited from ATAS.Indicators.Heatmap.IHeatmapIndicator
HeatmapIndicatorDescriptor Descriptor [get]
 Static type-level metadata. Identifies the indicator type, declares its placement (overlay vs sub-panel), visual roles, and series shape. Must not change between calls.
 
Type SettingsType [get]
 CLR type of the settings DTO this indicator accepts. Used by the catalogue to materialise persisted settings into the right shape before calling ConfigureAsync.
 
IHeatmapVisualState State [get]
 Persistent visual state read by the renderer. Created by the platform from Descriptor at instance construction time; the same reference is returned for the entire instance lifetime. Resets clear content but never replace the reference.
 

Detailed Description

Author-facing entry points for the heatmap indicator API. The non-generic HeatmapIndicator coexists with the generic HeatmapIndicator<TSettings> base class — different arities disambiguate them at the type system level.

Strongly typed base for indicator authors. Bridges to the non-generic IHeatmapIndicator with a single explicit cast, so derived classes work against typed settings.

Type Constraints
TSettings :class 
TSettings :new() 

Member Function Documentation

◆ ClearSeries< TValue >() [1/2]

static void ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.ClearSeries< TValue > ( IHeatmapVisualLease  visualLease,
params HeatmapIndicatorSeriesHandle< TValue >[]  series 
)
staticprotected

Clear a homogeneous set of series inside an existing visual lease. Useful for rebuilds that clear and refill multiple related series in one commit.

◆ ClearSeries< TValue >() [2/2]

void ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.ClearSeries< TValue > ( params HeatmapIndicatorSeriesHandle< TValue >[]  series)
protected

Clear a homogeneous set of series under a short-lived state lease.

◆ ConfigureAsync()

virtual ValueTask ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.ConfigureAsync ( TSettings  settings,
CancellationToken  cancellationToken 
)
virtual

Apply user-edited settings. The base class has already stored settings in the inherited Settings property by the time this runs, so the default implementation does nothing. Override only when the indicator needs to react to a settings change — e.g. invalidate an accumulator, request a state reset on calc-mode change, or rebuild visual presentation under a lease. Implementations do not need to assign the supplied settings to a private field; read them via Settings.

◆ Describe()

static HeatmapIndicatorDescriptorBuilder ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.Describe ( string  indicatorId,
string?  label = null 
)
static

Begin describing a heatmap indicator. The returned builder yields visual and series handles that the author captures into static readonly fields; the runtime IHeatmapVisualState that backs the indicator is materialised lazily by the base class.

◆ Describe< TSelf >() [1/2]

static HeatmapIndicatorDescriptorBuilder ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.Describe< TSelf > ( string?  labelOverride = null)
static

Typed overload that resolves the indicator id and label from the HeatmapIndicatorAttribute applied to TSelf . Equivalent to HeatmapIndicator<TSettings>.Describe<TSelf> but callable from any context (tests, factories) — author code inside the static constructor of an indicator should prefer the inherited base-class helper, which yields the shorter Describe<Self>() spelling.

Type Constraints
TSelf :IHeatmapIndicator 
TSelf :DescribeFromAttribute 
TSelf :typeof 
TSelf :TSelf 
TSelf :labelOverride 

◆ Describe< TSelf >() [2/2]

static HeatmapIndicatorDescriptorBuilder ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.Describe< TSelf > ( string?  labelOverride = null)
staticprotected

Begin describing the indicator using metadata from the HeatmapIndicatorAttribute applied to TSelf . Authors call this from the static constructor of the deriving type, which keeps the type id declared exactly once (in the attribute) and removes the typo-mismatch risk between discovery metadata and the descriptor.

Parameters
labelOverrideWhen non-null, used as the descriptor label instead of the attribute's HeatmapIndicatorAttribute.DisplayName.
Type Constraints
TSelf :IHeatmapIndicator 
TSelf :HeatmapIndicator.DescribeFromAttribute 
TSelf :typeof 
TSelf :TSelf 
TSelf :labelOverride 

◆ HasValidBuySellVolume()

static bool ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.HasValidBuySellVolume ( HeatmapTradeTick  tick)
staticprotected

Common filter for buy/sell volume indicators: timestamp and volume must be positive and direction must be buy or sell.

◆ HasValidTimestampPriceVolume()

static bool ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.HasValidTimestampPriceVolume ( HeatmapTradeTick  tick)
staticprotected

Common filter for price/volume indicators: timestamp, price, and volume must all be positive.

◆ OnStateResetCoreAsync()

virtual ValueTask ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.OnStateResetCoreAsync ( IHeatmapIndicatorContext  context,
IHeatmapIndicatorRuntime  runtime,
CancellationToken  cancellationToken 
)
protectedvirtual

Override to react to a state-reset notification. The base class has already saved context and runtime into Context / Runtime by the time this runs, so most overrides only need to clear their own indicator-internal accumulators (fields, dictionaries, etc.) and don't need either argument. The arguments are still surfaced for indicators that want to drive a re-warm or capture context-derived state synchronously.

◆ OrderedTicks() [1/4]

static List< HeatmapTradeTick > ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.OrderedTicks ( HeatmapTickBatch  ticks)
staticprotected

Return eligible ticks from a pooled batch ordered by timestamp. The returned list is detached from the batch and may be kept after the callback returns.

◆ OrderedTicks() [2/4]

static List< HeatmapTradeTick > ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.OrderedTicks ( HeatmapTickBatch  ticks,
Predicate< HeatmapTradeTick >  predicate 
)
staticprotected

Return eligible ticks from a pooled batch ordered by timestamp. The returned list is detached from the batch and may be kept after the callback returns.

◆ OrderedTicks() [3/4]

static List< HeatmapTradeTick > ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.OrderedTicks ( IEnumerable< HeatmapTradeTick >  ticks)
staticprotected

Return eligible ticks from an enumerable ordered by timestamp.

◆ OrderedTicks() [4/4]

static List< HeatmapTradeTick > ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.OrderedTicks ( IEnumerable< HeatmapTradeTick >  ticks,
Predicate< HeatmapTradeTick >  predicate 
)
staticprotected

Return eligible ticks from an enumerable ordered by timestamp.

◆ UpdateSeries< TValue >()

void ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.UpdateSeries< TValue > ( HeatmapIndicatorSeriesHandle< TValue >  series,
Action< IHeatmapSeriesLease< TValue > >  update 
)
protected

Mutate one series under a short-lived state lease. Use this for simple append/clear/trim operations where the visual style and presentation do not need to change in the same transaction.

◆ UpdateVisual()

void ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.UpdateVisual ( HeatmapIndicatorVisualHandle  visual,
Action< IHeatmapVisualLease update 
)
protected

Mutate one visual under a short-lived state lease. Use this for style/presentation-only updates or when a callback needs one visual lease and no cross-visual coordination.

Property Documentation

◆ Context

Most recent context handed in by the platform via IHeatmapIndicator.OnStateResetNotificationAsync. Null only before the very first reset notification — the platform always emits a reset before any data callback, so by the time IHeatmapTradeTickConsumer.ProcessTicksAsync / IHeatmapWarmupIndicator.WarmUpAsync / IHeatmapProfileConsumer.ProcessProfileAsync fires this is non-null.

◆ Descriptor

abstract HeatmapIndicatorDescriptor ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.Descriptor
get

Static type-level metadata. Identifies the indicator type, declares its placement (overlay vs sub-panel), visual roles, and series shape. Must not change between calls.

Implements ATAS.Indicators.Heatmap.IHeatmapIndicator.

◆ Runtime

Most recent runtime handed in by the platform via IHeatmapIndicator.OnStateResetNotificationAsync. Use to call IHeatmapIndicatorRuntime.RequestReWarmAsync / IHeatmapIndicatorRuntime.RequestStateResetAsync. The reference is rebound on every reset, so do not cache it across reset boundaries — read this property each time.

◆ Settings

TSettings ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.Settings
getprotected

Most recent settings DTO applied through ConfigureAsync. The base class assigns this property before invoking the typed ConfigureAsync(TSettings, CancellationToken) override, so derived indicators can read the current settings directly without caching them into a private field. Defaults to a fresh TSettings instance until the platform calls ConfigureAsync for the first time.

◆ SettingsType

Type ATAS.Indicators.Heatmap.HeatmapIndicator< TSettings >.SettingsType
get

CLR type of the settings DTO this indicator accepts. Used by the catalogue to materialise persisted settings into the right shape before calling ConfigureAsync.

Implements ATAS.Indicators.Heatmap.IHeatmapIndicator.

◆ State

Persistent visual state. Lazily created on first access from the indicator's own Descriptor; the platform may pre-create it via IHeatmapIndicator.State at instance construction time so the reference is stable from the first lifecycle callback onward.

Implements ATAS.Indicators.Heatmap.IHeatmapIndicator.


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