Class MethodValueResolver
- java.lang.Object
-
- com.github.jknack.handlebars.context.MemberValueResolver<java.lang.reflect.Method>
-
- com.github.jknack.handlebars.context.MethodValueResolver
-
- All Implemented Interfaces:
ValueResolver
- Direct Known Subclasses:
JavaBeanValueResolver
public class MethodValueResolver extends MemberValueResolver<java.lang.reflect.Method>
A specialization ofMemberValueResolverwith lookup and invocation support forMethod. It matches a public method.- Since:
- 0.1.1
-
-
Field Summary
Fields Modifier and Type Field Description static ValueResolverINSTANCEThe default instance.-
Fields inherited from interface com.github.jknack.handlebars.ValueResolver
UNRESOLVED
-
-
Constructor Summary
Constructors Constructor Description MethodValueResolver()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanmatches(java.lang.reflect.Method method, java.lang.String name)True, if the member matches the one we look for.-
Methods inherited from class com.github.jknack.handlebars.context.MemberValueResolver
propertySet, resolve, resolve
-
-
-
-
Field Detail
-
INSTANCE
public static final ValueResolver INSTANCE
The default instance.
-
-
Method Detail
-
matches
public boolean matches(java.lang.reflect.Method method, java.lang.String name)Description copied from class:MemberValueResolverTrue, if the member matches the one we look for.- Specified by:
matchesin classMemberValueResolver<java.lang.reflect.Method>- Parameters:
method- The classMember.name- The attribute's name.- Returns:
- True, if the member matches the one we look for.
-
-