I have a set of repositories in a class lib that are required to be singletons. They share library with other classes as well - classes created as singletons.
Is it possible to configure Ninject to automatically use InSingletonScope() for all classes that are matching a specific criteria - for example, defined in a specific namespace?
I have between 20 and 30 repositories and from what I have found, I need to call InSingletonScope() for every repository.
I can - of course - do this by reflection, but I'm interested to know if there is an "automatic approach" to this :)