home *** CD-ROM | disk | FTP | other *** search
/ S283 Planetary Science &… the Search for Life CD 3 / 0_CD-ROM.iso / install / jre1_3 / lib / rt.jar / java / text / AttributedCharacterIterator$Attribute.class (.txt) < prev    next >
Encoding:
Java Class File  |  1979-12-31  |  2.1 KB  |  63 lines

  1. package java.text;
  2.  
  3. import java.io.InvalidObjectException;
  4. import java.io.Serializable;
  5. import java.util.HashMap;
  6. import java.util.Map;
  7.  
  8. public class AttributedCharacterIterator$Attribute implements Serializable {
  9.    private String name;
  10.    private static final Map instanceMap = new HashMap(7);
  11.    public static final AttributedCharacterIterator$Attribute LANGUAGE = new AttributedCharacterIterator$Attribute("language");
  12.    public static final AttributedCharacterIterator$Attribute READING = new AttributedCharacterIterator$Attribute("reading");
  13.    public static final AttributedCharacterIterator$Attribute INPUT_METHOD_SEGMENT = new AttributedCharacterIterator$Attribute("input_method_segment");
  14.    // $FF: synthetic field
  15.    static Class class$java$text$AttributedCharacterIterator$Attribute;
  16.  
  17.    protected AttributedCharacterIterator$Attribute(String var1) {
  18.       this.name = var1;
  19.       if (this.getClass() == (class$java$text$AttributedCharacterIterator$Attribute == null ? (class$java$text$AttributedCharacterIterator$Attribute = class$("java.text.AttributedCharacterIterator$Attribute")) : class$java$text$AttributedCharacterIterator$Attribute)) {
  20.          instanceMap.put(var1, this);
  21.       }
  22.  
  23.    }
  24.  
  25.    public final boolean equals(Object var1) {
  26.       return super.equals(var1);
  27.    }
  28.  
  29.    public final int hashCode() {
  30.       return super.hashCode();
  31.    }
  32.  
  33.    public String toString() {
  34.       return this.getClass().getName() + "(" + this.name + ")";
  35.    }
  36.  
  37.    protected String getName() {
  38.       return this.name;
  39.    }
  40.  
  41.    protected Object readResolve() throws InvalidObjectException {
  42.       if (this.getClass() != (class$java$text$AttributedCharacterIterator$Attribute == null ? (class$java$text$AttributedCharacterIterator$Attribute = class$("java.text.AttributedCharacterIterator$Attribute")) : class$java$text$AttributedCharacterIterator$Attribute)) {
  43.          throw new InvalidObjectException("subclass didn't correctly implement readResolve");
  44.       } else {
  45.          AttributedCharacterIterator$Attribute var1 = (AttributedCharacterIterator$Attribute)instanceMap.get(this.getName());
  46.          if (var1 != null) {
  47.             return var1;
  48.          } else {
  49.             throw new InvalidObjectException("unknown attribute name");
  50.          }
  51.       }
  52.    }
  53.  
  54.    // $FF: synthetic method
  55.    static Class class$(String var0) {
  56.       try {
  57.          return Class.forName(var0);
  58.       } catch (ClassNotFoundException var2) {
  59.          throw new NoClassDefFoundError(((Throwable)var2).getMessage());
  60.       }
  61.    }
  62. }
  63.