public CommandDefinitionService( ILogger <CommandDefinitionService> logger, ILoadedTypes loadedTypes) : base(logger) { var commandTypes = loadedTypes .TypesLoaded .Where(t => typeof(ICommand).GetTypeInfo().IsAssignableFrom(t)); Load(commandTypes.ToArray()); }
public JobDefinitionService( ILogger <JobDefinitionService> logger, ILoadedTypes loadedTypes) : base(logger) { var jobTypes = loadedTypes .TypesLoaded .Where(t => typeof(IJob).GetTypeInfo().IsAssignableFrom(t)); Load(jobTypes.ToArray()); }
public EventDefinitionService( ILogger <EventDefinitionService> logger, ILoadedTypes loadedTypes) : base(logger) { var eventTypes = loadedTypes .TypesLoaded .Where(t => typeof(IAggregateEvent).GetTypeInfo().IsAssignableFrom(t)); Load(eventTypes.ToArray()); }