Re: Terminolgy: the verb corresponding to "toString"
- From: Andrea Francia <andrea.francia@xxxxxxxxxxxxxxxxxxèdatogliereohohoho.it>
- Date: Thu, 31 Jul 2008 13:29:51 +0200
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"
The verb is "Returns a string"
For example you could say
Returns a string representation of the object.
http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html#toString()
Or you can be more accurate saying something like that:
Returns a string contaning the Full Name of the Employee and her/his age
--
Andrea Francia
http://www.andreafrancia.it/
.
- Follow-Ups:
- Re: Terminolgy: the verb corresponding to "toString"
- From: Roedy Green
- Re: Terminolgy: the verb corresponding to "toString"
- References:
- Terminolgy: the verb corresponding to "toString"
- From: Roedy Green
- Terminolgy: the verb corresponding to "toString"
- Prev by Date: Terminolgy: the verb corresponding to "toString"
- Next by Date: Re: Performance issues with large ResultSet
- Previous by thread: Terminolgy: the verb corresponding to "toString"
- Next by thread: Re: Terminolgy: the verb corresponding to "toString"
- Index(es):
Relevant Pages
|