/// <summary> /// Concatenates when any of <see cref="IUpdatable"/> are updated for every n <paramref name="interval"/>. /// </summary> /// <param name="name">Name of the cruncher for debugging purposes.</param> /// <param name="interval">The interval for how many fires must any of <paramref name="updatables"/> trigger <see cref="IUpdatable.Updated"/> in order to trigger IndicatorRow's update event.</param> /// <param name="properties"> /// How many properties all of the <paramref name="updatables"/> emit. /// this can be less than their minimal properties. /// e.g. if <paramref name="updatables"/> emit <see cref="BarValue"/> (4 properties), selecting 1 will take only <see cref="BarValue.Close"/>. /// </param> /// <param name="size">How many indicators will be initialized via <paramref name="factory"/>.</param> /// <param name="factory">A factory to initialize new indicators.</param> /// <returns>A new cruncher configured.</returns> public static Concat OnEveryUpdate(IUpdatable source, BindingIndicatorFactoryHandler factory, int interval = 1, int properties = 1, string name = null, bool waitForSourceReady = true) { IUpdatable[] sources = Factory(source, factory); return(BindToConcatenatingList(source, Concat.OnEveryUpdate(sources, interval, properties, name))); }
/// <summary> /// Concatenates when any of <see cref="IUpdatable"/> are updated for every n <paramref name="interval"/>. /// </summary> /// <param name="name">Name of the cruncher for debugging purposes.</param> /// <param name="interval">The interval for how many fires must any of <paramref name="updatables"/> trigger <see cref="IUpdatable.Updated"/> in order to trigger IndicatorRow's update event.</param> /// <param name="properties"> /// How many properties all of the <paramref name="updatables"/> emit. /// this can be less than their minimal properties. /// e.g. if <paramref name="updatables"/> emit <see cref="BarValue"/> (4 properties), selecting 1 will take only <see cref="BarValue.Close"/>. /// </param> /// <param name="size">How many indicators will be initialized via <paramref name="factory"/>.</param> /// <param name="factory">A factory to initialize new indicators.</param> /// <returns>A new cruncher configured.</returns> public static Concat OnEveryUpdate(int size, IndicatorFactoryHandler factory, int interval = 1, int properties = 1, string name = null) { return(BindToConcatenatingList(Concat.OnEveryUpdate(Factory(size, factory), interval, properties, name))); }