Class PrivilegeRenderCondition
- java.lang.Object
-
- com.adobe.granite.ui.components.rendercondition.PrivilegeRenderCondition
-
- All Implemented Interfaces:
RenderCondition
public class PrivilegeRenderCondition extends java.lang.Object implements RenderCondition
A condition that decides based onAccessControlManager.hasPrivileges(String, Privilege[]).
-
-
Constructor Summary
Constructors Constructor Description PrivilegeRenderCondition(AccessControlManager acm, java.lang.String path, java.lang.String[] privilegeNames)PrivilegeRenderCondition(AccessControlManager acm, java.lang.String path, Privilege[] privileges)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancheck()Returnstrueif the component should be rendered;falseotherwise.
-
-
-
Constructor Detail
-
PrivilegeRenderCondition
public PrivilegeRenderCondition(@Nonnull AccessControlManager acm, @Nonnull java.lang.String path, @Nonnull java.lang.String[] privilegeNames) throws RepositoryException- Throws:
RepositoryException
-
PrivilegeRenderCondition
public PrivilegeRenderCondition(@Nonnull AccessControlManager acm, @Nonnull java.lang.String path, @Nonnull Privilege[] privileges)
-
-
Method Detail
-
check
public boolean check() throws ServletExceptionDescription copied from interface:RenderConditionReturnstrueif the component should be rendered;falseotherwise.- Specified by:
checkin interfaceRenderCondition- Returns:
trueif the component should be rendered,falseotherwise- Throws:
ServletException- in case a servlet error occurs
-
-