Class SingleByteCharset

  • All Implemented Interfaces:
    java.lang.Comparable<java.nio.charset.Charset>
    Direct Known Subclasses:
    PDFDocEncodingCharset

    public class SingleByteCharset
    extends java.nio.charset.Charset
    Charset implementation for the single-byte encodings.
    Version:
    $Revision$
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected static char REPLACEMENT_CHARACTER
      Unicode replacement character 0xFFFD.
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected SingleByteCharset​(java.lang.String canonicalName, java.lang.String[] aliases, char[] toUnicodeMap)
      Creates a new single-byte charset using an array of unicode characters.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean contains​(java.nio.charset.Charset cs)
      java.nio.charset.CharsetDecoder newDecoder()
      java.nio.charset.CharsetEncoder newEncoder()
      • Methods inherited from class java.nio.charset.Charset

        aliases, availableCharsets, canEncode, compareTo, decode, defaultCharset, displayName, displayName, encode, encode, equals, forName, hashCode, isRegistered, isSupported, name, toString
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • REPLACEMENT_CHARACTER

        protected static final char REPLACEMENT_CHARACTER
        Unicode replacement character 0xFFFD.
        See Also:
        Constant Field Values
    • Constructor Detail

      • SingleByteCharset

        protected SingleByteCharset​(java.lang.String canonicalName,
                                    java.lang.String[] aliases,
                                    char[] toUnicodeMap)
        Creates a new single-byte charset using an array of unicode characters.
        Parameters:
        canonicalName - the canonical name
        aliases - An array of this charset's aliases, or null if it has no aliases
        toUnicodeMap - the array of unicode characters (may have a maximum of 256 characters, first character must be 0x0000)
    • Method Detail

      • contains

        public boolean contains​(java.nio.charset.Charset cs)
        Specified by:
        contains in class java.nio.charset.Charset
      • newDecoder

        public java.nio.charset.CharsetDecoder newDecoder()
        Specified by:
        newDecoder in class java.nio.charset.Charset
      • newEncoder

        public java.nio.charset.CharsetEncoder newEncoder()
        Specified by:
        newEncoder in class java.nio.charset.Charset