Lean  $LEAN_TAG$
QuantConnect.Securities.Option.OptionSymbol Class Reference

Static class contains common utility methods specific to symbols representing the option contracts More...

Static Public Member Functions

static bool IsStandardContract (Symbol symbol)
 Returns true if the option is a standard contract that expires 3rd Friday of the month More...
 
static bool IsStandard (Symbol symbol)
 Returns true if the option is a standard contract that expires 3rd Friday of the month More...
 
static bool IsWeekly (Symbol symbol)
 Returns true if the option is a weekly contract that expires on Friday , except 3rd Friday of the month More...
 
static string MapToUnderlying (string optionTicker, SecurityType securityType)
 Maps the option ticker to it's underlying More...
 
static DateTime GetLastDayOfTrading (Symbol symbol)
 Returns the last trading date for the option contract More...
 
static bool IsOptionContractExpired (Symbol symbol, DateTime currentTimeUtc)
 Returns true if the option contract is expired at the specified time More...
 

Detailed Description

Static class contains common utility methods specific to symbols representing the option contracts

Definition at line 26 of file OptionSymbol.cs.

Member Function Documentation

◆ IsStandardContract()

static bool QuantConnect.Securities.Option.OptionSymbol.IsStandardContract ( Symbol  symbol)
static

Returns true if the option is a standard contract that expires 3rd Friday of the month

Parameters
symbolOption symbol
Returns

Definition at line 35 of file OptionSymbol.cs.

Here is the call graph for this function:

◆ IsStandard()

static bool QuantConnect.Securities.Option.OptionSymbol.IsStandard ( Symbol  symbol)
static

Returns true if the option is a standard contract that expires 3rd Friday of the month

Parameters
symbolOption symbol
Returns

Definition at line 45 of file OptionSymbol.cs.

Here is the caller graph for this function:

◆ IsWeekly()

static bool QuantConnect.Securities.Option.OptionSymbol.IsWeekly ( Symbol  symbol)
static

Returns true if the option is a weekly contract that expires on Friday , except 3rd Friday of the month

Parameters
symbolOption symbol
Returns

Definition at line 65 of file OptionSymbol.cs.

Here is the call graph for this function:

◆ MapToUnderlying()

static string QuantConnect.Securities.Option.OptionSymbol.MapToUnderlying ( string  optionTicker,
SecurityType  securityType 
)
static

Maps the option ticker to it's underlying

Parameters
optionTickerThe option ticker to map
securityTypeThe security type of the option or underlying
Returns
The underlying ticker

Definition at line 76 of file OptionSymbol.cs.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetLastDayOfTrading()

static DateTime QuantConnect.Securities.Option.OptionSymbol.GetLastDayOfTrading ( Symbol  symbol)
static

Returns the last trading date for the option contract

Parameters
symbolOption symbol
Returns

Definition at line 95 of file OptionSymbol.cs.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ IsOptionContractExpired()

static bool QuantConnect.Securities.Option.OptionSymbol.IsOptionContractExpired ( Symbol  symbol,
DateTime  currentTimeUtc 
)
static

Returns true if the option contract is expired at the specified time

Parameters
symbolThe option contract symbol
currentTimeUtcThe current time (UTC)
Returns
True if the option contract is expired at the specified time, false otherwise

Definition at line 129 of file OptionSymbol.cs.

Here is the call graph for this function:

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