DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15082>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15082

elapsed time formatting utility method





------- Additional Comments From [EMAIL PROTECTED]  2002-12-11 03:52 -------
Ahhh...didn't know this class existed.  StopWatch looks like the right
class/place for this functionality.  I just looked at the source for it.  I can
see why the getTimeString method was originally not public - it's because it
takes in a long parameter and just formats that instead of referring to the
internal fields of the class.  I don't think the public method should have a
parameter.  I also think that overriding the toString method is a little
ambiguous. (I assume that was the intended public method before).
I would suggest:

public static long getTime()            (as-is)
public static String getTimeString()    (no parameters.  this should then call a
private formatTimeString method that accesses the internal fields.)

That would eliminate the privacy issues while keeping the API clear, IMHO.

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to