예제 #1
0
        public bool IsAccessibleToUser(IControllerTypeResolver controllerTypeResolver, DefaultSiteMapProvider provider, HttpContext context, SiteMapNode node)
        {
            Ensure.ThatTypeFor(() => node).IsOfType<MvcSiteMapNode>();

            HttpContextBase contextBase = context.Wrap();
            MvcSiteMapNode mvc = (MvcSiteMapNode)node;
            string controller = mvc.Controller;
            string action = mvc.Action;

            bool accessible = IsActionAccessibleToUser(controllerTypeResolver, contextBase, controller, action);
            return accessible;
        }