public static InterceptorCollection AddServiced(this InterceptorCollection interceptorCollection, Type interceptorType, params AspectPredicate[] predicates)
 {
     if (interceptorCollection == null)
     {
         throw new ArgumentNullException(nameof(interceptorCollection));
     }
     interceptorCollection.Add(new ServiceInterceptorFactory(interceptorType, predicates));
     return(interceptorCollection);
 }
        public static InterceptorCollection AddDelegate(this InterceptorCollection interceptorCollection, Func <AspectDelegate, AspectDelegate> aspectDelegate, int order, params AspectPredicate[] predicates)
        {
            if (interceptorCollection == null)
            {
                throw new ArgumentNullException(nameof(interceptorCollection));
            }

            interceptorCollection.Add(new DelegateInterceptorFactory(aspectDelegate, order, predicates));

            return(interceptorCollection);
        }
 public static InterceptorCollection AddTyped(this InterceptorCollection interceptorCollection, Type interceptorType, object[] args, params AspectPredicate[] predicates)
 {
     if (interceptorCollection == null)
     {
         throw new ArgumentNullException(nameof(interceptorCollection));
     }
     if (predicates == null)
     {
         throw new ArgumentNullException(nameof(predicates));
     }
     if (interceptorType == null)
     {
         throw new ArgumentNullException(nameof(interceptorType));
     }
     interceptorCollection.Add(new TypeInterceptorFactory(interceptorType, args, predicates));
     return(interceptorCollection);
 }