Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

Please excuse me as I am a bit new to the following technologies and practices. I have been given the task to create a management suite utilizing an MDI GUI. This suite will be the front end to a WCF data service. My question is, what design pattern is typically used by most professionals when designing such an application. At the moment, I have been looking into both MVC and 3-tier design patterns.

If the MVC route tends to be taken, I'm assuming that because the WCF service is added as a service reference which provides visibility to all it's classes, the model part of MVC is pretty much covered? Would it make sense to generate an interface from the WCF class?

If the 3-tier pattern is used, would it make sense to create datalayer objects for every visible WCF class (ex. PropertyDAL), and on top of that, business layer objects for each datalayer object? If this is the case, with there being over 114 classes which would be made visible, this would mean 228 additional classes which seems a bit bloated to me and not necessary.

Here is the link to the usage of MVC design pattern which has lead me to my question.

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

This is an enormous question, people have written whole books on this. I will therefore attempt to keep my answer brief.

Comparing MVC to three-tier is like comparing apples to oranges. Quite simply they have totally different usages.

MVC is a presentation pattern. It will help you design your UI, but not really any further. It has the concept of a "model" which nicely abstracts things like physical data reads, physical data writes, business rules and all bar the simplest of validation.

A three-tier approach however is a higher level pattern which covers the whole of your system. You have the concept of presentation, business and data services. So you need to think about how you build these three services, and furthermore how they talk to each other.

Interestingly, MVC and Three Tier can easily coexist. If you imagine a three-tiered system, theres absolutely nothing to stop you writing your presentation services using MVC.

share|improve this answer
    
Thank you @PeteH for your answer. I have included a link in my question above which is what leads me to include MVC as a design pattern option. –  James Shaw May 3 '13 at 17:34
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.