protected override object GetInstance(Type service, string key) { //NOTE: initialize the assembly (module) if (service != null) { ModuleConventions.InitializeAssembly(service.Assembly); } return(container.GetInstance(service, key)); }
protected override void Configure() { container = new PhoneContainer(); container.RegisterPhoneServices(RootFrame); container.Singleton <IMessageService, MessageService>(); //NOTE: don't register anything from the module assemblies here container.PerRequest <MainPageViewModel>(); //NOTE: install the conventions ModuleConventions.Install(); }
protected override IEnumerable <object> GetAllInstances(Type service) { //NOTE: initialize the assembly (module) ModuleConventions.InitializeAssembly(service.Assembly); return(container.GetAllInstances(service)); }