Method ParseOneOrTwoOrFourFloats
ParseOneOrTwoOrFourFloats(string?, IFormatProvider?)
Parses string with 1, 2 or 4 float values separated by the comma character or other separator. All whitespaces and brackets are trimmed before parsing is done. Null is returned if error occurs during parsing or number of parsed floats is different from 1, 2 or 4.
public static float[]? ParseOneOrTwoOrFourFloats(string? s, IFormatProvider? formatProvider = null)
Parameters
s
stringString to parse.
formatProvider
IFormatProviderOptional IFormatProvider with string format settings. If not specified, InvariantEnglishUS is used.
Returns
- float[]