Lean  $LEAN_TAG$
QuantConnect.Data.SubscriptionDataConfig Class Reference

Subscription data required including the type of data. More...

Inheritance diagram for QuantConnect.Data.SubscriptionDataConfig:
[legend]

Classes

class  NewSymbolEventArgs
 New base class for all event classes. More...
 

Public Member Functions

 SubscriptionDataConfig (Type objectType, Symbol symbol, Resolution resolution, DateTimeZone dataTimeZone, DateTimeZone exchangeTimeZone, bool fillForward, bool extendedHours, bool isInternalFeed, bool isCustom=false, TickType? tickType=null, bool isFilteredSubscription=true, DataNormalizationMode dataNormalizationMode=DataNormalizationMode.Adjusted, DataMappingMode dataMappingMode=DataMappingMode.OpenInterest, uint contractDepthOffset=0, bool mappedConfig=false)
 Constructor for Data Subscriptions More...
 
 SubscriptionDataConfig (SubscriptionDataConfig config, Type objectType=null, Symbol symbol=null, Resolution? resolution=null, DateTimeZone dataTimeZone=null, DateTimeZone exchangeTimeZone=null, bool? fillForward=null, bool? extendedHours=null, bool? isInternalFeed=null, bool? isCustom=null, TickType? tickType=null, bool? isFilteredSubscription=null, DataNormalizationMode? dataNormalizationMode=null, DataMappingMode? dataMappingMode=null, uint? contractDepthOffset=null, bool? mappedConfig=null)
 Copy constructor with overrides More...
 
bool Equals (SubscriptionDataConfig other)
 Indicates whether the current object is equal to another object of the same type. More...
 
override bool Equals (object obj)
 Determines whether the specified object is equal to the current object. More...
 
override int GetHashCode ()
 Serves as the default hash function. More...
 
override string ToString ()
 Returns a string that represents the current object. More...
 

Static Public Member Functions

static bool operator== (SubscriptionDataConfig left, SubscriptionDataConfig right)
 Override equals operator More...
 
static bool operator!= (SubscriptionDataConfig left, SubscriptionDataConfig right)
 Override not equals operator More...
 

Public Attributes

SecurityType SecurityType => Symbol.SecurityType
 Security type of this data subscription More...
 
string Market => Symbol.ID.Market
 Gets the market / scope of the symbol More...
 

Properties

Type Type [get]
 Type of data More...
 
Symbol Symbol [get]
 Symbol of the asset we're requesting: this is really a perm tick!! More...
 
TickType TickType [get]
 Trade, quote or open interest data More...
 
Resolution Resolution [get]
 Resolution of the asset we're requesting, second minute or tick More...
 
TimeSpan Increment [get]
 Timespan increment between triggers of this data: More...
 
bool FillDataForward [get]
 True if wish to send old data when time gaps in data feed. More...
 
bool ExtendedMarketHours [get]
 Boolean Send Data from between 4am - 8am (Equities Setting Only) More...
 
bool IsInternalFeed [get]
 True if this subscription was added for the sole purpose of providing currency conversion rates via CashBook.EnsureCurrencyDataFeeds More...
 
bool IsCustomData [get]
 True if this subscription is for custom user data, false for QC data More...
 
decimal SumOfDividends [get, set]
 The sum of dividends accrued in this subscription, used for scaling total return prices More...
 
DataNormalizationMode DataNormalizationMode [get, set]
 Gets the normalization mode used for this subscription More...
 
DataMappingMode DataMappingMode [get]
 Gets the securities mapping mode used for this subscription More...
 
uint ContractDepthOffset [get]
 The continuous contract desired offset from the current front month. For example, 0 (default) will use the front month, 1 will use the back month contract More...
 
decimal PriceScaleFactor [get, set]
 Price Scaling Factor: More...
 
string? MappedSymbol [get, set]
 Symbol Mapping: When symbols change over time (e.g. CHASE-> JPM) need to update the symbol requested. More...
 
DateTimeZone DataTimeZone [get]
 Gets the data time zone for this subscription More...
 
