Hi people,
I would like to use a custom interface in my project for the pattern IRequest/IRequestHandler.
Currently my classes inherit from MediatR interfaces like this:
class DisableBlogCommand : IRequest { }
class DisableBlogCommandHandler : IRequestHandler<DisableBlogCommand> { }
I was wondering if is possible to use something this way without inheriting from MediatR:
class DisableBlogCommand : ICommand { }
class DisableBlogCommandHandler : ICommandHandler<DisableBlogCommand> { }
class DisableBlogDomainEvent : IDomainEvent { }
class DisableBlogCommandHandler : IDomainEventHandler<DisableBlogDomainEvent> { }
Yeah you can just copy the code and make up your own interfaces really.
On Thu, Oct 5, 2017 at 7:45 PM Ivan Paulovich notifications@github.com
wrote:
Hi people,
I would like to use a custom interface in my project for the pattern
IRequest/IRequestHandler.
Currently my classes inherit from MediatR interfaces like this:class DisableBlogCommand : IRequest { }
class DisableBlogCommandHandler : IRequestHandler{ } I was wondering if is possible to use something this way without
inheriting from MediatR:class DisableBlogCommand : ICommand { }
class DisableBlogCommandHandler : ICommandHandler{ }
class DisableBlogDomainEvent : IDomainEvent { }
class DisableBlogCommandHandler : IDomainEventHandler{ } —
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/jbogard/MediatR/issues/198, or mute the thread
https://github.com/notifications/unsubscribe-auth/AAGYMj8VgwnVkXiJBn6_IRSNi_BR0yMIks5spXgdgaJpZM4Pv4W2
.
Thank you @jbogard!