Why are you modifying the salary? General raise or promotion? How do you tell your mutator which reason and apply the business rules as needed?
With completely seperate methods for each, the reason will be blindingly obvious. You don't even need a conditional to figure it out in the object's code.
"There is no shame in being self-taught, only in not trying to learn in the first place." -- Atrus, Myst: The Book of D'ni.
In reply to Re^17: Assignable Subroutines
by hardburn
in thread Assignable Subroutines
by dragonchild
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |