A simple design question.
Sample code:
Integer int1 = new Integer(20);
System.out.println(Integer.toBinaryString(int1));
Why JDK design is not something like the following? so, toBinaryString function returns the the desired result?
System.out.println(int1.toBinaryString());
Aside for wide usability of a static function, what are the other reasons for this design approach? Are they using any particular design pattern? If it is then, which pattern?