Click here to Skip to main content
15,917,645 members
Home / Discussions / Design and Architecture
   

Design and Architecture

 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
Pete O'Hanlon26-Feb-15 10:16
mvePete O'Hanlon26-Feb-15 10:16 
Questionwriting an IDS in python Pin
orphansec21-Feb-15 15:09
orphansec21-Feb-15 15:09 
AnswerRe: writing an IDS in python Pin
jschell23-Feb-15 10:15
jschell23-Feb-15 10:15 
GeneralRe: writing an IDS in python Pin
orphansec23-Feb-15 11:28
orphansec23-Feb-15 11:28 
GeneralRe: writing an IDS in python Pin
jschell26-Feb-15 9:37
jschell26-Feb-15 9:37 
AnswerRe: writing an IDS in python Pin
Richard MacCutchan23-Feb-15 21:39
mveRichard MacCutchan23-Feb-15 21:39 
Questionthe "right place" for data-binding in Model-View paradigms (MVC, MVP, MVVM) ? Pin
BillWoodruff16-Feb-15 1:24
professionalBillWoodruff16-Feb-15 1:24 
AnswerRe: the "right place" for data-binding in Model-View paradigms (MVC, MVP, MVVM) ? Pin
manchanx18-Feb-15 2:53
professionalmanchanx18-Feb-15 2:53 
I'm not quite sure if this is what you're asking for, but here I go.

I'm using MVP with WinForms (my experience with other flavors of MVxx isn't worth mentioning). My way of implementing it:

The Presenter is the only thing that knows about the other two. It subs to events from View and Model, calls methods on them and can read their properties. It contains the state of the View, the logic to manipulate it and synchronizes between Model and View - but it does no processing of the data whatsoever.

The Model can take different shapes: It can be a rather dumb data container, potentially already filled via constructor arguments. Or it can contain the code to pull data from the various sources and potentially transform it. Or it can be an adapter to a non-primitive business object (e.g. some kind of workflow). In the latter two cases it may hold the session of the ORM.

So either the Presenter "knows" that the data is already present on instantiation or it waits for some "data available"-event from the Model, which may be the result of a previous user request -> View fires event -> Presenter calls Model. The Presenter then hands the data to the View by calling methods on the View that take the data as arguments and either bind it or "just display" it (e.g. setting Label.Text = x).

Does this help?

- Sebastian
GeneralRe: the "right place" for data-binding in Model-View paradigms (MVC, MVP, MVVM) ? Pin
BillWoodruff20-Feb-15 12:40
professionalBillWoodruff20-Feb-15 12:40 
AnswerRe: the "right place" for data-binding in Model-View paradigms (MVC, MVP, MVVM) ? Pin
Mycroft Holmes23-Feb-15 13:36
professionalMycroft Holmes23-Feb-15 13:36 
QuestionLooking for the best way to setting user Profile Pin
yetrus13-Feb-15 5:48
yetrus13-Feb-15 5:48 
AnswerRe: Looking for the best way to setting user Profile Pin
BillWoodruff15-Feb-15 22:35
professionalBillWoodruff15-Feb-15 22:35 
Questiongeneral advice on starting to work with DB programming ? Pin
BillWoodruff11-Feb-15 1:11
professionalBillWoodruff11-Feb-15 1:11 
AnswerRe: general advice on starting to work with DB programming ? Pin
cjb11011-Feb-15 6:59
cjb11011-Feb-15 6:59 
GeneralRe: general advice on starting to work with DB programming ? Pin
BillWoodruff14-Feb-15 11:26
professionalBillWoodruff14-Feb-15 11:26 
AnswerRe: general advice on starting to work with DB programming ? Pin
jschell12-Feb-15 11:17
jschell12-Feb-15 11:17 
GeneralRe: general advice on starting to work with DB programming ? Pin
BillWoodruff14-Feb-15 11:27
professionalBillWoodruff14-Feb-15 11:27 
GeneralRe: general advice on starting to work with DB programming ? Pin
jschell20-Feb-15 13:36
jschell20-Feb-15 13:36 
AnswerRe: general advice on starting to work with DB programming ? Pin
manchanx12-Feb-15 13:19
professionalmanchanx12-Feb-15 13:19 
GeneralRe: general advice on starting to work with DB programming ? Pin
BillWoodruff14-Feb-15 11:28
professionalBillWoodruff14-Feb-15 11:28 
AnswerRe: general advice on starting to work with DB programming ? Pin
Jörgen Andersson12-Feb-15 21:43
professionalJörgen Andersson12-Feb-15 21:43 
GeneralRe: general advice on starting to work with DB programming ? Pin
BillWoodruff14-Feb-15 12:42
professionalBillWoodruff14-Feb-15 12:42 
GeneralRe: general advice on starting to work with DB programming ? Pin
Jörgen Andersson15-Feb-15 10:51
professionalJörgen Andersson15-Feb-15 10:51 
GeneralRe: general advice on starting to work with DB programming ? Pin
BillWoodruff15-Feb-15 22:25
professionalBillWoodruff15-Feb-15 22:25 
QuestionBetter language for complex GUI and input/output devices? Pin
ai_mc9-Feb-15 14:38
ai_mc9-Feb-15 14:38 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.