public interface SubscriptionFilter
SubscriptionFilter
is used to block unwanted subscription.
Its main purpose is to control subscription and corresponding data flows in
a situation with multiple providers and consumers. For example, it allows
to block sending local data subscription to remote data provider or to block
remote data consumers from subscribing to local data.
The SubscriptionFilter
must be stable - it must return the same
result for the same record no matter of external circumstances, otherwise
the behavior of QD components is unspecified.
The SubscriptionFilter
imposes the same performance restrictions
as other visiting interfaces - the implementer of SubscriptionFilter
must perform its operations quickly without need for synchronization and prolonged
external actions.
As a general rule wildcard
subscription should
always be accepted (when the corresponding record is allowed at all), however filtering
wildcard subscription is actually allowed (you can install filters to decide which
agents or distributors are allowed to use wildcard subscription).
This is a legacy interface. All new implementations shall extend
QDFilter
class. Legacy implementations of this interface are coerced into QDFilter
class using QDFilter.fromFilter(com.devexperts.qd.SubscriptionFilter, com.devexperts.qd.DataScheme)
method.
Modifier and Type | Method and Description |
---|---|
boolean |
acceptRecord(DataRecord record,
int cipher,
String symbol)
Determines if specified record shall be processed by corresponding subsystem.
|
boolean acceptRecord(DataRecord record, int cipher, String symbol)
Copyright © 2002-2019 Devexperts LLC. All Rights Reserved.