public static void validate(String s,Type t,boolean template){
  int i=_valid(s,t,template);
  if (i > -1) {
    throw new IllegalArgumentException("The string '" + s + "' for the URI component "+ t+ " contains an invalid character, '"+ s.charAt(i)+ "', at index "+ i);
  }
}

public static void validate ( String s , Type t , boolean template ) { int i = _valid ( s , t , template ) ; if ( i > - 1 ) { throw new IllegalArgumentException ( "The string '" + s + "' for the URI component " + t + " contains an invalid character, '" + s . charAt ( i ) + "', at index " + i ) ; } }
validates the legal characters of a percent - encoded string that represents a uri component type .
