Class UiViewAccessChecker

java.lang.Object
io.jmix.securityflowui.access.UiViewAccessChecker
All Implemented Interfaces:
com.vaadin.flow.router.BeforeEnterListener, com.vaadin.flow.router.internal.BeforeEnterHandler, Serializable

public class UiViewAccessChecker extends Object implements com.vaadin.flow.router.BeforeEnterListener
See Also:
  • Field Details

    • uiAccessChecker

      protected final UiAccessChecker uiAccessChecker
    • enabled

      protected boolean enabled
    • loginView

      protected Class<? extends com.vaadin.flow.component.Component> loginView
  • Constructor Details

    • UiViewAccessChecker

      public UiViewAccessChecker(UiAccessChecker uiAccessChecker)
    • UiViewAccessChecker

      public UiViewAccessChecker(boolean enabled, UiAccessChecker uiAccessChecker)
  • 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

      public void setLoginView(Class<? extends com.vaadin.flow.component.Component> loginView)
    • throwIfLoginViewSet

      protected void throwIfLoginViewSet()
    • beforeEnter

      public void beforeEnter(com.vaadin.flow.router.BeforeEnterEvent beforeEnterEvent)
      Specified by:
      beforeEnter in interface com.vaadin.flow.router.internal.BeforeEnterHandler
    • isHasAccess

      protected boolean isHasAccess(Class<?> targetView)
    • isProductionMode

      protected boolean isProductionMode(com.vaadin.flow.router.BeforeEnterEvent beforeEnterEvent)
    • isAnonymousAuthentication

      protected boolean isAnonymousAuthentication()