Commit Graph

8 Commits

Author SHA1 Message Date
jacalvar 5246125cb7 [Fixes #4087] Add AddViewComponentsAsServices() and ServiceBasedViewComponentActivator
* Added ViewComponentFeture and ViewComponentFeatureProvider to perform view component discovery.
* Changed view component discovery to use application parts.
* Changed ViewComponentDescriptorProvider to make use of Application parts.
* Added AddViewComponentsAsServices method on IMvcBuilder that performs view component
  discovery through the ApplicationPartManager and registers those view components as
  services in the service collection. Assemblies should be added to the ApplicationPartManager
  in order to discover view components in them in them.
2016-04-01 10:55:04 -07:00
jacalvar 0d0aad41f5 [Fixes #4014] Add overload to AddControllerAsServices that uses the default controller discovery logic.
* Added ControllerFeature and ControllerFeatureProvider to perform controller discovery.
* Changed controller discovery to use application parts.
* Changed ControllerActionDescriptorProvider to make use of Application parts.
* Simplified AddControllerAsServices to not accept any parameter and perform
  controller discovery through the ApplicationPartManager in the IMvcBuilder
  and IMvcCoreBuilder. Assemblies should be added to the ApplicationPartManager
  in order to discover controllers in them.
2016-04-01 09:29:37 -07:00
jacalvar de9ffb13c7 [Fixes #3732] Simplify controller discovery.
* Introduce ControllerAttribute and use it to mark base classes as controllers.
* Changed rules for controller discovery to:
  * All controller types must be public, concrete, non open generic types.
  * NotController attribute is not applied to any type oif the hierarchy.
  * The type name ends with controller.
  * Controller attribute is applied to the type or to one of its ancestors.
2016-03-31 10:50:26 -07:00
Doug Bunting 6bf25cecec React to HttpAbstractions namespace changes
- aspnet/HttpAbstractions#549 and aspnet/HttpAbstractions#592
- clean up `using`s
2016-03-30 16:19:42 -07:00
Ajay Bhargav Baaskaran 8c4bcf14c7 Added caching for validators 2016-01-26 17:15:16 -08:00
jacalvar 2b0bea675e [Fixes #3752] Cleanup Controller invocation pipeline
* Added a Release method to IControllerActivator
* Changed Create in IControllerActivator to take in a ControllerActionContext
* Move the check to determine if a controller can be instantiated into the controller activator.
* Move logic for disposing controllers into the controller activator and make release on the
  controller factory delegate into the activator.
* Changed release methods to take in a controller context.
2016-01-26 14:15:03 -08:00
N. Taylor Mullen 3be7fbdf9f Rename AspNet 5 file contents.
See https://github.com/aspnet/Announcements/issues/144 for more information.
2016-01-22 12:18:33 -08:00
N. Taylor Mullen 6a6c8ca544 Rename AspNet 5 folders and files.
See https://github.com/aspnet/Announcements/issues/144 for more information.
2016-01-22 12:17:07 -08:00