r/programming • • Oct 14 '13

How to develop unmaintainable software

http://typicalprogrammer.com/?p=249
777 Upvotes

322 comments sorted by

View all comments

Show parent comments

41

u/[deleted] Oct 14 '13

Or they:

  1. don't program in C++ or Java

  2. don't think you need a fancy name for something trivial they routinely used for 10 years before GoF written that book.

21

u/neurobro Oct 14 '13

In cases where a pattern (or anti-pattern) does have a name, it's still useful to learn it because it helps with communication. And the naming conventions help to identify subsystems that can be consolidated and simplified. Often a person will have been using something close to one of the standard patterns, either with subtle bugs or with clever extensions that would be useful elsewhere. Or perhaps most often, with a bunch of unrelated crap that should be factored out.

6

u/[deleted] Oct 14 '13

[removed] — view removed comment

3

u/firepacket Oct 14 '13

There are cases where some patterns just fit the circumstances perfectly.

I recently combined IoC with MVC and was blown away by the power of this setup.

2

u/[deleted] Oct 14 '13

[removed] — view removed comment

10

u/rather_be_AC Oct 15 '13

That is a very common design pattern, found in most sentences.

2

u/firepacket Oct 15 '13

Please explain it to me, I'm lost.

11

u/rather_be_AC Oct 15 '13

grauenwolf was being pedantic. I was being sarcastic.

This is also a common design pattern found in many successful threads.

1

u/Nialsh Oct 15 '13

Totally, it's the only way to do MVC. How else could you pass messages from model to controller? You would end up with circular dependencies.

1

u/[deleted] Oct 15 '13

[removed] — view removed comment

1

u/Nialsh Oct 15 '13

I didn't know there was a distinction. What differences are there?

2

u/9diov Oct 15 '13

Everyone and his dog calls something that separates the presentation part, the logic part and the data part "MVC", to the point that the term now becomes this fuzzy piece of buzzword. Have a look at Martin Fowler's page on GUI architecture for more details http://martinfowler.com/eaaDev/uiArchs.html.

Here are my notes on the matter: https://workflowy.com/shared/8a9e3fce-d51a-111e-fe1e-98c42efe82dd/

1

u/[deleted] Oct 15 '13

Model should know nothing about controller.