Questions tagged [design-patterns]
A design pattern is a general reusable solution to a commonly occurring problem in software design.
4,519 questions
5
votes
2
answers
3k
views
Do you know of a data-pump design pattern?
I frequently encounter a situation where I need to write a program which reads data-objects from a file or system, does a transformation on the data, convert the data to another datamodel and then ...
12
votes
2
answers
5k
views
Static Create method -- pros and cons compared with constructors
What are the pros and cons of having static object creation methods over constructors?
class Foo {
private Foo(object arg) { }
public static Foo Create(object arg) {
if (!ValidateParam(arg)) ...
3
votes
5
answers
845
views
Is this technique a design pattern? If so, what's it called?
I'll use C# as an example, but it should apply globally. Say I have a string value that should be one of a few constants, but I also want the client to set which string value to use so:
private int ...
7
votes
8
answers
18k
views
What is a "wrapper" program?
Where I work, employees use a third-party desktop program for their clients. This program saves data to a flat file. My colleague wants to write a Java program that uploads that flat file to a remote ...
4
votes
2
answers
10k
views
What sort of Design Patterns do you use in Android Development? [closed]
I have been developing on Android for a couple months now, and building upon one in house program I found the scalability to be lacking. I have that gut feeling that if I applied some OO Design ...
3
votes
1
answer
282
views
Why doesn't DDD consider Documents?
... that is, the inputs and outputs of service functions ?
Are entities, or aggregates, allowed to leave service boundaries?
22
votes
8
answers
13k
views
Is the GoF book still the one to read? [duplicate]
Possible Duplicate:
Is there a canonical book on design patterns?
I'd like to read a design patterns book. GoF for sure is the one to read. But after 15 years is it still valid, I mean isn't there ...
33
votes
11
answers
7k
views
Are design patterns generally a force for good or bad? [closed]
I've heard it argued that design patterns are the best thing since sliced bread. I've also heard it argued that design patterns tend to exacerbate "Second System Syndrome," that they are massively ...
24
votes
16
answers
80k
views
What is the most frequently used design pattern? [closed]
Which design pattern do you think is the most popular?
68
votes
5
answers
28k
views
What is inversion of control, and when should I use it?
I am designing a new system and I want to know what inversion of control (IOC) is, and more importantly, when to use it.
Does it have to be implemented with interfaces or can be done with classes?