DateTimeZone ExchangeTimeZone [get]
 Gets the exchange time zone for this subscription More...
 
ISet< IDataConsolidatorConsolidators [get]
 Consolidators that are registred with this subscription More...
 
bool IsFilteredSubscription [get]
 Gets whether or not this subscription should have filters applied to it (market hours/user filters from security) More...
 

Events

EventHandler< NewSymbolEventArgsNewSymbol
 Event fired when there is a new symbol due to mapping More...
 

Detailed Description

Subscription data required including the type of data.

Definition at line 29 of file SubscriptionDataConfig.cs.

Constructor & Destructor Documentation

◆ SubscriptionDataConfig() [1/2]

QuantConnect.Data.SubscriptionDataConfig.SubscriptionDataConfig ( Type  objectType,
Symbol  symbol,
Resolution  resolution,
DateTimeZone  dataTimeZone,
DateTimeZone  exchangeTimeZone,
bool  fillForward,
bool  extendedHours,
bool  isInternalFeed,
bool  isCustom = false,
TickType tickType = null,
bool  isFilteredSubscription = true,
DataNormalizationMode  dataNormalizationMode = DataNormalizationMode.Adjusted,
DataMappingMode  dataMappingMode = DataMappingMode.OpenInterest,
uint  contractDepthOffset = 0,
bool  mappedConfig = false 
)

Constructor for Data Subscriptions

Parameters
objectTypeType of the data objects.
symbolSymbol of the asset we're requesting
resolutionResolution of the asset we're requesting
dataTimeZoneThe time zone the raw data is time stamped in
exchangeTimeZoneSpecifies the time zone of the exchange for the security this subscription is for. This is this output time zone, that is, the time zone that will be used on BaseData instances
fillForwardFill in gaps with historical data
extendedHoursEquities only - send in data from 4am - 8pm
isInternalFeedSet to true if this subscription is added for the sole purpose of providing currency conversion rates, setting this flag to true will prevent the data from being sent into the algorithm's OnData methods
isCustomTrue if this is user supplied custom data, false for normal QC data
tickTypeSpecifies if trade or quote data is subscribed
isFilteredSubscriptionTrue if this subscription should have filters applied to it (market hours/user filters from security), false otherwise
dataNormalizationModeSpecifies normalization mode used for this subscription
dataMappingModeThe contract mapping mode to use for the security
contractDepthOffsetThe continuous contract desired offset from the current front month. For example, 0 (default) will use the front month, 1 will use the back month contract

Definition at line 200 of file SubscriptionDataConfig.cs.

Here is the call graph for this function:

◆ SubscriptionDataConfig() [2/2]

QuantConnect.Data.SubscriptionDataConfig.SubscriptionDataConfig ( SubscriptionDataConfig  config,
Type  objectType = null,
Symbol  symbol = null,
Resolution resolution = null,
DateTimeZone  dataTimeZone = null,
DateTimeZone  exchangeTimeZone = null,
bool?  fillForward = null,
bool?  extendedHours = null,
bool?  isInternalFeed = null,
bool?  isCustom = null,
TickType tickType = null,
bool?  isFilteredSubscription = null,
DataNormalizationMode dataNormalizationMode = null,
DataMappingMode dataMappingMode = null,
uint?  contractDepthOffset = null,
bool?  mappedConfig = null 
)

Copy constructor with overrides

Parameters
configThe config to copy, then overrides are applied and all option
objectTypeType of the data objects.
symbolSymbol of the asset we're requesting
resolutionResolution of the asset we're requesting
dataTimeZoneThe time zone the raw data is time stamped in
exchangeTimeZoneSpecifies the time zone of the exchange for the security this subscription is for. This is this output time zone, that is, the time zone that will be used on BaseData instances
fillForwardFill in gaps with historical data
extendedHoursEquities only - send in data from 4am - 8pm
isInternalFeedSet to true if this subscription is added for the sole purpose of providing currency conversion rates, setting this flag to true will prevent the data from being sent into the algorithm's OnData methods
isCustomTrue if this is user supplied custom data, false for normal QC data
tickTypeSpecifies if trade or quote data is subscribed
isFilteredSubscriptionTrue if this subscription should have filters applied to it (market hours/user filters from security), false otherwise
dataNormalizationModeSpecifies normalization mode used for this subscription
dataMappingModeThe contract mapping mode to use for the security
contractDepthOffsetThe continuous contract desired offset from the current front month. For example, 0 (default) will use the front month, 1 will use the back month contract
mappedConfigTrue if this is created as a mapped config. This is useful for continuous contract at live trading where we subscribe to the mapped symbol but want to preserve uniqueness

