AddDispatcher Method
Definition
AddDispatcher<TDispatcher, TImplementation>()
Adds a dispatcher of type TDispatcher to DispatcherServiceTypes (if not already registered) and DispatcherImplementationTypes (if not already registered).
public SavvyioOptions AddDispatcher<TDispatcher, TImplementation>() where TDispatcher : IDispatcher where TImplementation : class, TDispatcher
Returns
- SavvyioOptions
A reference to this instance so that additional configuration calls can be chained.
Type Parameters
TDispatcherThe type of the IDispatcher interface to add.
TImplementationThe type of the implementation to use.
AddDispatcher(Type, Type)
Adds a dispatcher of type IDispatcher to DispatcherServiceTypes (if not already registered) and DispatcherImplementationTypes (if not already registered).
public SavvyioOptions AddDispatcher(Type service, Type implementation)
Parameters
serviceTypeThe Type of the IDispatcher interface to add.
implementationTypeThe type of the implementation to use.
Returns
- SavvyioOptions
A reference to this instance so that additional configuration calls can be chained.