Example #1
0
        public ControllerActionDescriptorProvider(
            ApplicationPartManager partManager,
            ApplicationModelFactory applicationModelFactory)
        {
            if (partManager == null)
            {
                throw new ArgumentNullException(nameof(partManager));
            }

            if (applicationModelFactory == null)
            {
                throw new ArgumentNullException(nameof(applicationModelFactory));
            }

            _partManager             = partManager;
            _applicationModelFactory = applicationModelFactory;
        }
 public static IList <ControllerActionDescriptor> Build(ApplicationModel application)
 {
     return(ApplicationModelFactory.Flatten(application, CreateActionDescriptor));
 }