Definition at line 268 of file SubscriptionDataConfig.cs.

Member Function Documentation

◆ Equals() [1/2]

bool QuantConnect.Data.SubscriptionDataConfig.Equals ( SubscriptionDataConfig  other)

Indicates whether the current object is equal to another object of the same type.

Returns
true if the current object is equal to the other parameter; otherwise, false.
Parameters
otherAn object to compare with this object.

Definition at line 314 of file SubscriptionDataConfig.cs.

Here is the caller graph for this function:

◆ Equals() [2/2]

override bool QuantConnect.Data.SubscriptionDataConfig.Equals ( object  obj)

Determines whether the specified object is equal to the current object.

Returns
true if the specified object is equal to the current object; otherwise, false.
Parameters
objThe object to compare with the current object.

Definition at line 340 of file SubscriptionDataConfig.cs.

Here is the call graph for this function:

◆ GetHashCode()

override int QuantConnect.Data.SubscriptionDataConfig.GetHashCode ( )

Serves as the default hash function.

Returns
A hash code for the current object.

Definition at line 354 of file SubscriptionDataConfig.cs.

Here is the caller graph for this function:

◆ operator==()

static bool QuantConnect.Data.SubscriptionDataConfig.operator== ( SubscriptionDataConfig  left,
SubscriptionDataConfig  right 
)
static

Override equals operator

Definition at line 379 of file SubscriptionDataConfig.cs.

Here is the call graph for this function:

◆ operator!=()

static bool QuantConnect.Data.SubscriptionDataConfig.operator!= ( SubscriptionDataConfig  left,
SubscriptionDataConfig  right 
)
static

Override not equals operator

Definition at line 387 of file SubscriptionDataConfig.cs.

Here is the call graph for this function:

◆ ToString()

override string QuantConnect.Data.SubscriptionDataConfig.ToString ( )

Returns a string that represents the current object.

Returns
A string that represents the current object.

<filterpriority>2</filterpriority>

Definition at line 399 of file SubscriptionDataConfig.cs.

Here is the caller graph for this function:

Member Data Documentation

◆ SecurityType

SecurityType QuantConnect.Data.SubscriptionDataConfig.SecurityType => Symbol.SecurityType

Security type of this data subscription

Definition at line 47 of file SubscriptionDataConfig.cs.

◆ Market

string QuantConnect.Data.SubscriptionDataConfig.Market => Symbol.ID.Market

Gets the market / scope of the symbol

Definition at line 158 of file SubscriptionDataConfig.cs.

Property Documentation

◆ Type

Type QuantConnect.Data.SubscriptionDataConfig.Type
get

Type of data

Definition at line 42 of file SubscriptionDataConfig.cs.

◆ Symbol

Symbol QuantConnect.Data.SubscriptionDataConfig.Symbol
get

Symbol of the asset we're requesting: this is really a perm tick!!

Definition at line 52 of file SubscriptionDataConfig.cs.

◆ TickType

TickType QuantConnect.Data.SubscriptionDataConfig.TickType
get

Trade, quote or open interest data

Definition at line 57 of file SubscriptionDataConfig.cs.

◆ Resolution

Resolution QuantConnect.Data.SubscriptionDataConfig.Resolution
get

Resolution of the asset we're requesting, second minute or tick

Definition at line 62 of file SubscriptionDataConfig.cs.

◆ Increment

