1 023 B
1 023 B
IndicatorsCts
Generic wrapper for consuming MetaTrader technical indicators, with a reusable instance pool to avoid duplicate handles.
Main features
- Uniform wrapper over common indicators: RSI, MA, CCI, Stochastic, VIDyA, Bollinger Bands, SuperTrend, VWAP change, AD, OBV, Standard Deviation, SAR, ADX and ADX Wilder (
CiRsi,CiMa,CiCci,CiStocastic,CiBands,CiSuperTrend,CiAdx, etc., all built onCiIndicatorSimple<TNumBuffer>). - Instance pool/cache keyed by parameters, so the same indicator handle is reused instead of recreated (
CIndicatorCache).
Basic usage
Creating an indicator
CiRsi* rsi = new CiRsi();
rsi.Create(iRSI(_Symbol, PERIOD_CURRENT, 14, PRICE_CLOSE), true);
Using the pool instead of creating handles manually
// CIndicatorCache resolves/reuses handles internally by symbol+timeframe+params,
// avoiding duplicate indicator handles across the EA.
Only the most representative classes are shown here.