Lean  $LEAN_TAG$
QuantConnect.Parse Class Reference

Provides methods for parsing strings using CultureInfo.InvariantCulture More...

Static Public Member Functions

static TimeSpan TimeSpan (string value)
 Parses the provided value as a System.TimeSpan using System.TimeSpan.Parse(string,IFormatProvider) with CultureInfo.InvariantCulture More...
 
static bool TryParse (string input, out TimeSpan value)
 Tries to parse the provided value with TryParse as a System.TimeSpan using CultureInfo.InvariantCulture. More...
 
static bool TryParseExact (string input, string format, TimeSpanStyles timeSpanStyle, out TimeSpan value)
 Tries to parse the provided value with TryParse as a System.TimeSpan, format string, TimeSpanStyles, and using CultureInfo.InvariantCulture More...
 
static DateTime DateTime (string value)
 Parses the provided value as a System.DateTime using System.DateTime.Parse(string,IFormatProvider) with CultureInfo.InvariantCulture More...
 
static DateTime DateTimeExact (string value, string format)
 Parses the provided value as a System.DateTime using System.DateTime.ParseExact(string,string,IFormatProvider) with the specified format and CultureInfo.InvariantCulture More...
 
static DateTime DateTimeExact (string value, string format, DateTimeStyles dateTimeStyles)
 Parses the provided value as a System.DateTime using System.DateTime.ParseExact(string,string,IFormatProvider) with the specified format , dateTimeStyles and CultureInfo.InvariantCulture More...
 
static bool TryParse (string input, DateTimeStyles dateTimeStyle, out System.DateTime value)
 Tries to parse the provided value with TryParse as a System.DateTime using the specified dateTimeStyle and CultureInfo.InvariantCulture. More...
 
static bool TryParseExact (string input, string format, DateTimeStyles dateTimeStyle, out System.DateTime value)
 Tries to parse the provided value with TryParse as a System.DateTime using the specified dateTimeStyle , the format format , and CultureInfo.InvariantCulture. More...
 
static double Double (string value)
 Parses the provided value as a double using CultureInfo.InvariantCulture More...
 
static bool TryParse (string input, NumberStyles numberStyle, out double value)
 Tries to parse the provided value with TryParse as a double using the specified numberStyle and CultureInfo.InvariantCulture. More...
 
static decimal Decimal (string value)
 Parses the provided value as a decimal using CultureInfo.InvariantCulture More...
 
static decimal Decimal (string value, NumberStyles numberStyles)
 Parses the provided value as a decimal using the specified numberStyles and CultureInfo.InvariantCulture More...
 
static bool TryParse (string input, NumberStyles numberStyle, out decimal value)
 Tries to parse the provided value with TryParse as a decimal using the specified numberStyle and CultureInfo.InvariantCulture. More...
 
static int Int (string value)
 Parses the provided value as a int using CultureInfo.InvariantCulture More...
 
static bool TryParse (string input, NumberStyles numberStyle, out int value)
 Tries to parse the provided value with TryParse as a int using the specified numberStyle and CultureInfo.InvariantCulture. More...
 
static long Long (string value)
 Parses the provided value as a long using CultureInfo.InvariantCulture More...
 
static long Long (string value, NumberStyles numberStyles)
 Parses the provided value as a long using CultureInfo.InvariantCulture and the specified numberStyles More...
 
static bool TryParse (string input, NumberStyles numberStyle, out long value)
 Tries to parse the provided value with TryParse as a long using the specified numberStyle and CultureInfo.InvariantCulture. More...
 
static T Enum< T > (string input, bool ignoreCase=true)
 Parses the provided value as a an enumeration type T More...
 
static bool TryParse< T > (string input, out T value, bool ignoreCase=true)
 Parses the provided value as a an enumeration type T More...
 

Detailed Description

Provides methods for parsing strings using CultureInfo.InvariantCulture

Definition at line 24 of file Parse.cs.

Member Function Documentation

◆ TimeSpan()

static TimeSpan QuantConnect.Parse.TimeSpan ( string  value)
static

Parses the provided value as a System.TimeSpan using System.TimeSpan.Parse(string,IFormatProvider) with CultureInfo.InvariantCulture

Definition at line 30 of file Parse.cs.

◆ TryParse() [1/6]

static bool QuantConnect.Parse.TryParse ( string  input,
out TimeSpan  value 
)
static

Tries to parse the provided value with TryParse as a System.TimeSpan using CultureInfo.InvariantCulture.

Definition at line 38 of file Parse.cs.

Here is the caller graph for this function:

◆ TryParseExact() [1/2]

static bool QuantConnect.Parse.TryParseExact ( string  input,
string  format,
TimeSpanStyles  timeSpanStyle,
out TimeSpan  value 
)
static

Tries to parse the provided value with TryParse as a System.TimeSpan, format string, TimeSpanStyles, and using CultureInfo.InvariantCulture

Parameters
input
format
timeSpanStyle
value
Returns

Definition at line 53 of file Parse.cs.

Here is the caller graph for this function:

◆ DateTime()

