Separate Query from Modifier

From CSSEMediaWiki
(Difference between revisions)
Jump to: navigation, search
(New page: Straight from Martin Fowler 2003: You have a method that returns a value and also changes the state of an object. ''Create two methods, one for the query and for the modification'' ...)
 
Line 1: Line 1:
 
Straight from [[Martin Fowler 2003]]:
 
Straight from [[Martin Fowler 2003]]:
  
You have a method that returns a value and also changes the state of an object.
+
"You have a method that returns a value and also changes the state of an object.
  
''Create two methods, one for the query and for the modification''
+
''Create two methods, one for the query and for the modification.''"
  
 
==See also==
 
==See also==
 
[[Command query separation]]
 
[[Command query separation]]

Revision as of 04:39, 21 September 2008

Straight from Martin Fowler 2003:

"You have a method that returns a value and also changes the state of an object.

Create two methods, one for the query and for the modification."

See also

Command query separation

Personal tools