We use cookies to serve our customers and website visitors in the best possible way. Cookies are used for the proper functioning of the website and for improving the user experience, monitoring visitor traffic and marketing purposes. By continuing to browse the site, you agree to our use of cookies. You can read more about cookies here.
com.vaadin.flow.server.
Package com.vaadin.flow.server
Interface StaticFileHandler
All Superinterfaces:
All Known Implementing Classes:
Handler for static files. The handler should be responsible in identifying and serving the static files, based on the servlet request.
Since:
1.3
Author:
Vaadin Ltd.
See Also:
-
Method Summary
Modifier and TypeMethodDescriptionboolean
serveStaticResource
(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) Serves a static resource for the requested path if a resource can be found.
-
Method Details
-
serveStaticResource
boolean serveStaticResource(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) throws IOException Serves a static resource for the requested path if a resource can be found.
Parameters:
request
- the request object to read fromresponse
- the response object to write toReturns:
true
if a file was served and the request has been handled,false
otherwise.Throws:
IOException
- if the underlying servlet container reports an exception
-