Example #1
0
        private static void addCharacterSet(int value, String encodingName)
        {
            var eci = new CharacterSetECI(value, encodingName);

            VALUE_TO_ECI[value]       = eci; // can't use valueOf
            NAME_TO_ECI[encodingName] = eci;
        }
Example #2
0
        private static void addCharacterSet(int value, String[] encodingNames)
        {
            var eci = new CharacterSetECI(value, encodingNames[0]);

            VALUE_TO_ECI[value] = eci; // can't use valueOf
            foreach (string t in encodingNames)
            {
                NAME_TO_ECI[t] = eci;
            }
        }
Example #3
0
 /// <param name="value">ECI value
 /// </param>
 /// <returns> {@link ECI} representing ECI of given value, or null if it is legal but unsupported
 /// </returns>
 /// <throws>  IllegalArgumentException if ECI value is invalid </throws>
 public static ECI getECIByValue(int value_Renamed)
 {
     if (value_Renamed < 0 || value_Renamed > 999999)
     {
         throw new System.ArgumentException("Bad ECI value: " + value_Renamed);
     }
     if (value_Renamed < 900)
     {
         // Character set ECIs use 000000 - 000899
         return(CharacterSetECI.getCharacterSetECIByValue(value_Renamed));
     }
     return(null);
 }