コード例 #1
0
        public static IDisposable RequireScope(this IWindsorContainer container)
        {
            var current = Scope.ObtainCurrentScope();

            if (current == null)
            {
                return(container.BeginScope());
            }
            return(null);
        }
コード例 #2
0
        public static IDisposable RequireScope(this IKernel kernel)
        {
            var current = Scope.ObtainCurrentScope();

            if (current == null)
            {
                return(kernel.BeginScope());
            }
            return(null);
        }