code: public static String encodeScheme(String scheme, String encoding) throws UnsupportedEncodingException {
  		return HierarchicalUriComponents.encodeUriComponent(scheme, encoding, HierarchicalUriComponents.Type.SCHEME);
  	}
docs: Encodes the given URI scheme with the given encoding.
  @param scheme the scheme to be encoded
  @param encoding the character encoding to encode to
  @return the encoded scheme
  @throws UnsupportedEncodingException when the given encoding parameter is not supported