Package com.vaadin.base.devserver
Class DevBundleBuildingHandler
java.lang.Object
com.vaadin.base.devserver.DevBundleBuildingHandler
- All Implemented Interfaces:
com.vaadin.flow.internal.DevModeHandler,com.vaadin.flow.server.RequestHandler,Serializable
public final class DevBundleBuildingHandler
extends Object
implements com.vaadin.flow.internal.DevModeHandler
A fake DevModeHandler whose only purpose is to eagerly show a "build in
progress" HTML page to the user, during the creation of the development
bundle.
The getPort() method returns a fixed value of -1, meaning
that this handler will not start a server listening for incoming requests.
Most of the other methods should not be invoked, and they may throw an exception if called.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintgetPort()Gets always -1, as this handler does not start a server.booleanhandleRequest(com.vaadin.flow.server.VaadinSession session, com.vaadin.flow.server.VaadinRequest request, com.vaadin.flow.server.VaadinResponse response) prepareConnection(String path, String method) booleanserveDevModeRequest(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) voidstop()voidWaits for the dev bundle to be built.
-
Constructor Details
-
DevBundleBuildingHandler
-
-
Method Details
-
getFailedOutput
- Specified by:
getFailedOutputin interfacecom.vaadin.flow.internal.DevModeHandler
-
prepareConnection
- Specified by:
prepareConnectionin interfacecom.vaadin.flow.internal.DevModeHandler
-
serveDevModeRequest
public boolean serveDevModeRequest(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) - Specified by:
serveDevModeRequestin interfacecom.vaadin.flow.internal.DevModeHandler
-
stop
public void stop()- Specified by:
stopin interfacecom.vaadin.flow.internal.DevModeHandler
-
getProjectRoot
- Specified by:
getProjectRootin interfacecom.vaadin.flow.internal.DevModeHandler
-
getPort
public int getPort()Gets always -1, as this handler does not start a server.- Specified by:
getPortin interfacecom.vaadin.flow.internal.DevModeHandler- Returns:
- -1
-
handleRequest
public boolean handleRequest(com.vaadin.flow.server.VaadinSession session, com.vaadin.flow.server.VaadinRequest request, com.vaadin.flow.server.VaadinResponse response) throws IOException - Specified by:
handleRequestin interfacecom.vaadin.flow.server.RequestHandler- Throws:
IOException
-
waitForDevBundle
public void waitForDevBundle()Waits for the dev bundle to be built.Suspends the caller's thread until the dev bundle is created (or failed to create).
-