Esempio n. 1
0
        protected override void RegisterTypes(ICodeBrixContainer container)
        {
            container.RegisterForNavigation <MainPage>();
            container.RegisterForNavigation <TabA, TabViewModel>();
            container.RegisterForNavigation <TabB, TabViewModel>();
            container.RegisterForNavigation <TabC, TabViewModel>();

            container.RegisterSingleton(new ApplicationCommands(), typeof(IApplicationCommands));
        }
Esempio n. 2
0
 public static void RegisterModule <T>(this ICodeBrixContainer container, ICodeBrixModuleInfo <T> moduleInfo) where T : ICodeBrixModule
 {
     container.RegisterSingleton(new ObjectFactory(moduleInfo.ModuleType, true, moduleInfo.Settings), moduleInfo.ModuleType, moduleInfo.ModuleName);
     (container as CodeBrixContainer)?.ModuleCatalog?.AddModule(moduleInfo.ModuleInfo);
 }