LifecycleManagersRegistry ofFactoryRegistry = new LifecycleManagersRegistry();
ofFactoryRegistry.addFactoryFactory(new ScopeLifecycleManager<Object>());
ProvidersRegistry providersRegistry =
new ProvidersRegistry(ofFactoryRegistry, new ApplicationValidator());
Set<Class<?>> classes = new ApplicationFileLoader(true).getClasses();
if (classes != null) {
for (Class<?> cls : classes) {
if (ProviderMetadataCollector.isProvider(cls)) {
providersRegistry.addProvider(cls);
}