Share via


IActionResultExecutor<TResult> Interface

Definition

Defines an interface for a service which can execute a particular kind of IActionResult by manipulating the HttpResponse.

generic <typename TResult>
 where TResult : IActionResultpublic interface class IActionResultExecutor
public interface IActionResultExecutor<in TResult> where TResult : IActionResult
type IActionResultExecutor<'Result (requires 'Result :> IActionResult)> = interface
Public Interface IActionResultExecutor(Of In TResult)

Type Parameters

TResult

The type of IActionResult.

This type parameter is contravariant. That is, you can use either the type you specified or any type that is less derived. For more information about covariance and contravariance, see Covariance and Contravariance in Generics.
Derived

Remarks

Implementations of IActionResultExecutor<TResult> are typically called by the ExecuteResultAsync(ActionContext) method of the corresponding action result type. Implementations should be registered as singleton services.

Methods

ExecuteAsync(ActionContext, TResult)

Asynchronously executes the action result, by modifying the HttpResponse.

Applies to