OptionChainProvider (Class)
The OptionChainsProvider (OCP) class provides access to a collection of options for an underlying asset. The collection that is returned includes options that satisfy the criteria established in the OCP properties. Monthly options are automatically added to the OptionChainProvider’s Data when the OptionChainProvider is loaded. Quarterly and weekly options are loaded only if the IncludeWeekly and/or IncludeQuarterly properties are set to true prior to loading the OptionChainProvider.
For general information about providers, refer to Provider Classes.
Namespace: tsdata.marketdata
Properties
Additional
properties, methods, and events are described in the classes listed
under Inheritance Hierarchy (see below).
Name | Type | Description | |
![]() |
Data | object | Gets the OptionChain collection object. |
![]() |
Expirations | int | Gets or sets the number of future expiration dates to be returned. |
![]() |
Fields | list | Specifies one or more fields to be retrieved for all options. An updated event will be triggered for each change of the specified fields. Note that this may have the undesirable effect of creating a high volume of updates if a large number of options are referenced. |
![]() |
IncludeNonStandard | bool | True to include non-standard options in the option chain. |
![]() |
IncludeQuarterly | bool | True to include quarterly options in the option chain. |
![]() |
IncludeRegionals | bool | True to include regional options in the option chain. |
![]() |
IncludeWeekly | bool | True to include weekly options in the option chain. |
![]() |
Option[index] | object | Gets the OptionSecurity collection with the specified index. |
![]() |
OptionsCount | int | Gets the total number of options retrieved in the provider's collection. |
![]() |
Strikes | int | Gets or sets the number of strike prices on each side of the current underlying price to be returned. |
![]() |
Underlying | object | Gets the MarketSecurity object of the underlying security. |
![]() |
UnderlyingSymbol | string | Gets or sets the symbol of the underlying security. |
![]() |
UnderlyingType | enum | Gets or sets the type of the underlying security. See SecurityType for a list of possible values. |
Methods
Name | Description | |
![]() |
Create() | Initializes a new instance of provider. |
![]() |
FindOption(type,date,strike) | Finds and returns an OptionSecurity object for a specific option in the option chain data retrieved based on the type, date, and strike parameters. Throws an Argument 'index' in call to method 'Option' if not found. |
![]() |
FindOption(type,date,strike,region) | Finds and returns an OptionSecurity object for a specific option in the option chain data retrieved based on the type, date, strike, and region parameters. Throws an Argument 'index' in call to method 'Option' if not found. |
Events
Name | Description | |
![]() |
Updated | Occurs whenever an OptionChain in the provider collection is updated. See OptionChainUpdatedEventArgs for the properties returned by the handler's args parameter. |
Inheritance Hierarchy
tsdata.marketdata.OptionChainProvider