Owneat Technical Guide main Help

Class DeleteIngredientCommandHandler

Namespace: Restaurant.Application.Requests.Ingredient
Assembly: Restaurant.Application.dll

public sealed class DeleteIngredientCommandHandler : IRequestHandler<DeleteIngredientCommand, Result<Unit>>

Inheritance

object ← DeleteIngredientCommandHandler

Implements

IRequestHandler<DeleteIngredientCommand, Result<Unit\>\>

Inherited Members

object.Equals\(object?\), object.Equals\(object?, object?\), object.GetHashCode\(\), object.GetType\(\), object.ReferenceEquals\(object?, object?\), object.ToString\(\)

Constructors

DeleteIngredientCommandHandler\(IIngredientRepository, IUnitOfWork\)

public DeleteIngredientCommandHandler(IIngredientRepository ingredientRepository, IUnitOfWork unitOfWork)

Parameters

ingredientRepository IIngredientRepository

unitOfWork IUnitOfWork

Methods

Handle\(DeleteIngredientCommand, CancellationToken\)

Handles a request

public Task<Result<Unit>> Handle(DeleteIngredientCommand request, CancellationToken cancellationToken)

Parameters

request DeleteIngredientCommand

The request

cancellationToken CancellationToken

Cancellation token

Returns

Task <Result<Unit\>\>

Response from the request

Last modified: 21 May 2024