Class OSFCodeSetRegistry.Entry

  • Enclosing class:
    OSFCodeSetRegistry

    public static final class OSFCodeSetRegistry.Entry
    extends java.lang.Object
    An entry in the OSF registry which allows users to find out the equivalent Java character encoding name as well as some other facts from the registry.
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private Entry​(java.lang.String javaName, int encodingNum, boolean isFixedWidth, int maxBytesPerChar)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object obj)
      First checks reference equality since it's expected people will use the pre-defined constant Entries.
      int getMaxBytesPerChar()  
      java.lang.String getName()
      Returns the Java equivalent name.
      int getNumber()
      Get the OSF registry number for this code set.
      int hashCode()
      Uses the registry number as the hash code.
      boolean isFixedWidth()
      Is this a fixed or variable width code set? (In CORBA terms, "non-byte-oriented" or a "byte-oriented" code set, respectively)
      • Methods inherited from class java.lang.Object

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

      • javaName

        private java.lang.String javaName
      • encodingNum

        private int encodingNum
      • isFixedWidth

        private boolean isFixedWidth
      • maxBytesPerChar

        private int maxBytesPerChar
    • Constructor Detail

      • Entry

        private Entry​(java.lang.String javaName,
                      int encodingNum,
                      boolean isFixedWidth,
                      int maxBytesPerChar)
    • Method Detail

      • getName

        public java.lang.String getName()
        Returns the Java equivalent name. If the encoding has an optional byte order marker, this name will map to the Java encoding that includes the marker.
        Returns:
        The Java name
      • getNumber

        public int getNumber()
        Get the OSF registry number for this code set.
        Returns:
        Encoding number
      • isFixedWidth

        public boolean isFixedWidth()
        Is this a fixed or variable width code set? (In CORBA terms, "non-byte-oriented" or a "byte-oriented" code set, respectively)
        Returns:
        True if this is a fixed with code set.
      • getMaxBytesPerChar

        public int getMaxBytesPerChar()
      • equals

        public boolean equals​(java.lang.Object obj)
        First checks reference equality since it's expected people will use the pre-defined constant Entries.
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Uses the registry number as the hash code.
        Overrides:
        hashCode in class java.lang.Object