using Valg.EVA.Skanning.ContainerExtensions;
using Unity;

namespace Valg.EVA.Skanning.Scan.Api
{
    public class UnityInstaller : IUnityInstaller
    {
        public void Install(IUnityContainer unityContainer)
        {
            unityContainer.RegisterType<ScannedFormMapper>(ContainerLifetimes.CreateContainerControlledLifetimeManager());
            unityContainer.RegisterType<IFieldValueAssignerFactory, FieldValueAssignerFactory>(ContainerLifetimes.CreateContainerControlledLifetimeManager());
            unityContainer.RegisterType<RecoverableReadsoftErrorsDispatcher>(ContainerLifetimes.CreateContainerControlledLifetimeManager());
        }
    }
}