static DateTime QuantConnect.Parse.DateTime ( string  value)
static

Parses the provided value as a System.DateTime using System.DateTime.Parse(string,IFormatProvider) with CultureInfo.InvariantCulture

Definition at line 62 of file Parse.cs.

◆ DateTimeExact() [1/2]

static DateTime QuantConnect.Parse.DateTimeExact ( string  value,
string  format 
)
static

Parses the provided value as a System.DateTime using System.DateTime.ParseExact(string,string,IFormatProvider) with the specified format and CultureInfo.InvariantCulture

Definition at line 71 of file Parse.cs.

Here is the caller graph for this function:

◆ DateTimeExact() [2/2]

static DateTime QuantConnect.Parse.DateTimeExact ( string  value,
string  format,
DateTimeStyles  dateTimeStyles 
)
static

Parses the provided value as a System.DateTime using System.DateTime.ParseExact(string,string,IFormatProvider) with the specified format , dateTimeStyles and CultureInfo.InvariantCulture

Definition at line 80 of file Parse.cs.

◆ TryParse() [2/6]

static bool QuantConnect.Parse.TryParse ( string  input,
DateTimeStyles  dateTimeStyle,
out System.DateTime  value 
)
static

Tries to parse the provided value with TryParse as a System.DateTime using the specified dateTimeStyle and CultureInfo.InvariantCulture.

Definition at line 89 of file Parse.cs.

◆ TryParseExact() [2/2]

static bool QuantConnect.Parse.TryParseExact ( string  input,
string  format,
DateTimeStyles  dateTimeStyle,
out System.DateTime  value 
)
static

Tries to parse the provided value with TryParse as a System.DateTime using the specified dateTimeStyle , the format format , and CultureInfo.InvariantCulture.

Definition at line 99 of file Parse.cs.

◆ Double()

static double QuantConnect.Parse.Double ( string  value)
static

Parses the provided value as a double using CultureInfo.InvariantCulture

Definition at line 107 of file Parse.cs.

◆ TryParse() [3/6]

static bool QuantConnect.Parse.TryParse ( string  input,
NumberStyles  numberStyle,
out double  value 
)
static

Tries to parse the provided value with TryParse as a double using the specified numberStyle and CultureInfo.InvariantCulture.

Definition at line 116 of file Parse.cs.

◆ Decimal() [1/2]

static decimal QuantConnect.Parse.Decimal ( string  value)
static

Parses the provided value as a decimal using CultureInfo.InvariantCulture

Definition at line 124 of file Parse.cs.

Here is the caller graph for this function:

◆ Decimal() [2/2]

static decimal QuantConnect.Parse.Decimal ( string  value,
NumberStyles  numberStyles 
)
static

Parses the provided value as a decimal using the specified numberStyles and CultureInfo.InvariantCulture

Definition at line 133 of file Parse.cs.

◆ TryParse() [4/6]

static bool QuantConnect.Parse.TryParse ( string  input,
NumberStyles  numberStyle,
out decimal  value 
)
static

Tries to parse the provided value with TryParse as a decimal using the specified numberStyle and CultureInfo.InvariantCulture.

Definition at line 142 of file Parse.cs.

◆ Int()

static int QuantConnect.Parse.Int ( string  value)
static

Parses the provided value as a int using CultureInfo.InvariantCulture

Definition at line 150 of file Parse.cs.

Here is the caller graph for this function:

◆ TryParse() [5/6]

static bool QuantConnect.Parse.TryParse ( string  input,
NumberStyles  numberStyle,
out int  value 
)
static

Tries to parse the provided value with TryParse as a int using the specified numberStyle and CultureInfo.InvariantCulture.

Definition at line 159 of file Parse.cs.

◆ Long() [1/2]

static long QuantConnect.Parse.Long ( string  value)
static

Parses the provided value as a long using CultureInfo.InvariantCulture

Definition at line 167 of file Parse.cs.

Here is the caller graph for this function:

◆ Long() [2/2]

static long QuantConnect.Parse.Long ( string  value,
NumberStyles  numberStyles 
)
static

Parses the provided value as a long using CultureInfo.InvariantCulture and the specified numberStyles

Definition at line 176 of file Parse.cs.

◆ TryParse() [6/6]

static bool QuantConnect.Parse.TryParse ( string  input,
NumberStyles  numberStyle,
out long  value 
)
static

Tries to parse the provided value with TryParse as a long using the specified numberStyle and CultureInfo.InvariantCulture.

Definition at line 185 of file Parse.cs.

◆ Enum< T >()

static T QuantConnect.Parse.Enum< T > ( string  input,
bool  ignoreCase = true 
)
static

Parses the provided value as a an enumeration type T

Type Constraints
T :struct 
T :IConvertible 

Definition at line 193 of file Parse.cs.

Here is the call graph for this function:

◆ TryParse< T >()

static bool QuantConnect.Parse.TryParse< T > ( string  input,
out T  value,
bool  ignoreCase = true 
)
static

Parses the provided value as a an enumeration type T

Type Constraints
T :struct 
T :IConvertible 

Definition at line 208 of file Parse.cs.


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