public static Either <TLeft, long> ParseToLong <TLeft>( this Either <TLeft, string> source, NumberStyles style, TLeft left) { return(source.FlatMap(x => LongParser.Parse <TLeft>(x, style, left))); }
public static Either <TLeft, long> ParseToLong <TLeft>( this Either <TLeft, string> source, IFormatProvider provider, TLeft left) { return(source.FlatMap(x => LongParser.Parse <TLeft>(x, provider, left))); }
public static Either <TLeft, long> ParseToLong <TLeft>( this string source, NumberStyles style, IFormatProvider provider, TLeft left) { return(LongParser.Parse <TLeft>(source, style, provider, left)); }
public async Task <ClashDelayResponse> GetClashProxyDelay(string name, int timeout = 5000, string testUrl = "http://www.gstatic.com/generate_204") { string url = string.Format(API_PROXIES_DELAY, Uri.EscapeDataString(name)); var dict = new Dictionary <string, dynamic>(); dict.Add("timeout", Convert.ToString(timeout)); dict.Add("url", testUrl); var result = await GetAsync <ClashDelayResponse>(url, dict); result.DelayLong = LongParser.Parse(result.Delay); return(result); }
public static Maybe <long> ParseToLong(this string source) { return(LongParser.Parse(source)); }
public static Maybe <long> ParseToLong(this Maybe <string> source, NumberStyles style, IFormatProvider provider) { return(source.FlatMap(x => LongParser.Parse(x, style, provider))); }
public static Maybe <long> ParseToLong(this Maybe <string> source, NumberStyles style) { return(source.FlatMap(x => LongParser.Parse(x, style))); }
public static Maybe <long> ParseToLong(this string source, NumberStyles style, IFormatProvider provider) { return(LongParser.Parse(source, style, provider)); }
public static Maybe <long> ParseToLong(this string source, NumberStyles style) { return(LongParser.Parse(source, style)); }
public static Either <TLeft, long> ParseToLong <TLeft>(this string source, TLeft left) { return(LongParser.Parse(source, left)); }