This commit is contained in:
454313500@qq.com
2021-03-23 14:29:21 +08:00
parent ea8dd04c8c
commit 06c32afa03

16
test.cs
View File

@@ -1,16 +0,0 @@
using System;
namespace CC.Yi.API
{
public class Startup
{
//动态 面向AOP思想的依赖注入 Autofac
public void ConfigureContainer(ContainerBuilder builder)
{
builder.RegisterType(typeof(CustomAutofacAop));
builder.RegisterGeneric(typeof(BaseDal<>)).As(typeof(IBaseDal<>));
builder.RegisterType<studentBll>().As<IstudentBll>().EnableInterfaceInterceptors();//表示注入前后要执行CastleAOP
}
}
}