IAlgorithmSubscriptionManager
QuantConnect.Interfaces.IAlgorithmSubscriptionManager
Bases: ISubscriptionDataConfigService
AlgorithmSubscriptionManager interface will manage the subscriptions for the SubscriptionManager
subscription_manager_subscriptions
subscription_manager_subscriptions: Iterable[
SubscriptionDataConfig
]
Gets all the current data config subscriptions that are being processed for the SubscriptionManager
available_data_types
available_data_types: Dictionary[
SecurityType, List[TickType]
]
Gets the available data types
subscription_manager_count
subscription_manager_count() -> int
Returns the amount of data config subscriptions processed for the SubscriptionManager
get_subscription_data_configs
get_subscription_data_configs(
symbol: Union[Symbol, str, BaseContract] = None,
include_internal_configs: bool = False,
) -> List[SubscriptionDataConfig]
Gets a list of all registered SubscriptionDataConfig for a given Symbol if any else will return the whole list of subscriptions
add
add(
data_type: Type,
symbol: Union[Symbol, str, BaseContract],
resolution: Optional[Resolution] = None,
fill_forward: bool = True,
extended_market_hours: bool = False,
is_filtered_subscription: bool = True,
is_internal_feed: bool = False,
is_custom_data: bool = False,
data_normalization_mode: DataNormalizationMode = ...,
data_mapping_mode: DataMappingMode = ...,
contract_depth_offset: int = 0,
) -> SubscriptionDataConfig
add(
symbol: Union[Symbol, str, BaseContract],
resolution: Optional[Resolution] = None,
fill_forward: bool = True,
extended_market_hours: bool = False,
is_filtered_subscription: bool = True,
is_internal_feed: bool = False,
is_custom_data: bool = False,
subscription_data_types: List[
Tuple[Type, TickType]
] = None,
data_normalization_mode: DataNormalizationMode = ...,
data_mapping_mode: DataMappingMode = ...,
contract_depth_offset: int = 0,
) -> List[SubscriptionDataConfig]
Signature descriptions:
-
Creates and adds a list of SubscriptionDataConfig for a given symbol and configuration. Can optionally pass in desired subscription data type to use. If the config already existed will return existing instance instead
-
Creates and adds a list of SubscriptionDataConfig for a given symbol and configuration. Can optionally pass in desired subscription data types to use. If the config already existed will return existing instance instead
lookup_subscription_config_data_types
lookup_subscription_config_data_types(
symbol_security_type: SecurityType,
resolution: Resolution,
is_canonical: bool,
) -> List[Tuple[Type, TickType]]
Get the data feed types for a given SecurityTypeResolution
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
symbol_security_type
|
SecurityType
|
The SecurityType used to determine the types |
required |
resolution
|
Resolution
|
The resolution of the data requested |
required |
is_canonical
|
bool
|
Indicates whether the security is Canonical (future and options) |
required |
Returns:
| Type | Description |
|---|---|
List[Tuple[Type, TickType]]
|
Types that should be added to the SubscriptionDataConfig. |