    FOREIGN MODULE sun_io;

    IMPORT
        java_lang,
        java_security,
        java_util,
        java_io;

    TYPE

      ByteToCharConverter* = POINTER TO ABSTRACT RECORD (java_lang.Object)
                               subMode! : BOOLEAN;
                               subChars! : POINTER TO ARRAY OF CHAR;
                               charOff! : INTEGER;
                               byteOff! : INTEGER;
                               badInputLength! : INTEGER;
                             STATIC
                               PROCEDURE Init*() : ByteToCharConverter,CONSTRUCTOR;
                               PROCEDURE getConverter*(p0 : java_lang.String) : ByteToCharConverter;
                               PROCEDURE getDefault*() : ByteToCharConverter;
                             END;

      ByteToCharCp1252* = POINTER TO EXTENSIBLE RECORD (ByteToCharSingleByte)
                          STATIC
                            PROCEDURE Init*() : ByteToCharCp1252,CONSTRUCTOR;
                          END;

      ByteToCharISO8859_1* = POINTER TO EXTENSIBLE RECORD (ByteToCharConverter)
                             STATIC
                               PROCEDURE Init*() : ByteToCharISO8859_1,CONSTRUCTOR;
                             END;

      ByteToCharSingleByte* = POINTER TO ABSTRACT RECORD (ByteToCharConverter)
                                byteToCharTable! : java_lang.String;
                              STATIC
                                PROCEDURE Init*() : ByteToCharSingleByte,CONSTRUCTOR;
                              END;

      ByteToCharUnicode* = POINTER TO EXTENSIBLE RECORD (ByteToCharConverter)
                           STATIC
                             PROCEDURE Init*() : ByteToCharUnicode,CONSTRUCTOR;
                           END;

      ByteToCharUnicodeBig* = POINTER TO EXTENSIBLE RECORD (ByteToCharUnicode)
                              STATIC
                                PROCEDURE Init*() : ByteToCharUnicodeBig,CONSTRUCTOR;
                              END;

      ByteToCharUnicodeLittle* = POINTER TO EXTENSIBLE RECORD (ByteToCharUnicode)
                                 STATIC
                                   PROCEDURE Init*() : ByteToCharUnicodeLittle,CONSTRUCTOR;
                                 END;

      ByteToCharUTF8* = POINTER TO EXTENSIBLE RECORD (ByteToCharConverter)
                        STATIC
                          PROCEDURE Init*() : ByteToCharUTF8,CONSTRUCTOR;
                        END;

      CharacterEncoding* = POINTER TO EXTENSIBLE RECORD (java_lang.Object)
                           STATIC
                             PROCEDURE Init*() : CharacterEncoding,CONSTRUCTOR;
                             PROCEDURE aliasName*(p0 : java_lang.String) : java_lang.String;
                           END;

      CharToByteConverter* = POINTER TO ABSTRACT RECORD (java_lang.Object)
                               subMode! : BOOLEAN;
                               subBytes! : POINTER TO ARRAY OF BYTE;
                               charOff! : INTEGER;
                               byteOff! : INTEGER;
                               badInputLength! : INTEGER;
                             STATIC
                               PROCEDURE Init*() : CharToByteConverter,CONSTRUCTOR;
                               PROCEDURE getConverter*(p0 : java_lang.String) : CharToByteConverter;
                               PROCEDURE getDefault*() : CharToByteConverter;
                             END;

      CharToByteCp1252* = POINTER TO EXTENSIBLE RECORD (CharToByteSingleByte)
                          STATIC
                            PROCEDURE Init*() : CharToByteCp1252,CONSTRUCTOR;
                          END;

      CharToByteISO8859_1* = POINTER TO EXTENSIBLE RECORD (CharToByteConverter)
                             STATIC
                               PROCEDURE Init*() : CharToByteISO8859_1,CONSTRUCTOR;
                             END;

      CharToByteSingleByte* = POINTER TO ABSTRACT RECORD (CharToByteConverter)
                                index1! : POINTER TO ARRAY OF SHORTINT;
                                index2! : java_lang.String;
                                mask1! : INTEGER;
                                mask2! : INTEGER;
                                shift! : INTEGER;
                                badInputLength! : INTEGER;
                              STATIC
                                PROCEDURE Init*() : CharToByteSingleByte,CONSTRUCTOR;
                              END;

      CharToByteUnicode* = POINTER TO EXTENSIBLE RECORD (CharToByteConverter)
                             marked! : BOOLEAN;
                             byteOrder! : INTEGER;
                           STATIC
                             PROCEDURE Init*() : CharToByteUnicode,CONSTRUCTOR;
                           END;

      CharToByteUnicodeBig* = POINTER TO EXTENSIBLE RECORD (CharToByteUnicode)
                              STATIC
                                PROCEDURE Init*() : CharToByteUnicodeBig,CONSTRUCTOR;
                              END;

      CharToByteUnicodeBigUnmarked* = POINTER TO EXTENSIBLE RECORD (CharToByteUnicode)
                                      STATIC
                                        PROCEDURE Init*() : CharToByteUnicodeBigUnmarked,CONSTRUCTOR;
                                      END;

      CharToByteUnicodeLittle* = POINTER TO EXTENSIBLE RECORD (CharToByteUnicode)
                                 STATIC
                                   PROCEDURE Init*() : CharToByteUnicodeLittle,CONSTRUCTOR;
                                 END;

      CharToByteUnicodeLittleUnmarked* = POINTER TO EXTENSIBLE RECORD (CharToByteUnicode)
                                         STATIC
                                           PROCEDURE Init*() : CharToByteUnicodeLittleUnmarked,CONSTRUCTOR;
                                         END;

      CharToByteUTF8* = POINTER TO EXTENSIBLE RECORD (CharToByteConverter)
                        STATIC
                          PROCEDURE Init*() : CharToByteUTF8,CONSTRUCTOR;
                        END;

      ConversionBufferFullException* = POINTER TO EXTENSIBLE RECORD (java_io.CharConversionException)
                                       STATIC
                                         PROCEDURE Init*() : ConversionBufferFullException,CONSTRUCTOR;
                                         PROCEDURE Init*(p0 : java_lang.String) : ConversionBufferFullException,CONSTRUCTOR;
                                       END;

      MalformedInputException* = POINTER TO EXTENSIBLE RECORD (java_io.CharConversionException)
                                 STATIC
                                   PROCEDURE Init*() : MalformedInputException,CONSTRUCTOR;
                                   PROCEDURE Init*(p0 : java_lang.String) : MalformedInputException,CONSTRUCTOR;
                                 END;

      UnknownCharacterException* = POINTER TO EXTENSIBLE RECORD (java_io.CharConversionException)
                                   STATIC
                                     PROCEDURE Init*() : UnknownCharacterException,CONSTRUCTOR;
                                     PROCEDURE Init*(p0 : java_lang.String) : UnknownCharacterException,CONSTRUCTOR;
                                   END;

    PROCEDURE (self:ByteToCharConverter) convert*(IN  p0 : ARRAY OF BYTE;
                                                      p1 : INTEGER;
                                                      p2 : INTEGER;
                                                  IN  p3 : ARRAY OF CHAR;
                                                      p4 : INTEGER;
                                                      p5 : INTEGER) : INTEGER,NEW,ABSTRACT;

    PROCEDURE (self:ByteToCharConverter) convertAll*(IN  p0 : ARRAY OF BYTE) : POINTER TO ARRAY OF CHAR,NEW,EXTENSIBLE;

    PROCEDURE (self:ByteToCharConverter) flush*(IN  p0 : ARRAY OF CHAR;
                                                    p1 : INTEGER;
                                                    p2 : INTEGER) : INTEGER,NEW,ABSTRACT;

    PROCEDURE (self:ByteToCharConverter) getBadInputLength*() : INTEGER,NEW,EXTENSIBLE;

    PROCEDURE (self:ByteToCharConverter) getCharacterEncoding*() : java_lang.String,NEW,ABSTRACT;

    PROCEDURE (self:ByteToCharConverter) getMaxCharsPerByte*() : INTEGER,NEW,EXTENSIBLE;

    PROCEDURE (self:ByteToCharConverter) nextByteIndex*() : INTEGER,NEW,EXTENSIBLE;

    PROCEDURE (self:ByteToCharConverter) nextCharIndex*() : INTEGER,NEW,EXTENSIBLE;

    PROCEDURE (self:ByteToCharConverter) reset*(),NEW,ABSTRACT;

    PROCEDURE (self:ByteToCharConverter) setSubstitutionChars*(IN  p0 : ARRAY OF CHAR),NEW,EXTENSIBLE;

    PROCEDURE (self:ByteToCharConverter) setSubstitutionMode*(p0 : BOOLEAN),NEW,EXTENSIBLE;

    PROCEDURE (self:ByteToCharConverter) toString*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:ByteToCharCp1252) getCharacterEncoding*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:ByteToCharISO8859_1) convert*(IN  p0 : ARRAY OF BYTE;
                                                      p1 : INTEGER;
                                                      p2 : INTEGER;
                                                  IN  p3 : ARRAY OF CHAR;
                                                      p4 : INTEGER;
                                                      p5 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:ByteToCharISO8859_1) flush*(IN  p0 : ARRAY OF CHAR;
                                                    p1 : INTEGER;
                                                    p2 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:ByteToCharISO8859_1) getCharacterEncoding*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:ByteToCharISO8859_1) reset*(),EXTENSIBLE;

    PROCEDURE (self:ByteToCharSingleByte) convert*(IN  p0 : ARRAY OF BYTE;
                                                       p1 : INTEGER;
                                                       p2 : INTEGER;
                                                   IN  p3 : ARRAY OF CHAR;
                                                       p4 : INTEGER;
                                                       p5 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:ByteToCharSingleByte) flush*(IN  p0 : ARRAY OF CHAR;
                                                     p1 : INTEGER;
                                                     p2 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:ByteToCharSingleByte) getUnicode!(p0 : INTEGER) : CHAR,NEW,EXTENSIBLE;

    PROCEDURE (self:ByteToCharSingleByte) reset*(),EXTENSIBLE;

    PROCEDURE (self:ByteToCharUnicode) convert*(IN  p0 : ARRAY OF BYTE;
                                                    p1 : INTEGER;
                                                    p2 : INTEGER;
                                                IN  p3 : ARRAY OF CHAR;
                                                    p4 : INTEGER;
                                                    p5 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:ByteToCharUnicode) flush*(IN  p0 : ARRAY OF CHAR;
                                                  p1 : INTEGER;
                                                  p2 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:ByteToCharUnicode) getCharacterEncoding*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:ByteToCharUnicode) reset*(),EXTENSIBLE;

    PROCEDURE (self:ByteToCharUTF8) convert*(IN  p0 : ARRAY OF BYTE;
                                                 p1 : INTEGER;
                                                 p2 : INTEGER;
                                             IN  p3 : ARRAY OF CHAR;
                                                 p4 : INTEGER;
                                                 p5 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:ByteToCharUTF8) flush*(IN  p0 : ARRAY OF CHAR;
                                               p1 : INTEGER;
                                               p2 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:ByteToCharUTF8) getCharacterEncoding*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:ByteToCharUTF8) reset*(),EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) canConvert*(p0 : CHAR) : BOOLEAN,NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) convert*(IN  p0 : ARRAY OF CHAR;
                                                      p1 : INTEGER;
                                                      p2 : INTEGER;
                                                  IN  p3 : ARRAY OF BYTE;
                                                      p4 : INTEGER;
                                                      p5 : INTEGER) : INTEGER,NEW,ABSTRACT;

    PROCEDURE (self:CharToByteConverter) convertAll*(IN  p0 : ARRAY OF CHAR) : POINTER TO ARRAY OF BYTE,NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) convertAny*(IN  p0 : ARRAY OF CHAR;
                                                         p1 : INTEGER;
                                                         p2 : INTEGER;
                                                     IN  p3 : ARRAY OF BYTE;
                                                         p4 : INTEGER;
                                                         p5 : INTEGER) : INTEGER,NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) flush*(IN  p0 : ARRAY OF BYTE;
                                                    p1 : INTEGER;
                                                    p2 : INTEGER) : INTEGER,NEW,ABSTRACT;

    PROCEDURE (self:CharToByteConverter) flushAny*(IN  p0 : ARRAY OF BYTE;
                                                       p1 : INTEGER;
                                                       p2 : INTEGER) : INTEGER,NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) getBadInputLength*() : INTEGER,NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) getCharacterEncoding*() : java_lang.String,NEW,ABSTRACT;

    PROCEDURE (self:CharToByteConverter) getMaxBytesPerChar*() : INTEGER,NEW,ABSTRACT;

    PROCEDURE (self:CharToByteConverter) nextByteIndex*() : INTEGER,NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) nextCharIndex*() : INTEGER,NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) reset*(),NEW,ABSTRACT;

    PROCEDURE (self:CharToByteConverter) setSubstitutionBytes*(IN  p0 : ARRAY OF BYTE),NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) setSubstitutionMode*(p0 : BOOLEAN),NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteConverter) toString*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:CharToByteCp1252) getCharacterEncoding*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:CharToByteISO8859_1) canConvert*(p0 : CHAR) : BOOLEAN,EXTENSIBLE;

    PROCEDURE (self:CharToByteISO8859_1) convert*(IN  p0 : ARRAY OF CHAR;
                                                      p1 : INTEGER;
                                                      p2 : INTEGER;
                                                  IN  p3 : ARRAY OF BYTE;
                                                      p4 : INTEGER;
                                                      p5 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteISO8859_1) flush*(IN  p0 : ARRAY OF BYTE;
                                                    p1 : INTEGER;
                                                    p2 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteISO8859_1) getCharacterEncoding*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:CharToByteISO8859_1) getMaxBytesPerChar*() : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteISO8859_1) reset*(),EXTENSIBLE;

    PROCEDURE (self:CharToByteSingleByte) canConvert*(p0 : CHAR) : BOOLEAN,EXTENSIBLE;

    PROCEDURE (self:CharToByteSingleByte) convert*(IN  p0 : ARRAY OF CHAR;
                                                       p1 : INTEGER;
                                                       p2 : INTEGER;
                                                   IN  p3 : ARRAY OF BYTE;
                                                       p4 : INTEGER;
                                                       p5 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteSingleByte) flush*(IN  p0 : ARRAY OF BYTE;
                                                     p1 : INTEGER;
                                                     p2 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteSingleByte) getMaxBytesPerChar*() : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteSingleByte) getNative*(p0 : CHAR) : BYTE,NEW,EXTENSIBLE;

    PROCEDURE (self:CharToByteSingleByte) reset*(),EXTENSIBLE;

    PROCEDURE (self:CharToByteUnicode) convert*(IN  p0 : ARRAY OF CHAR;
                                                    p1 : INTEGER;
                                                    p2 : INTEGER;
                                                IN  p3 : ARRAY OF BYTE;
                                                    p4 : INTEGER;
                                                    p5 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteUnicode) flush*(IN  p0 : ARRAY OF BYTE;
                                                  p1 : INTEGER;
                                                  p2 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteUnicode) getCharacterEncoding*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:CharToByteUnicode) getMaxBytesPerChar*() : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteUnicode) reset*(),EXTENSIBLE;

    PROCEDURE (self:CharToByteUTF8) canConvert*(p0 : CHAR) : BOOLEAN,EXTENSIBLE;

    PROCEDURE (self:CharToByteUTF8) convert*(IN  p0 : ARRAY OF CHAR;
                                                 p1 : INTEGER;
                                                 p2 : INTEGER;
                                             IN  p3 : ARRAY OF BYTE;
                                                 p4 : INTEGER;
                                                 p5 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteUTF8) flush*(IN  p0 : ARRAY OF BYTE;
                                               p1 : INTEGER;
                                               p2 : INTEGER) : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteUTF8) getCharacterEncoding*() : java_lang.String,EXTENSIBLE;

    PROCEDURE (self:CharToByteUTF8) getMaxBytesPerChar*() : INTEGER,EXTENSIBLE;

    PROCEDURE (self:CharToByteUTF8) reset*(),EXTENSIBLE;

    END sun_io.