code: public static String toHex(int color) {
  		validateRGB(color);
  		String hex = Integer.toHexString(color).toUpperCase();
  		if (hex.length() == 1) {
  			hex = "0" + hex;
  		}
  		return hex;
  	}
docs: Convert the RGB integer to a hex single color
  
  @param color
  integer color inclusively between 0 and 255
  @return hex single color in format FF