public CompetitionWorkflow(Competition competition, IStateMachineFactory <Competition, ECompetitionState, ECompetitionEvent> stateMachineFactory, IStateMachineConfigurator <Competition, ECompetitionState, ECompetitionEvent> stateMachineConfigurator) : base(competition, stateMachineFactory, stateMachineConfigurator) { }
public StatelessWorkflowProvider(IStateMachineFactory <TObject, TState, TEvent> stateMachineFactory, IStateMachineConfigurator <TObject, TState, TEvent> stateMachineConfigurator) { if (stateMachineFactory == null) { throw new ArgumentNullException(nameof(stateMachineFactory)); } if (stateMachineConfigurator == null) { throw new ArgumentNullException(nameof(stateMachineConfigurator)); } StateMachineFactory = stateMachineFactory; StateMachineConfigurator = stateMachineConfigurator; }
protected StatelessWorkflow(TObject @object, IStateMachineFactory <TObject, TState, TEvent> stateMachineFactory, IStateMachineConfigurator <TObject, TState, TEvent> stateMachineConfigurator) { if (@object == null) { throw new ArgumentNullException(nameof(@object)); } if (stateMachineFactory == null) { throw new ArgumentNullException(nameof(stateMachineFactory)); } if (stateMachineConfigurator == null) { throw new ArgumentNullException(nameof(stateMachineConfigurator)); } _stateMachineFactory = stateMachineFactory; _stateMachineConfigurator = stateMachineConfigurator; Object = @object; }
// NOTE: Inject Competition repository etc public CompetitionWorkflowProvider(IStateMachineFactory <Competition, ECompetitionState, ECompetitionEvent> stateMachineFactory, IStateMachineConfigurator <Competition, ECompetitionState, ECompetitionEvent> stateMachineConfigurator) : base(stateMachineFactory, stateMachineConfigurator) { }