code: public static int getCodePoint(char lead, char trail)
      {
          if (Character.isSurrogatePair(lead, trail)) {
              return Character.toCodePoint(lead, trail);
          }
          throw new IllegalArgumentException("Illegal surrogate characters");
      }
docs: <strong>[icu]</strong> Returns a code point corresponding to the two surrogate code units.
  
  @param lead the lead char
  @param trail the trail char
  @return code point if surrogate characters are valid.
  @exception IllegalArgumentException thrown when the code units do
  not form a valid code point