#include "base/memory/ref_counted.h"
#include "base/strings/string_tokenizer.h"
+#include "base/time/time.h"
#include "net/base/net_export.h"
#include "net/http/http_byte_range.h"
#include "net/http/http_version.h"
static bool ParseRangeHeader(const std::string& range_specifier,
std::vector<HttpByteRange>* ranges);
+ // Parses a Retry-After header that is either an absolute date/time or a
+ // number of seconds in the future. Interprets absolute times as relative to
+ // |now|. If |retry_after_string| is successfully parsed and indicates a time
+ // that is not in the past, fills in |*retry_after| and returns true;
+ // otherwise, returns false.
+ static bool ParseRetryAfterHeader(const std::string& retry_after_string,
+ base::Time now,
+ base::TimeDelta* retry_after);
+
// Scans the '\r\n'-delimited headers for the given header name. Returns
// true if a match is found. Input is assumed to be well-formed.
// TODO(darin): kill this