/// <summary> /// Sets the User-Agent header of the request to the specified comment. /// </summary> /// <param name="comment">The Upgrade header comment.</param> /// <returns>An <see cref="IRequest"/> object that represents the request.</returns> public static IRequest UserAgent(this IWith @this, string comment) => @this.UserAgent(new ProductInfoHeaderValue(comment));
/// <summary> /// Sets the User-Agent header of the request to the specified product name and product version. /// </summary> /// <param name="productName">The Upgrade header product name.</param> /// <param name="productVersion">The Upgrade header product version.</param> /// <returns>An <see cref="IRequest"/> object that represents the request.</returns> public static IRequest UserAgent(this IWith @this, string productName, string productVersion) => @this.UserAgent(new ProductInfoHeaderValue(productName, productVersion));
/// <summary> /// Sets the User-Agent header of the request to the specified product. /// </summary> /// <param name="product">The Upgrade header product.</param> /// <returns>An <see cref="IRequest"/> object that represents the request.</returns> public static IRequest UserAgent(this IWith @this, ProductHeaderValue product) => @this.UserAgent(new ProductInfoHeaderValue(product));