struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dave Newton <davelnew...@gmail.com>
Subject Re: OT: Architectural Semantics: Model View Presenter
Date Tue, 08 Apr 2014 17:42:32 GMT
IMO the real differences are who decides what view (C in MVC, e.g., an S2
result), and what preps data for the view (C in MVC, one or more Ps in
MVP). Some people use things like the S2 "<action>" tags to provide some
multiple-P-like functionality but I'm pretty "meh" on that usage.

Personally the differences generally boil down to either some trivial
push/pull of functionality or simple definitions, although there's probably
a bit more to it than that.

Dave



On Tue, Apr 8, 2014 at 1:31 PM, Ken McWilliams <ken.mcwilliams@gmail.com>wrote:

> Marked as OT because this more of a conceptual issue and has to do with
> talking to .NET developers regarding framework difference than with
> framework use.
>
> I'm trying to wrap my head around the Model View Pattern (MVP) pattern. My
> issue is that I can't really differentiate it from what I do in Struts2.
> But in no documentation is there any claim that Struts2 follows MVP. Also
> it seems to be a term that only shows up mainly in Microsoft circles, is it
> a sort of branding?
>
> Given the Wikipedia article:
> http://en.wikipedia.org/wiki/Model%E2%80%93view%E2%80%93presenter
>
> There is a picture at the top of the wiki article that shows the following:
>
> ----
> Model Business Objects <=> Presenter Contains the logic for application <=>
> View UI Components Has no notion of the model.
> ----
>
> This looks a lot like, the pattern most of us take for Struts2, where the
> middle part, the presenter, is replaced by the Struts2 action.
>
> The main difference is that this is less of an abstraction than found in
> most JEE applications, as the chain is typically: Data tier objects <=>
> service tier objects <=> struts2 action <=> view.
>
> I'm supposing that this extra level, isn't required for the MVP pattern and
> so omitted to focus on the pattern and not perhaps would be done in best
> practice.
>
> So is then is Struts2 following MVP (in most cases)? I've read that wiki
> article twice and still don't see a difference. Any light on the matter
> would be most welcome.
>
> On the other hand if there isn't a difference, we should add Struts2 to the
> list of MVP frameworks at the bottom!
>
> Regards,
> Ken
>



-- 
e: davelnewton@gmail.com
m: 908-380-8699
s: davelnewton_skype
t: @dave_newton <https://twitter.com/dave_newton>
b: Bucky Bits <http://buckybits.blogspot.com/>
g: davelnewton <https://github.com/davelnewton>
so: Dave Newton <http://stackoverflow.com/users/438992/dave-newton>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message