Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Favorites infavorites:mine
infavorites:1234
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with Search options user 12828

Questions about problem solving and planning for a solution through software design.

3
votes
The Agile "mantra" is not to do without documentation entirely. The Agile mantra is to prefer "Working software over comprehensive documentation". But note the bit at the bottom of the manifesto. …
answered Aug 29 '12 by pdr
3
votes
While coding, I came across a realization that I am not creating 'loose coupling'. The way I am trying to solve the problem right now is creating an instance of the Log Collector Class in MAIN and …
answered May 24 '12 by pdr
2
votes
That's a pretty good approach. You can have as many objects as you like raising exceptions, informing your middle-man, and as many listeners as you like waiting for an event to be raised. And no objec …
answered May 24 '12 by pdr
15
votes
Of course not. Even if you use an IoC container, you will have to have conditions somewhere, deciding which concrete implementation to inject. This is the nature of the Strategy pattern. I don't real …
answered May 1 '12 by pdr
15
votes
This is a prime candidate for the Strategy pattern. For example, this code: if ($this->isDisputeAccepted($order)) { //returns true if dispute was accepted $order->setStatus('accepted'); $ord …
answered May 1 '12 by pdr
2
votes
I don't think I've ever said this before, but this looks like a prime candidate for the Visitor pattern. the visitor design pattern is a way of separating an algorithm from an object structure on …
answered Feb 26 '12 by pdr
1
vote
The best practice, for the user, is obviously to make sure the second add fails. But this is going to slow your whole site down for the sake of the 0.1% case. The most technically efficient solution, …
answered Feb 8 '12 by pdr
0
votes
I think you're right that the payment period is not a property of the actual Car/Motorbike. But it is an attribute of the class of vehicle. While you could go down the road of having an if/select on …
answered Feb 2 '12 by pdr
18
votes
If the issue is that you need to apply multiple discounts, under given circumstances, you might want to consider the Chain of Responsibility pattern. In a nutshell, you pass the information you want …
answered Jan 18 '12 by pdr
3
votes
I think you're right, to be honest. I think that Microsoft messed up with the StreamWriter class, specifically, for the reasons you describe. However, I've since seen a lot of code where people don't …
answered Jan 11 '12 by pdr
10
votes
It's really entirely up to you. I would consider it a display detail. If you were to replace the front-end with a web service, you would want to "display" it in an entirely different way. And thus I' …
answered Dec 22 '11 by pdr
11
votes
Like the Pirate Code, the SRP is more of a guideline than a rule, and it's not even a particularly well-worded one. Most developers have accepted the redefinitions of Martin Fowler (in Refactoring) an …
answered Nov 29 '11 by pdr
1
vote
The "eventing" design pattern (better known as the Observer Pattern) allows you to attach multiple methods of the same signature to the delegate. You can't really do that with an interface. I'm not …
answered Oct 13 '11 by pdr
3
votes
Point out to him that the Agile books suggest postponing decisions as long as you can but no more than that. Every decision has a point where it has to be made, and maybe you're there right now. On t …
answered Oct 4 '11 by pdr
2
votes
signals. You will find very quickly that you have classes where there is nothing to test. When you find those, rethink your design, you probably don't need that class. On the other hand, you'll also … find code where you feel you are swimming in treacle while trying to write the tests. Again, rethink your design, it probably needs an abstraction layer you don't have yet. In other cases, you'll …
answered Sep 16 '11 by pdr

15 30 50 per page