Ejemplo n.º 1
0
        protected ConditionalProcessManagerConfiguration <TState> IfIn(TState conditionalState)
        {
            var filteredByPermittedStateEvents = _aggregatedEvents.Where(x => x.PermittedState.Equals(conditionalState)).ToList();
            var processManagerConfiguration    = new ProcessManagerConfiguration <TState>
            {
                ConditionalAction = () => _conditionalAction(conditionalState),
                PermittedState    = conditionalState
            };

            return(new ConditionalProcessManagerConfiguration <TState>(processManagerConfiguration, this, filteredByPermittedStateEvents));
        }
Ejemplo n.º 2
0
 public ConditionalProcessManagerConfiguration(ProcessManagerConfiguration <TState> processManagerConfiguration, ProcessManager <TState> originProcessManager, IReadOnlyCollection <AggregatedEvent <TState> > aggregatedEvents)
 {
     _processManagerConfiguration = processManagerConfiguration;
     _originProcessManager        = originProcessManager;
     _aggregatedEvents            = aggregatedEvents;
 }
 public TransitionalProcessManagerConfiguration(ProcessManagerConfiguration <TState> processManagerConfiguration, ProcessManager <TState> originProcessManager)
 {
     _processManagerConfiguration = processManagerConfiguration;
     _originProcessManager        = originProcessManager;
 }