Castle.Facilities.WcfIntegration.Proxy.WcfInterceptorSelector.SplitInterceptors C# (CSharp) Method

SplitInterceptors() private static method

private static SplitInterceptors ( IInterceptor interceptors, MethodInfo method, List &infrastructureInterceptors, List &userInterceptors ) : void
interceptors IInterceptor
method MethodInfo
infrastructureInterceptors List
userInterceptors List
return void
		private static void SplitInterceptors(IInterceptor[] interceptors, MethodInfo method,
											  out List<IInterceptor> infrastructureInterceptors,
											  out List<IInterceptor> userInterceptors)
		{
			userInterceptors = new List<IInterceptor>(interceptors.Length);
			infrastructureInterceptors = new List<IInterceptor>(interceptors.Length);

			foreach (var interceptor in interceptors)
			{
				if (interceptor is IWcfInterceptor)
				{
					var infrastructureInterceptor = (IWcfInterceptor)interceptor;
					if (infrastructureInterceptor.Handles(method))
					{
						infrastructureInterceptors.Add(infrastructureInterceptor);
					}
					continue;
				}
				userInterceptors.Add(interceptor);
			}
		}