I want to have an descriptive string for an object in Cocoa. I’m thinking about overriding either the description method or the stringValue method. Which is preferable and why? The only guideline I could find was in here stating
You are discouraged from overriding description.
Is this indeed what you would suggest? Any other preferred overrride point?
descriptionis the way to go, that’s what it’s called to supply string representation of an object.I believe suggested by Hillegass’ book as well.