33,584 questions
2387
votes
24
answers
584k
views
What are MVP and MVC and what is the difference?
When looking beyond the RAD (drag-drop and configure) way of building user interfaces that many tools encourage you are likely to come across three design patterns called Model-View-Controller, Model-...
1492
votes
26
answers
724k
views
What is the difference between MVC and MVVM?
Is there a difference between the standard "Model View Controller" pattern and Microsoft's Model/View/ViewModel pattern?
581
votes
5
answers
205k
views
How should a model be structured in MVC? [closed]
I am just getting a grasp on the MVC framework and I often wonder how much code should go in the model. I tend to have a data access class that has methods like this:
public function CheckUsername($...
460
votes
12
answers
472k
views
What is a Data Transfer Object (DTO)?
In MVC are the model classes DTO? If not, what are the differences and do we need both?
245
votes
6
answers
187k
views
What is difference between MVC, MVP & MVVM design pattern in terms of coding c#
If we search Google using the phrase "differences between MVC, MVP & MVVM design pattern" then we may get a few URL's which discuss the difference between MVC MVP & MVVM design ...
222
votes
9
answers
65k
views
Java / Jakarta EE web development, where do I start and what skills do I need? [closed]
I want to learn, at least at a basic level, how to build Java web applications (coming from a .NET background). I would like to be able to build, deploy a simple CMS type application from the ground ...
207
votes
6
answers
57k
views
Difference between Observer, Pub/Sub, and Data Binding
What is the difference between the Observer Pattern, Publish/Subscribe, and Data Binding?
I searched around a bit on Stack Overflow and did not find any good answers.
What I have come to believe is ...
199
votes
7
answers
111k
views
Add directives from directive in AngularJS
I'm trying to build a directive that takes care of adding more directives to the element it is declared on.
For example, I want to build a directive that takes care of adding datepicker, datepicker-...
193
votes
10
answers
386k
views
Spring Test & Security: How to mock authentication?
I was trying to figure out how to unit test if my the URLs of my controllers are properly secured. Just in case someone changes things around and accidentally removes security settings.
My ...
177
votes
13
answers
465k
views
Content type 'application/x-www-form-urlencoded;charset=UTF-8' not supported for @RequestBody MultiValueMap
Based on the answer for problem with x-www-form-urlencoded with Spring @Controller
I have written the below @Controller method
@RequestMapping(value = "/{email}/authenticate", method = ...
156
votes
10
answers
46k
views
Rails Model, View, Controller, and Helper: what goes where?
In Ruby on Rails Development (or MVC in general), what quick rule should I follow as to where to put logic.
Please answer in the affirmative - With Do put this here, rather than Don't put that there.
151
votes
12
answers
96k
views
MVC Vs n-tier architecture
I was wondering what exactly is the difference between MVC(which is an architectural pattern) and an n-tier architecture for an application. I searched for it but couldn't find a simple explanation. ...
134
votes
30
answers
73k
views
Is there a JavaScript MVC (micro-)framework? [closed]
Are there any client-side JavaScript MVC (micro-)frameworks?
I have a rather complicated HTML form, and it would benefit from the MVC pattern.
I imagine a good solution would provide the following:
...
134
votes
2
answers
50k
views
GUI not working after rewriting to MVC
I'm practicing MVC style programming. I have a Mastermind game in a single file, working fine (maybe apart of the fact that "Check" button is invisible at start).
http://paste.pocoo.org/show/226726/
...
131
votes
7
answers
134k
views
Unable to set data attribute using jQuery Data() API
I've got the following field on an MVC view:
@Html.TextBoxFor(model => model.Course.Title, new { data_helptext = "Old Text" })</span>
In a seperate js file, I want to set the data-helptext ...
121
votes
7
answers
84k
views
What is the difference between an MVC Model object, a domain object and a DTO
What is the difference between a MVC Model object, a domain object, and a DTO?
My understanding is:
MVC Model object:
Models the data to be displayed by a corresponding view. It may not map directly ...
110
votes
3
answers
49k
views
Fat models and skinny controllers sounds like creating God models
I've been reading a lot of blogs which advocate the fat models and skinny controllers approach, esp. the Rails camp. As a result the routers is basically just figuring out what method to call on what ...
102
votes
4
answers
44k
views
What components are MVC in JSF MVC framework?
In JSF MVC framework who is Model, View, and Controller?
99
votes
8
answers
191k
views
How to pass parameters to a partial view in ASP.NET MVC?
Suppose that I have this partial view:
Your name is <strong>@firstName @lastName</strong>
which is accessible through a child only action like:
[ChildActionOnly]
public ActionResult ...
98
votes
3
answers
108k
views
MVCS - Model View Controller Service
I've been using MVC for a long time and heard about the "Service" layer (for example in Java web project) and I've been wondering if that is a real architectural pattern given I can't find a lot of ...
93
votes
4
answers
29k
views
Fat model / thin controller vs. Service layer [closed]
I have been developing enterprise applications for many years using .Net
My apps usually have a domain model containing entities mapping to SQL DB tables.
I use a Repository pattern, Dependency ...
92
votes
6
answers
119k
views
Angular design pattern: MVC, MVVM or MV*?
Angular 1.x (AngularJS) was following more or less the MV* design principle because of its two-way data binding functionality.
Angular2 is adopting a component-based UI, a concept that might be ...
87
votes
4
answers
80k
views
Differentiating between domain, model, and entity with respect to MVC
Can someone explain these 3 concepts and the differences between them with respect to an MVC framework along with an example. To me these appear almost equivalent, and it seems they are used ...
87
votes
4
answers
28k
views
Where does the "business logic layer" fit in to an MVC application?
First, before anyone screams dupe, I had a hard time summarizing it in a simple title. Another title might have been "What is the difference between a domain model and MVC model?" or "What is a model?...
85
votes
11
answers
49k
views
Are the roles of a service and a façade similar?
The more I read, the more confused I am.
Note that all the question is related to how service and facades fit on the MVC pattern.
My understanding is that a Facade is not a super-smart object, it ...