示例#1
0
 public ValidationResult Validate(AddGenericEntityCommand <TEntity, TIdentifier> instance)
 {
     return(Validate(instance?.Data));
 }
示例#2
0
 public async Task <ValidationResult> ValidateAsync(AddGenericEntityCommand <TEntity, TIdentifier> instance, CancellationToken cancellation = default)
 {
     return(await ValidateAsync(instance?.Data, cancellation));
 }
示例#3
0
 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));
 }