コード例 #1
0
        static void Main(string[] args)
        {
            IocHelper.Register <ClassA, IClassA>();
            //IocHelper.Register(new ClassB());

            IocHelper.RegisterAssembly(Assembly.GetExecutingAssembly());

            IClassA ca = IocHelper.Resolve <IClassA>();
            ClassB  cb = IocHelper.Resolve <ClassB>();
        }
コード例 #2
0
        public void OnApplicationStarted(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext)
        {
            IocHelper.Register();

            RegisterDemoSection(applicationContext);
        }