F# Data


TextRuntime

Namespace: FSharp.Data.Runtime

Static helper methods called from the generated code for working with text

Record Fields

Record FieldDescription
cultureInfoCache
Signature: Dictionary<string,CultureInfo>
Modifiers: mutable static
Attributes:
[<ThreadStatic>]
[<DefaultValue>]

Static members

Static memberDescription
TextRuntime.AsyncMap(...)
Signature: (valueAsync:Async<'T> * mapping:Func<'T,'R>) -> Async<'R>
Type parameters: 'T, 'R

Turn a sync operation into an async operation

TextRuntime.ConvertBoolean(text)
Signature: (text:string option) -> bool option
TextRuntime.ConvertBooleanBack(...)
Signature: (value:bool option * use0and1:bool) -> string
TextRuntime.ConvertDateTime(...)
Signature: (cultureStr:string * text:string option) -> DateTime option
TextRuntime.ConvertDateTimeBack(...)
Signature: (cultureStr:string * value:DateTime option) -> string
TextRuntime.ConvertDateTimeOffset(...)
Signature: (cultureStr:string * text:string option) -> DateTimeOffset option
TextRuntime.ConvertDateTimeOffsetBack(...)
Signature: (cultureStr:string * value:DateTimeOffset option) -> string
TextRuntime.ConvertDecimal(...)
Signature: (cultureStr:string * text:string option) -> decimal option
TextRuntime.ConvertDecimalBack(...)
Signature: (cultureStr:string * value:decimal option) -> string
TextRuntime.ConvertFloat(...)
Signature: (cultureStr:string * missingValuesStr:string * text:string option) -> float option
TextRuntime.ConvertFloatBack(...)
Signature: (cultureStr:string * missingValuesStr:string * value:float option) -> string
TextRuntime.ConvertGuid(text)
Signature: (text:string option) -> Guid option
TextRuntime.ConvertGuidBack(value)
Signature: (value:Guid option) -> string
TextRuntime.ConvertInteger(...)
Signature: (cultureStr:string * text:string option) -> int option
TextRuntime.ConvertInteger64(...)
Signature: (cultureStr:string * text:string option) -> int64 option
TextRuntime.ConvertInteger64Back(...)
Signature: (cultureStr:string * value:int64 option) -> string
TextRuntime.ConvertIntegerBack(...)
Signature: (cultureStr:string * value:int option) -> string
TextRuntime.ConvertString(text)
Signature: (text:string option) -> string option
TextRuntime.ConvertStringBack(value)
Signature: (value:string option) -> string
TextRuntime.ConvertTimeSpan(...)
Signature: (cultureStr:string * text:string option) -> TimeSpan option
TextRuntime.ConvertTimeSpanBack(...)
Signature: (cultureStr:string * value:TimeSpan option) -> string
TextRuntime.GetCulture(cultureStr)
Signature: cultureStr:string -> CultureInfo

Returns CultureInfo matching the specified culture string (or InvariantCulture if the argument is null or empty)

TextRuntime.GetMissingValues(...)
Signature: missingValuesStr:string -> string []
TextRuntime.GetNonOptionalValue(...)
Signature: (name:string * opt:'T option * originalValue:string option) -> 'T
Type parameters: 'T

Operation that extracts the value from an option and reports a meaningful error message when the value is not there For missing strings we return "", and for missing doubles we return NaN For other types an error is thrown

TextRuntime.NullableToOption(nullable)
Signature: nullable:Nullable<'?8576> -> '?8576 option
Type parameters: '?8576

Turn a .NET type Nullable<'T> to an F# option type Option<'T>

TextRuntime.OptionToNullable(opt)
Signature: (opt:'?8574 option) -> Nullable<'?8574>
Type parameters: '?8574

Turn an F# option type Option<'T> containing a primitive value type into a .NET type Nullable<'T>

Fork me on GitHub