protected override void AttachToComponentRegistration(
     IComponentRegistry componentRegistry,
     IComponentRegistration registration)
 {
     if (DynamicProxyContext.From(registration) != null)
     {
         registration.InterceptedBy <SimpleInterceptor>();
     }
 }
Пример #2
0
        protected override void AttachToComponentRegistration(IComponentRegistry componentRegistry, IComponentRegistration registration)
        {
            Type implementationType = registration.Activator.LimitType;

            if (DynamicProxyContext.From(registration) != null && implementationType.FullName == "Orchard.Car.Services.CarInfoService")
            {
                registration.InterceptedBy <SimpleInterceptor>();
            }
        }