Take Care
Although it seems to be very easy to change a method name, code can be broken if refactoring tools (built into many modern IDE's) are not used to also change all code that refers to the existing method.
If a codebase has provided an external API that including the existing method name then the existing function should not be removed, but 'deprecated' over time and finally removed at a future date. In this case the "Copy Method" refactoring can be considered as an alternative.
- Java 5.0 provides the annotation @Override to help protect against mistakes such as this.
Read more about this topic: Rename Method
Famous quotes containing the word care:
“No one knows better than children how much they need the authority that protects, that sets the outer limits of behavior with known and prescribed consequences. As one little boy expressed it to his mother, You care what I do.”
—Leontine Young (20th century)
“It seems that nature, having taken such wise care to fit the organs of our body for our happiness and convenience, gave us also pride, to spare us the pain of knowing our own imperfections.”
—François, Duc De La Rochefoucauld (16131680)