LeanDataPathComponents
QuantConnect.Util.LeanDataPathComponents
LeanDataPathComponents(
security_type: SecurityType,
market: str,
resolution: Resolution,
symbol: Union[Symbol, str, BaseContract],
filename: str,
date: Union[datetime, date],
tick_type: TickType,
)
Bases: Object
Type representing the various pieces of information emebedded into a lean data file path
Initializes a new instance of the LeanDataPathComponents class
date
date: datetime
Gets the date component from the file name
market
market: str
Gets the market from the path
filename
filename: str
Gets the file name, not inluding directory information
symbol
symbol: Symbol
Gets the symbol object implied by the path. For options, or any multi-entry zip file, this should be the canonical symbol
parse
parse(path: str) -> LeanDataPathComponents
Parses the specified path into a new instance of the LeanDataPathComponents class
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
The path to be parsed |
required |
Returns:
| Type | Description |
|---|---|
LeanDataPathComponents
|
A new instance of the LeanDataPathComponents class representing the specified path. |