using System.Collections.Generic;
using Tapeti.Config;
using Tapeti.Flow.Default;
namespace Tapeti.Flow
{
///
///
/// Provides the Flow middleware.
///
public class FlowExtension : ITapetiExtension
{
private readonly IFlowRepository flowRepository;
///
///
public FlowExtension(IFlowRepository flowRepository)
{
this.flowRepository = flowRepository;
}
///
public void RegisterDefaults(IDependencyContainer container)
{
container.RegisterDefault();
container.RegisterDefault();
container.RegisterDefault();
container.RegisterDefaultSingleton(() => flowRepository ?? new NonPersistentFlowRepository());
container.RegisterDefaultSingleton();
}
///
public IEnumerable