Example #1
0
 public static void AppendQuery(this RequestUriBuilder builder, string name, byte[] value, bool escape = true)
 {
     builder.AppendQuery(name, Convert.ToBase64String(value), escape);
 }
Example #2
0
 public static void AppendQuery(this RequestUriBuilder builder, string name, Guid value, bool escape = true)
 {
     builder.AppendQuery(name, value.ToString(), escape);
 }
Example #3
0
 public static void AppendQuery(this RequestUriBuilder builder, string name, int value, bool escape = true)
 {
     builder.AppendQuery(name, value.ToString(TypeFormatters.DefaultNumberFormat, CultureInfo.InvariantCulture), escape);
 }
Example #4
0
 public static void AppendQuery(this RequestUriBuilder builder, string name, TimeSpan value, bool escape = true)
 {
     builder.AppendQuery(name, XmlConvert.ToString(value), escape);
 }
Example #5
0
 public static void AppendQuery(this RequestUriBuilder builder, string name, bool value, bool escape = false)
 {
     builder.AppendQuery(name, TypeFormatters.ToString(value), escape);
 }
Example #6
0
 public static void AppendQuery(this RequestUriBuilder builder, string name, TimeSpan value, string format, bool escape = true)
 {
     builder.AppendQuery(name, TypeFormatters.ToString(value, format), escape);
 }
Example #7
0
 public static void AppendPath(this RequestUriBuilder builder, DateTimeOffset value, string format, bool escape = true)
 {
     builder.AppendPath(TypeFormatters.ToString(value, format), escape);
 }
Example #8
0
 public static void AppendPath(this RequestUriBuilder builder, Guid value, bool escape = true)
 {
     builder.AppendPath(value.ToString(), escape);
 }
Example #9
0
 public static void AppendPath(this RequestUriBuilder builder, IEnumerable <string> value, bool escape = true)
 {
     builder.AppendPath(string.Join(",", value), escape);
 }
Example #10
0
 public static void AppendPath(this RequestUriBuilder builder, byte[] value, bool escape = true)
 {
     builder.AppendPath(TypeFormatters.ToBase64UrlString(value), escape);
 }
Example #11
0
 public static void AppendPath(this RequestUriBuilder builder, double value, bool escape = true)
 {
     builder.AppendPath(value.ToString(TypeFormatters.DefaultNumberFormat, CultureInfo.InvariantCulture), escape);
 }
Example #12
0
 public static void AppendPath(this RequestUriBuilder builder, bool value, bool escape = false)
 {
     builder.AppendPath(TypeFormatters.ToString(value), escape);
 }
Example #13
0
 public static void AppendQueryDelimited <T>(this RequestUriBuilder builder, string name, IEnumerable <T> value, string delimiter, bool escape = true)
 {
     builder.AppendQuery(name, string.Join(delimiter, value), escape);
 }