Package io.jmix.flowui.sys
Class UiAccessChecker
java.lang.Object
io.jmix.flowui.sys.UiAccessChecker
Class checks UI access permission.
-
Field Summary
Modifier and TypeFieldDescriptionprotected com.vaadin.flow.server.auth.AccessAnnotationChecker
protected AccessManager
protected ViewRegistry
-
Constructor Summary
ConstructorDescriptionUiAccessChecker
(com.vaadin.flow.server.auth.AccessAnnotationChecker accessAnnotationChecker, AccessManager accessManager, ViewRegistry viewRegistry) -
Method Summary
Modifier and TypeMethodDescriptiongetControllerClass
(MenuItem menuItem) protected boolean
isMenuItemHasSecurityPermission
(MenuItem menuItem) boolean
isMenuPermitted
(MenuItem menuItem) FirstlyAccessAnnotationChecker
checks annotation constraints, if menu item is not permitted thenAccessManager
checks granted permissions.protected boolean
isSupportedView
(Class<?> targetView) protected boolean
isViewHasSecurityPermission
(Class<?> target) boolean
isViewPermitted
(Class<?> target) FirstlyAccessAnnotationChecker
checks annotation constraints, if view is not permitted thenAccessManager
checks granted permissions.
-
Field Details
-
accessAnnotationChecker
protected com.vaadin.flow.server.auth.AccessAnnotationChecker accessAnnotationChecker -
accessManager
-
viewRegistry
-
-
Constructor Details
-
UiAccessChecker
public UiAccessChecker(@Nullable com.vaadin.flow.server.auth.AccessAnnotationChecker accessAnnotationChecker, AccessManager accessManager, ViewRegistry viewRegistry)
-
-
Method Details
-
isViewPermitted
FirstlyAccessAnnotationChecker
checks annotation constraints, if view is not permitted thenAccessManager
checks granted permissions.- Parameters:
target
- class to check- Returns:
true
if view is permitted
-
isSupportedView
-
isViewHasSecurityPermission