Re: Terminolgy: the verb corresponding to "toString"
- From: Nigel Wade <nmw@xxxxxxxxxxxx>
- Date: Thu, 31 Jul 2008 12:48:28 +0100
Roedy Green wrote:
What is the tersest way to document a toString style method.
I would like to say something like this:
"displays" the width and height in both metric and imperial measure
But it does not display anything, just prepares for display.
I have seen people also use misleading terms like "show" and "print".
What do you use?
The best I can come up with is "format". Sun uses this is the
SimpleDateFormat class.
To me, "format" implies some sort of complicated masks or a choice of
layouts.
"prepare" is too vague.
Perhaps a phase "convert x to a string"
Is there anything wrong with what Object.toString() says?
"Returns a string representation of the object. "
...
"The toString method for class Object returns a string consisting of..."
Seems to do pretty much cover it.
--
Nigel Wade
.
- References:
- Terminolgy: the verb corresponding to "toString"
- From: Roedy Green
- Terminolgy: the verb corresponding to "toString"
- Prev by Date: Re: Performance issues with large ResultSet
- Next by Date: Re: Mutually Recursive Generic Types
- Previous by thread: Re: Terminolgy: the verb corresponding to "toString"
- Next by thread: Re: Terminolgy: the verb corresponding to "toString"
- Index(es):
Relevant Pages
|