public static RestClient Build(Action <IClientSettingsBuilder> builder) { var settings = new ClientSettingsBuilder(); builder(settings); return(new RestClient(settings.Build())); }
public static IRestClient AsRestClient(this IHttpClient client, Action <IClientSettingsBuilder> settings, IBuildContext context) { var builder = new ClientSettingsBuilder(); settings(builder); return(client.AsRestClient(builder.Build(context))); }