Interface KlineStrategy
- All Superinterfaces:
Nameable, Named, Strategy, SubscriptionStrategy<Kline>
- All Known Implementing Classes:
AbstractKlineStrategy
Defines a Kline (candlestick) strategy.
A KlineStrategy pins exactly one KlineInterval via getInterval(); the runtime
subscribes the strategy to exchangeSupport.getKlines(getInterval()) and feeds each Kline natively into the indicator chain — so the existing KlineValueSource-based OHLCV indicators work. getMarketDataSource() returning MarketDataSource.KLine is what flags the strategy as a
kline consumer at the runtime layer.
-
Method Summary
Modifier and TypeMethodDescriptiondefault booleandefault booleanacceptInstrument(@NonNull Instrument instrument) The single kline cadence this strategy consumes (s1, m1, m5, …).default MarketDataSourceMethods inherited from interface Strategy
applyProperty, configure, getExecutionCallback, getExecutionConfig, getExecutionMode, getId, getInputCurrency, getInstruments, getNotices, getOutputCurrency, getProperty, getProperty, getPropertyInfo, getPropertyInfos, getSignals, getStateStore, getStats, getYields, hasProperty, hasProperty, init, isCurrencyLess, isEnabled, reset, setEnabled, setProperty, setPropertyMethods inherited from interface SubscriptionStrategy
subscribeSource, update, updateFrom
-
Method Details
-
getInterval
KlineInterval getInterval()The single kline cadence this strategy consumes (s1, m1, m5, …). -
accept
- Specified by:
acceptin interfaceSubscriptionStrategy<Kline>
-
acceptInstrument
- Specified by:
acceptInstrumentin interfaceSubscriptionStrategy<Kline>
-
getMarketDataSource
- Specified by:
getMarketDataSourcein interfaceSubscriptionStrategy<Kline>
-