Uses of Interface
org.jgrapes.http.ResponseCreationSupport.MaxAgeCalculator
Package
Description
Provides components for building a HTTP server based on the
core and IO components.
Provides a base component for generating template based responses
to HTTP requests.
-
Uses of ResponseCreationSupport.MaxAgeCalculator in org.jgrapes.http
Modifier and TypeClassDescriptionstatic class
DefaultMaxAgeCalculator provides an implementation that tries to guess a good max age value by looking at the path of the requested resource.Modifier and TypeFieldDescriptionstatic final ResponseCreationSupport.MaxAgeCalculator
ResponseCreationSupport.DEFAULT_MAX_AGE_CALCULATOR
A default implementation for the max-age calculator.Modifier and TypeMethodDescriptionstatic boolean
ResponseCreationSupport.sendStaticContent
(HttpRequest request, IOSubchannel channel, Function<String, URL> resolver, ResponseCreationSupport.MaxAgeCalculator maxAgeCalculator) Creates and sends a response with static content.static boolean
ResponseCreationSupport.sendStaticContent
(Request.In event, IOSubchannel channel, Function<String, URL> resolver, ResponseCreationSupport.MaxAgeCalculator maxAgeCalculator) Shorthand for invokingResponseCreationSupport.sendStaticContent(HttpRequest, IOSubchannel, Function, MaxAgeCalculator)
with theHttpRequest
from the event.void
StaticContentDispatcher.setMaxAgeCalculator
(ResponseCreationSupport.MaxAgeCalculator maxAgeCalculator) Sets theResponseCreationSupport.MaxAgeCalculator
for generating theCache-Control
(max-age
) header of the response. -
Uses of ResponseCreationSupport.MaxAgeCalculator in org.jgrapes.http.freemarker
Modifier and TypeMethodDescriptionvoid
FreeMarkerRequestHandler.setMaxAgeCalculator
(ResponseCreationSupport.MaxAgeCalculator maxAgeCalculator) Sets theResponseCreationSupport.MaxAgeCalculator
for generating theCache-Control
(max-age
) header of the response.