private LifecycleInjector run ( Module externalModule , final String [ ] args ) { return InjectorBuilder . fromModules ( modules ) . combineWith ( externalModule ) . map ( new ModuleTransformer ( ) { @ Override public Module transform ( Module module ) { List < Module > modulesToTransform = Collections . singletonList ( module ) ; for ( ModuleListTransformer transformer : transformers ) { modulesToTransform = transformer . transform ( Collections . unmodifiableList ( modulesToTransform ) ) ; } return Modules . combine ( modulesToTransform ) ; } } ) . overrideWith ( overrideModules ) . createInjector ( new LifecycleInjectorCreator ( ) . withArguments ( args ) . withFeatures ( featureOverrides ) . withProfiles ( profiles ) ) ; }
Create the injector and call any LifecycleListeners