ReqRest
Show / Hide Table of Contents

Class HttpMethodBuilderExtensions

Defines the static methods for an IHttpMethodBuilder provided by the library.

Inheritance
Object
HttpMethodBuilderExtensions
Namespace: ReqRest.Builders
Assembly: ReqRest.dll
Syntax
public static class HttpMethodBuilderExtensions

Methods

Delete<T>(T)

Sets the HttpMethod to the HTTP DELETE method.

Declaration
public static T Delete<T>(this T builder)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder

Get<T>(T)

Sets the HttpMethod to the HTTP GET method.

Declaration
public static T Get<T>(this T builder)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder

Head<T>(T)

Sets the HttpMethod to the HTTP HEAD method.

Declaration
public static T Head<T>(this T builder)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder

Options<T>(T)

Sets the HttpMethod to the HTTP OPTIONS method.

Declaration
public static T Options<T>(this T builder)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder

Patch<T>(T)

Sets the HttpMethod to the HTTP PATCH method.

Declaration
public static T Patch<T>(this T builder)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder

Post<T>(T)

Sets the HttpMethod to the HTTP POST method.

Declaration
public static T Post<T>(this T builder)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder

Put<T>(T)

Sets the HttpMethod to the HTTP PUT method.

Declaration
public static T Put<T>(this T builder)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder

SetMethod<T>(T, HttpMethod)

Sets the HttpMethod which is being built.

Declaration
public static T SetMethod<T>(this T builder, HttpMethod method)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

HttpMethod method

The HTTP method used by the HTTP request message.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder
  • method

SetMethod<T>(T, String)

Sets the HttpMethod which is being built.

Declaration
public static T SetMethod<T>(this T builder, string method)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

String method

A string from which an HttpMethod can be created.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder
  • method

Trace<T>(T)

Sets the HttpMethod to the HTTP TRACE method.

Declaration
public static T Trace<T>(this T builder)
    where T : IHttpMethodBuilder
Parameters
Type Name Description
T builder

The builder.

Returns
Type Description
T

The specified builder.

Type Parameters
Name Description
T

The type of the builder.

Exceptions
Type Condition
ArgumentNullException
  • builder
Back to top Copyright © 2019 ReqRest - Generated with DocFX - Material Theme made by Oscar Vásquez - Impressum (Imprint)