By default, Handler processes market data for all securities that are available in a particular
market data channel. For certain channels, it may be a huge amount of data, which may
cause Handler to allocate significant amount of system resources (like a memory).
From the other side, it often happens that all securities are not the point of interest.
For these reasons, Handler provides an ability to define a subset of securities for
which it will monitor market data, maintain books and report about changes in
statistics. No events will be fired by Handler for any security, if they aren't presented in
a defined subset. Subsets can be specified by security id, symbol and security group.
Filtering must be manipulated only when Handler is stopped or receiving security definitions.
Once Handler is started to process market data, filters must not be modified.
Filtering By Security Id There're three Handler members which affect security id filtering:
- AddSecurityIdFilter(Int32) puts a security id into
the collection of security ids for which Handler must process market data.
RemoveSecurityIdFilter(Int32) excludes single security
id from the set of security ids for which Handler processes market data.
ClearSecurityIdFilters() removes all security id
filters and restores default behavior when all market data are processed by
Handler.
Filtering By Symbol There're three Handler members which affect symbol filtering:
- AddSymbolFilter(String) puts a symbol into
the collection of security descriptions for which Handler must process market data.
RemoveSymbolFilter(String) excludes single symbol
from the set of security descriptions for which Handler processes market data.
ClearSymbolFilters() removes all symbol
filters and restores default behavior when all market data are processed by
Handler.
Filtering By Security Group There're three Handler members which affect security group filtering:
- AddSecurityGroupFilter(String) puts a security group into
the collection of security descriptions for which Handler must process market data.
RemoveSecurityGroupFilter(String) excludes single security group
from the set of security descriptions for which Handler processes market data.
ClearSecurityGroupFilters() removes all security group
filters and restores default behavior when all market data are processed by
Handler.