4#include "Stroika/Foundation/StroikaPreComp.h"
7#include "Stroika/Foundation/Characters/String2Int.h"
12#include "CacheControl.h"
19using namespace Stroika::Foundation::Traversal;
36 Assert (
not v.empty ());
38 Assert (
not vv.empty ());
47 r.fMustRevalidate =
true;
50 r.fNoTransform =
true;
53 r.fOnlyIfCached =
true;
66 if (
vv.length () >= 2) {
84 if (
not sb.empty ()) {
93 sb <<
"must-revalidate"sv;
101 sb <<
"no-transform"sv;
105 sb <<
"only-if-cached"sv;
122 if (fMaxStale->fAmount) {
123 sb <<
"={}"_f(*fMaxStale->fAmount);
Similar to String, but intended to more efficiently construct a String. Mutable type (String is large...
String is like std::u32string, except it is much easier to use, often much more space efficient,...
A generalization of a vector: a container whose elements are keyed by the natural numbers.
static constexpr DiscreteRange FullRange()
bool fImmutable
Very useful if/when true.
optional< int > fSharedMaxAge
bool fMustRevalidate
Probably not useful in most cases. Just affects behavior of cached values when expired and disconnect...
optional< uint32_t > fAge
optional< uint32_t > fMaxAge
static CacheControl Parse(const Characters::String &headerValue)
optional< int > fMinFresh