Class DefaultAttributeResolver
java.lang.Object
io.pebbletemplates.pebble.attributes.DefaultAttributeResolver
- All Implemented Interfaces:
AttributeResolver
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionresolve(Object instance, Object attributeNameValue, Object[] argumentValues, ArgumentsNode args, EvaluationContextImpl context, String filename, int lineNumber) Attempts to resolve an attribute of the given instance.
-
Constructor Details
-
DefaultAttributeResolver
public DefaultAttributeResolver()
-
-
Method Details
-
resolve
public ResolvedAttribute resolve(Object instance, Object attributeNameValue, Object[] argumentValues, ArgumentsNode args, EvaluationContextImpl context, String filename, int lineNumber) Description copied from interface:AttributeResolverAttempts to resolve an attribute of the given instance. If this method returnsnull, Pebble asks the next attribute resolver in the list.- Specified by:
resolvein interfaceAttributeResolver- Parameters:
instance- The object which is being accessedattributeNameValue- The name of the attribute to resolveargumentValues- fully evaluated positional argumentsargs- The argumentscontext- The evaluation contextfilename- Filename of the templatelineNumber- the line number on which the expression is defined on.- Returns:
- a
ResolvedAttributewrapping the attribute value, ornullif the attribute could not be resolved
-