The bar update manager utility class may be used to keep a historical data selection up to date. When the CompressTicks method is used to create a temporary historic bar table, the historical selection will need to be updated in order to keep the data up to date. The BarUpdateManager class simplifies this.
BarUpdateManager Methods
| Watch(BSTR Symbol, DataType
BarType, short Interval)
Adds a symbol to a bar watch.
Remove(BSTR Symbol, DataType BarType, short Interval) Removes a symbol from a bar watch.
Update(BSTR Symbol, DataType BarType, short Interval, DateTimeInfo LastDateTime, double Last) Updates the current bar with the last price. |
BarUpdateManager Events
| NewBar(BSTR Symbol, DataType
BarType, short Interval, DateTimeInfo
BarDateTime, double OpenPrice, double HighPrice, double LowPrice,
double ClosePrice)
Fires when a new bar has been created as per the specified Type and Interval passed to the Watch method. |
Remarks
The Bar Update Manager simply watches incoming tick data that you supply it with via the Update method, and then fires an even when a new bar is created. The BarUpdateManager.Update method is typically called from inside the Connection.Update event.
See Also
DataType, DateTimeInfo, CompressTicks