code: public long getFirstDate(String headerName) {
  		String headerValue = getFirst(headerName);
  		if (headerValue == null) {
  			return -1;
  		}
  		for (String dateFormat : DATE_FORMATS) {
  			SimpleDateFormat simpleDateFormat = new SimpleDateFormat(dateFormat, Locale.US);
  			simpleDateFormat.setTimeZone(GMT);
  			try {
  				return simpleDateFormat.parse(headerValue).getTime();
  			}
  			catch (ParseException e) {
  				// ignore
  			}
  		}
  		throw new IllegalArgumentException("Cannot parse date value \"" + headerValue +
  				"\" for \"" + headerName + "\" header");
  	}
docs: Parse the first header value for the given header name as a date,
  return -1 if there is no value, or raise {@link IllegalArgumentException}
  if the value cannot be parsed as a date.