I'm new to Autofac (3) and am using it to find a number of classes in several assemblies that implement IRecognizer.
So I have:
builder.RegisterAssemblyTypes(AppDomain.CurrentDomain.GetAssemblies()).As<IRecognizer>();
which is fine.
But I'd like to inject references to the found components into a constructor - sort of:
public Detector(List<IRecognizer> recognizers)
{
this.Recognizers = recognizers;
}
Is there any way to do this?