MCPcopy Create free account
hub / github.com/SmingHub/Sming / setCache

Method setCache

Sming/Components/Network/src/Network/Http/HttpResponse.cpp:33–41  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

31}
32
33HttpResponse* HttpResponse::setCache(int maxAgeSeconds, bool isPublic)
34{
35 String cache = isPublic ? F("public") : F("private");
36 cache += F(", max-age=");
37 cache += maxAgeSeconds;
38 cache += F(", must-revalidate");
39 headers[HTTP_HEADER_CACHE_CONTROL] = cache;
40 return this;
41}
42
43bool HttpResponse::sendString(const String& text)
44{

Callers 13

onFileFunction · 0.80
onFileFunction · 0.80
onFileFunction · 0.80
onFileFunction · 0.80
onIndexFunction · 0.80
onConfigurationFunction · 0.80
onFileFunction · 0.80
onFileFunction · 0.80
onFileFunction · 0.80
onFileFunction · 0.80
onFileFunction · 0.80
onIndexFunction · 0.80

Calls 1

FFunction · 0.50

Tested by

no test coverage detected