Package com.vaadin.flow.internal.hilla
Interface EndpointRequestUtil
- All Superinterfaces:
Serializable
A container for utility methods related with Hilla endpoints.
For internal use only. May be renamed or removed in a future release.
- Since:
- 23.2
- Author:
- Vaadin Ltd
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classHolder for the lazily-computed, cached Hilla availability flag. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionbooleanisAnonymousEndpoint(jakarta.servlet.http.HttpServletRequest request) Checks if the given request goes to an anonymous (public) endpoint.booleanisEndpointRequest(jakarta.servlet.http.HttpServletRequest request) Checks if the request is for an endpoint.static booleanChecks if Hilla is available.
-
Field Details
-
HILLA_ENDPOINT_CLASS
- See Also:
-
-
Method Details
-
isEndpointRequest
boolean isEndpointRequest(jakarta.servlet.http.HttpServletRequest request) Checks if the request is for an endpoint.Note even if this method returns
true, there is no guarantee that an endpoint method will actually be called, e.g. access might be denied.- Parameters:
request- the HTTP request- Returns:
trueif the request is for an endpoint,falseotherwise
-
isAnonymousEndpoint
boolean isAnonymousEndpoint(jakarta.servlet.http.HttpServletRequest request) Checks if the given request goes to an anonymous (public) endpoint.- Parameters:
request- the HTTP request to check- Returns:
trueif the request goes to an anonymous endpoint,falseotherwise
-
isHillaAvailable
static boolean isHillaAvailable()Checks if Hilla is available.The result is computed once on first access and cached, since the availability of the Hilla endpoint class cannot change during the lifetime of the classloader that loaded this interface.
- Returns:
- true if Hilla is available, false otherwise
-