KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > ChangedPackage > JavaLangByte


1 package ChangedPackage;
2
3 /**
4  * OLD: This class contains two methods which caused JDiff to report one
5  * method as removed and added. This may have been due to a List's
6  * compareTo method depending upon another List?
7  */

8 public class JavaLangByte {
9     /** Default constructor - unchagned.
10     public JavaLangByte() {
11     }
12
13     // This is verbatim from J2SE1.2
14
15     /**
16      * Returns a new String object representing the specified Byte. The radix
17      * is assumed to be 10.
18      *
19      * @param b the byte to be converted
20      */

21     public static String JavaDoc toString(byte b) {
22     return Integer.toString((int)b, 10);
23     }
24
25     /**
26      * Returns a String object representing this Byte's value.
27      */

28     public String JavaDoc toString() {
29         
30     return String.valueOf((int)value);
31     }
32
33     /**
34      * The value of the Byte.
35      *
36      * @serial
37      */

38     private byte value;
39 }
40
Popular Tags