44 |
import java.io.ObjectInputStream; |
import java.io.ObjectInputStream; |
45 |
import java.io.ObjectOutputStream; |
import java.io.ObjectOutputStream; |
46 |
import java.io.IOException; |
import java.io.IOException; |
47 |
|
import java.io.InvalidObjectException; |
48 |
|
|
49 |
/** |
/** |
50 |
* This is the abstract superclass of all classes which format and |
* This is the abstract superclass of all classes which format and |
197 |
protected Object readResolve() throws InvalidObjectException |
protected Object readResolve() throws InvalidObjectException |
198 |
{ |
{ |
199 |
String s = getName(); |
String s = getName(); |
200 |
for (int i=0;i<allFields.length;i++) |
for (int i = 0; i < allFields.length; i++) |
201 |
if (s.equals(allFields[i].getName())) |
if (s.equals(allFields[i].getName())) |
202 |
return allFields[i]; |
return allFields[i]; |
203 |
|
|
204 |
throw new InvalidObjectException("no such NumberFormat field called " + s); |
throw new InvalidObjectException("no such NumberFormat field called " |
205 |
|
+ s); |
206 |
} |
} |
207 |
} |
} |
208 |
|
|