I was using WindsorControllerFactory from mvccontrib.castle lib until now, after i migrated to mvc 2 it doesn't work anymore, I've downloaded the latest mvccontrib release and no factories in there
Controller factory is responsible for handling the incoming request and mapping it to specific controller. Here is how it works: In this figure, I tried to explain where the role exists of controller factory. By default, ASP.NET MVC uses DefaultControllerFactory class for creating controller after receiving request from Route Handler.
The custom controller factory is no longer necessary if you update your ASP.NET MVC project to use .NET Framework 4.5 or later and simply add this NuGet package to it. It will automatically add a static class called UnityMvcActivator with everything required.
The controller class we use in our MVC application is derived from Controller ( abstract) class which implements ControllerBase, IActionFilter, IAuthorizationFilter, IDisposable, IExceptionFilter and IResultFilter . With the help of the above mentioned interfaces and ControllerBase class, the Controller class helps to create a controller easily.
You need to download MVCContrib.Extras.release.zip. It has the controller factories and the rest of the stuff.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With