// Copyright (C) 2020 White Sharx (https://whitesharx.com) - All Rights Reserved. // Unauthorized copying of this file, via any medium is strictly prohibited. // Proprietary and confidential. // using System.Collections.Generic; using System.Linq; using Httx.Requests.Extensions; namespace Httx.Requests.Types { public class Json
: BaseRequest { public Json(string url, TBody body = default) : base(null) { Url = url; if (typeof(TBody) == typeof(byte[])) { Body = (byte[])(object)body; } else { Body = Equals(body, default(TBody)) ? default : this.ResolveBodyMapper(Context.Instance).AsBody(body); } } public override string Url { get; } public override IEnumerable