GC stress fixes and other bugfixes; classpath progress

This commit is contained in:
Joel Dice
2007-07-29 17:32:23 -06:00
parent d5a00c4556
commit a2bd7d0668
27 changed files with 463 additions and 75 deletions

View File

@ -3,12 +3,35 @@ package java.lang;
public final class Integer extends Number {
public static final Class TYPE = Class.forCanonicalName("I");
public static final int MIN_VALUE = 0x80000000;
public static final int MAX_VALUE = 0x7FFFFFFF;
private final int value;
public Integer(int value) {
this.value = value;
}
public boolean equals(Object o) {
return o instanceof Integer && ((Integer) o).value == value;
}
public int hashCode() {
return value;
}
public String toString() {
return toString(value);
}
public static String toString(int v, int radix) {
return Long.toString(v, radix);
}
public static String toString(int v) {
return toString(v, 10);
}
public byte byteValue() {
return (byte) value;
}