Class GetterFactory
java.lang.Object
org.klojang.invoke.GetterFactory
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final GetterFactory
The one and only instance ofGetterFactory
. -
Method Summary
-
Field Details
-
INSTANCE
The one and only instance ofGetterFactory
.
-
-
Method Details
-
getGetters
Returns the publicgetters
for the specified class. The returnedMap
maps property names toGetter
instances.- Parameters:
clazz
- the class for which to retrieve the public gettersstrict
- iffalse
, all non-static methods with a zero-length parameter list and a non-void
return type, exceptgetClass()
,hashCode()
andtoString()
, will be regarded as getters. Otherwise JavaBeans naming conventions will be applied regarding which methods qualify as getters, with the exception that methods returning aBoolean
are allowed to have a name starting with "is". Forrecord
types, getters are collected as though withstrict
equal tofalse
.- Returns:
- the public getters of the specified class
- Throws:
IllegalAssignmentException
- if the does not have any public getters
-