Class LoginViewRedirectSupport

java.lang.Object
io.jmix.flowui.sys.LoginViewRedirectSupport

@Component("flowui_LoginViewRedirectSupport") public class LoginViewRedirectSupport extends Object
Provides shared checks used to redirect an already authenticated user from the configured login view.
  • Field Details

  • Constructor Details

  • Method Details

    • isLoginView

      public boolean isLoginView(Class<? extends com.vaadin.flow.component.Component> navigationTarget)
      Checks whether the navigation target is the configured login view.
      Parameters:
      navigationTarget - navigation target class
      Returns:
      true if the target matches the configured login view
    • isUserAuthenticated

      public boolean isUserAuthenticated()
      Checks whether the current authentication is set and is not anonymous.
      Returns:
      true if the current user is authenticated
    • findMainViewInfo

      public Optional<ViewInfo> findMainViewInfo()
      Finds the configured main view.
      Returns:
      main view info, or an empty optional if the main view is not configured or not registered