public ValidationResult Validate(AddGenericEntityCommand <TEntity, TIdentifier> instance) { return(Validate(instance?.Data)); }
public async Task <ValidationResult> ValidateAsync(AddGenericEntityCommand <TEntity, TIdentifier> instance, CancellationToken cancellation = default) { return(await ValidateAsync(instance?.Data, cancellation)); }
public async Task <AddGenericEntityCommandResponse <TIdentifier> > Handle(AddGenericEntityCommand <TEntity, TIdentifier> request, CancellationToken cancellationToken) { _logger.LogInformation("AddGenericEntityCommand: {data}", request.Data); return(new AddGenericEntityCommandResponse <TIdentifier>(request.Data.Id)); }