Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9050551
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T12:40:47+00:00 2026-06-16T12:40:47+00:00

Is there any MVC framework around that applies POCO concept to controllers ? Example:

  • 0

Is there any MVC framework around that applies POCO concept to controllers ?

Example:
Suppose I don’t want to make my controller dependent on any web framework, in the way that I don’t need to inherit from framework Controller class anymore.
Instead, I want to just specify routes with some rules, describing how to map requests to methods and parameters of my POCO controller class instance.

Maybe little example below can explain it better.
Imagine we can have routing like this:

routes.MapPOCOController<MyPOCO>("MyWebAppName/{method}/{*parameters}", () => _container.Resolve<MyPOCO>());
routes.IfMethodReturns<MyCustomRedirectResult>().PerformRedirect(result => result.Url);

and then your controller class is just a POCO object:

public class MyPOCO {
    public User     GetUser(Guid userId) {...}
    public string   Home() { 
        return _razorEngine.Render("~/Views/Home/Index.cshtml", new HomeModel { Message = "Hello world!"});
    }
    public object   RenderSomePageOrRedirect()
    {
        if(blabla)
            return new MyCustomRedirectResult("/profile");
        else
            return _razorEngine.Render( ... );
    }
    ...
}
  • In first method “GetUser” JSON serialization could happen automagically like in mvc4.
  • In second method “Home” we need to render our views manually as a string, so this would give you more flexibility, like combining different engines or writing a custom one in much more natural way than it happens in current asp.mvc implementation.
  • In third method “RenderSomePageOrRedirect” we are not tight to current RedirectResult implementation and can use whatever class that works, and then map it properly in routes.

Is there any framework around that already implemented at least one of the mentioned concepts ? … maybe some “contrib” library?

The reasons why I’m looking for such functionality are:

  • I want to follow DRY principle and don’t want to mix request/response mapping code with the business logic in the controller (you can’t do both with current mvc implementations that I’m aware of)
  • I want to make my controller classes usable in multiple contexts, so, it’s easier for unit-testing, for reusing and so on. (code becomes more DRY when you reusing same controllers in different web applications: you simply need to adjust routes a bit)
  • It’s just a gut feeling that this way of doing things is better, sorry, my words renderer gives up (

PS: my appreciation to people (StriplingWarrior especially) who commented below and helped me to form this question properly!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T12:40:48+00:00Added an answer on June 16, 2026 at 12:40 pm

    Actually there is FubuMvc . It seems to be pretty much what you’re looking for. The only problem is scarce documentation.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Question: Are there any Mvc framework solutions that I can leverage to create a
I have a question that really applies to any MVC framework, I'm using the
Is there any order or pattern that action parameters in an MVC controller follow.
Are there any libraries that support JSTL style coding in an ASP MVC view?
I would like to know are there any Java (MVC) framework for non-web application
I have been playing around with the concept of 'module' that some mvc frameworks
Is there any reason to use Spring MVC (or other similar frameworks) as a
Are there any good examples of mvc routing wherein every 404 page not found
Is there any way to render ASP.net MVC controls or code directly within a
Is there any freeware library (controls) for ASP MVC implementing posting and displaying comments?

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.