Share via


RouteHandlerBuilder Class

Definition

Builds conventions that will be used for customization of MapAction EndpointBuilder instances.

public sealed class RouteHandlerBuilder : Microsoft.AspNetCore.Builder.IEndpointConventionBuilder
type RouteHandlerBuilder = class
    interface IEndpointConventionBuilder
Public NotInheritable Class RouteHandlerBuilder
Implements IEndpointConventionBuilder
Inheritance
RouteHandlerBuilder
Implements

Constructors

Name Description
RouteHandlerBuilder(IEnumerable<IEndpointConventionBuilder>)

Instantiates a new RouteHandlerBuilder given multiple IEndpointConventionBuilder instances.

Methods

Name Description
Add(Action<EndpointBuilder>)

Adds the specified convention to the builder. Conventions are used to customize EndpointBuilder instances.

Finally(Action<EndpointBuilder>)

Registers the specified convention for execution after conventions registered via Add(Action<EndpointBuilder>)

Extension Methods

Name Description
Accepts(RouteHandlerBuilder, Type, Boolean, String, String[])

Adds IAcceptsMetadata to Metadata for all endpoints produced by builder.

Accepts(RouteHandlerBuilder, Type, String, String[])

Adds IAcceptsMetadata to Metadata for all endpoints produced by builder.

Accepts<TRequest>(RouteHandlerBuilder, Boolean, String, String[])

Adds IAcceptsMetadata to Metadata for all endpoints produced by builder.

Accepts<TRequest>(RouteHandlerBuilder, String, String[])

Adds IAcceptsMetadata to Metadata for all endpoints produced by builder.

AddEndpointFilter<TFilterType>(RouteHandlerBuilder)

Registers a filter of type TFilterType onto the route handler.

DisableRequestTimeout(IEndpointConventionBuilder)

Disables request timeout on the endpoint(s).

ExcludeFromDescription(RouteHandlerBuilder)

Adds the IExcludeFromDescriptionMetadata to Metadata for all endpoints produced by builder.

Produces(RouteHandlerBuilder, Int32, Type, String, String[])

Adds an IProducesResponseTypeMetadata to Metadata for all endpoints produced by builder.

Produces<TResponse>(RouteHandlerBuilder, Int32, String, String[])

Adds an IProducesResponseTypeMetadata to Metadata for all endpoints produced by builder.

ProducesProblem(RouteHandlerBuilder, Int32, String)

Adds an IProducesResponseTypeMetadata with a ProblemDetails type to Metadata for all endpoints produced by builder.

ProducesValidationProblem(RouteHandlerBuilder, Int32, String)

Adds an IProducesResponseTypeMetadata with a HttpValidationProblemDetails type to Metadata for all endpoints produced by builder.

ShortCircuit(IEndpointConventionBuilder, Nullable<Int32>)

Short circuit the endpoint(s). The execution of the endpoint will happen in UseRouting middleware instead of UseEndpoint.

WithRequestTimeout(IEndpointConventionBuilder, RequestTimeoutPolicy)

Specifies a timeout policy for to the endpoint(s).

WithRequestTimeout(IEndpointConventionBuilder, String)

Specifies a timeout policy for to the endpoint(s).

WithRequestTimeout(IEndpointConventionBuilder, TimeSpan)

Specifies a timeout for the endpoint(s).

WithTags(RouteHandlerBuilder, String[])

Adds the ITagsMetadata to Metadata for all endpoints produced by builder.

Applies to