commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Fabien Le Floc'h" <logo...@gmail.com>
Subject [lang] Mutable* increment decrement, add and subtract in Interface / Abstract class
Date Wed, 29 Nov 2006 13:42:20 GMT
Mutable* increment decrement, add and subtract methods are available on all
numbers.

It would be nice to have a MutableNumber interface (or abstract class
extending Number) specifying those methods. This can be useful when some
object takes a "MutableNumber" as input.

It would be nice as well to have a copy() method, that creates a new
MutableNumber initialized with the value of the current MutableNumber. This
is different from the getValue(), as getValue returns a non mutable object.

I can send a patch if you are interested.

Fabien.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message