public class NotModified
extends java.lang.Object
| Constructor and Description |
|---|
NotModified() |
| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
formatRfc2822(java.lang.Long timestamp) |
static void |
setClientCacheAggressively(io.netty.handler.codec.http.HttpHeaders headers)
Tells the browser to cache static files for a long time.
|
static void |
setNoClientCache(io.netty.handler.codec.http.HttpHeaders headers)
Prevents client cache.
|
public static java.lang.String formatRfc2822(java.lang.Long timestamp)
public static void setClientCacheAggressively(io.netty.handler.codec.http.HttpHeaders headers)
Don't worry that browsers do not pick up new files after you modified them, see the doc about static files.
Google recommends 1 year: http://code.google.com/speed/page-speed/docs/caching.html
Both Max-age and Expires header are set because IEs use Expires, not max-age: http://mrcoles.com/blog/cookies-max-age-vs-expires/
public static void setNoClientCache(io.netty.handler.codec.http.HttpHeaders headers)