code: public static String encode(String string, String enc) throws UnsupportedEncodingException {
      return new String(encode(string.getBytes(enc)), enc);
    }
docs: Encode a String in Base64. No line breaks or other white space are inserted into the encoded
  data.
  
  @param string The data to encode.
  @param enc Character encoding to use when converting to and from bytes.
  @return An encoded String.
  @throws UnsupportedEncodingException if the character encoding specified is not supported.
  @since ostermillerutils 1.00.00