TimeSpan QuantConnect.Data.SubscriptionDataConfig.Increment
get

Timespan increment between triggers of this data:

Definition at line 67 of file SubscriptionDataConfig.cs.

◆ FillDataForward

bool QuantConnect.Data.SubscriptionDataConfig.FillDataForward
get

True if wish to send old data when time gaps in data feed.

Definition at line 72 of file SubscriptionDataConfig.cs.

◆ ExtendedMarketHours

bool QuantConnect.Data.SubscriptionDataConfig.ExtendedMarketHours
get

Boolean Send Data from between 4am - 8am (Equities Setting Only)

Definition at line 77 of file SubscriptionDataConfig.cs.

◆ IsInternalFeed

bool QuantConnect.Data.SubscriptionDataConfig.IsInternalFeed
get

True if this subscription was added for the sole purpose of providing currency conversion rates via CashBook.EnsureCurrencyDataFeeds

Definition at line 82 of file SubscriptionDataConfig.cs.

◆ IsCustomData

bool QuantConnect.Data.SubscriptionDataConfig.IsCustomData
get

True if this subscription is for custom user data, false for QC data

Definition at line 87 of file SubscriptionDataConfig.cs.

◆ SumOfDividends

decimal QuantConnect.Data.SubscriptionDataConfig.SumOfDividends
getset

The sum of dividends accrued in this subscription, used for scaling total return prices

Definition at line 92 of file SubscriptionDataConfig.cs.

◆ DataNormalizationMode

DataNormalizationMode QuantConnect.Data.SubscriptionDataConfig.DataNormalizationMode
getset

Gets the normalization mode used for this subscription

Definition at line 97 of file SubscriptionDataConfig.cs.

◆ DataMappingMode

DataMappingMode QuantConnect.Data.SubscriptionDataConfig.DataMappingMode
get

Gets the securities mapping mode used for this subscription

This is particular useful when generating continuous futures

Definition at line 103 of file SubscriptionDataConfig.cs.

◆ ContractDepthOffset

uint QuantConnect.Data.SubscriptionDataConfig.ContractDepthOffset
get

The continuous contract desired offset from the current front month. For example, 0 (default) will use the front month, 1 will use the back month contract

Definition at line 109 of file SubscriptionDataConfig.cs.

◆ PriceScaleFactor

decimal QuantConnect.Data.SubscriptionDataConfig.PriceScaleFactor
getset

Price Scaling Factor:

Definition at line 114 of file SubscriptionDataConfig.cs.

◆ MappedSymbol

string? QuantConnect.Data.SubscriptionDataConfig.MappedSymbol
getset

Symbol Mapping: When symbols change over time (e.g. CHASE-> JPM) need to update the symbol requested.

Definition at line 120 of file SubscriptionDataConfig.cs.

◆ DataTimeZone

DateTimeZone QuantConnect.Data.SubscriptionDataConfig.DataTimeZone
get

Gets the data time zone for this subscription

Definition at line 163 of file SubscriptionDataConfig.cs.

◆ ExchangeTimeZone

DateTimeZone QuantConnect.Data.SubscriptionDataConfig.ExchangeTimeZone
get

Gets the exchange time zone for this subscription

Definition at line 168 of file SubscriptionDataConfig.cs.

◆ Consolidators

ISet<IDataConsolidator> QuantConnect.Data.SubscriptionDataConfig.Consolidators
get

Consolidators that are registred with this subscription

Definition at line 173 of file SubscriptionDataConfig.cs.

◆ IsFilteredSubscription

bool QuantConnect.Data.SubscriptionDataConfig.IsFilteredSubscription
get

Gets whether or not this subscription should have filters applied to it (market hours/user filters from security)

Definition at line 178 of file SubscriptionDataConfig.cs.

Event Documentation

◆ NewSymbol

EventHandler<NewSymbolEventArgs> QuantConnect.Data.SubscriptionDataConfig.NewSymbol

Event fired when there is a new symbol due to mapping

Definition at line 37 of file SubscriptionDataConfig.cs.


The documentation for this class was generated from the following file: