Class AuthorizeAttrProcessor
- Object
-
- org.thymeleaf.processor.AbstractProcessor
-
- org.thymeleaf.processor.element.AbstractElementTagProcessor
-
- org.thymeleaf.processor.element.AbstractAttributeTagProcessor
-
- org.thymeleaf.standard.processor.AbstractStandardConditionalVisibilityTagProcessor
-
- org.thymeleaf.extras.springsecurity5.dialect.processor.AuthorizeAttrProcessor
-
- All Implemented Interfaces:
org.thymeleaf.processor.element.IElementProcessor,org.thymeleaf.processor.element.IElementTagProcessor,org.thymeleaf.processor.IProcessor
public final class AuthorizeAttrProcessor extends org.thymeleaf.standard.processor.AbstractStandardConditionalVisibilityTagProcessorRenders the element children (*tag content*) if the authenticated user is authorized to see it according to the specified Spring Security expression.- Author:
- Daniel Fernández
-
-
Field Summary
Fields Modifier and Type Field Description static StringATTR_NAMEstatic StringATTR_NAME_EXPRstatic intATTR_PRECEDENCE
-
Constructor Summary
Constructors Constructor Description AuthorizeAttrProcessor(org.thymeleaf.templatemode.TemplateMode templateMode, String dialectPrefix, String attrName)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleanisVisible(org.thymeleaf.context.ITemplateContext context, org.thymeleaf.model.IProcessableElementTag tag, org.thymeleaf.engine.AttributeName attributeName, String attributeValue)-
Methods inherited from class org.thymeleaf.standard.processor.AbstractStandardConditionalVisibilityTagProcessor
doProcess
-
Methods inherited from class org.thymeleaf.processor.element.AbstractAttributeTagProcessor
doProcess
-
Methods inherited from class org.thymeleaf.processor.element.AbstractElementTagProcessor
getDialectPrefix, getMatchingAttributeName, getMatchingElementName, process
-
Methods inherited from class org.thymeleaf.processor.AbstractProcessor
getPrecedence, getTemplateMode
-
-
-
-
Field Detail
-
ATTR_PRECEDENCE
public static final int ATTR_PRECEDENCE
- See Also:
- Constant Field Values
-
ATTR_NAME
public static final String ATTR_NAME
- See Also:
- Constant Field Values
-
ATTR_NAME_EXPR
public static final String ATTR_NAME_EXPR
- See Also:
- Constant Field Values
-
-
Method Detail
-
isVisible
protected boolean isVisible(org.thymeleaf.context.ITemplateContext context, org.thymeleaf.model.IProcessableElementTag tag, org.thymeleaf.engine.AttributeName attributeName, String attributeValue)- Specified by:
isVisiblein classorg.thymeleaf.standard.processor.AbstractStandardConditionalVisibilityTagProcessor
-
-