Package io.jmix.securityflowui.access
Class FlowuiViewAccessChecker
java.lang.Object
io.jmix.securityflowui.access.FlowuiViewAccessChecker
- All Implemented Interfaces:
com.vaadin.flow.router.BeforeEnterListener,com.vaadin.flow.router.internal.BeforeEnterHandler,Serializable
public class FlowuiViewAccessChecker
extends Object
implements com.vaadin.flow.router.BeforeEnterListener
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected booleanprotected final FlowuiAccessCheckerprotected Class<? extends com.vaadin.flow.component.Component> -
Constructor Summary
ConstructorsConstructorDescriptionFlowuiViewAccessChecker(boolean enabled, FlowuiAccessChecker flowuiAccessChecker) FlowuiViewAccessChecker(FlowuiAccessChecker flowuiAccessChecker) -
Method Summary
Modifier and TypeMethodDescriptionvoidbeforeEnter(com.vaadin.flow.router.BeforeEnterEvent beforeEnterEvent) voidenable()Enables the access checker.protected booleanprotected booleanisHasAccess(Class<?> targetView) protected booleanisProductionMode(com.vaadin.flow.router.BeforeEnterEvent beforeEnterEvent) voidsetLoginView(Class<? extends com.vaadin.flow.component.Component> loginView) protected void
-
Field Details
-
flowuiAccessChecker
-
enabled
protected boolean enabled -
loginView
-
-
Constructor Details
-
FlowuiViewAccessChecker
-
FlowuiViewAccessChecker
-
-
Method Details
-
enable
public void enable()Enables the access checker.This must be called for the access checker to perform any checks. By default, the access checker is disabled.
-
setLoginView
-
throwIfLoginViewSet
protected void throwIfLoginViewSet() -
beforeEnter
public void beforeEnter(com.vaadin.flow.router.BeforeEnterEvent beforeEnterEvent) - Specified by:
beforeEnterin interfacecom.vaadin.flow.router.internal.BeforeEnterHandler
-
isHasAccess
-
isProductionMode
protected boolean isProductionMode(com.vaadin.flow.router.BeforeEnterEvent beforeEnterEvent) -
isAnonymousAuthentication
protected boolean isAnonymousAuthentication()
-