public static Method getGenericAccessor ( Class < ? > clazz , String field ) { LOG . trace ( "getGenericAccessor({}, {})" , clazz , field ) ; String accessorQualifiedName = new StringBuilder ( clazz . getCanonicalName ( ) ) . append ( "." ) . append ( field ) . toString ( ) ; return accessorCache . computeIfAbsent ( accessorQualifiedName , key -> Stream . of ( clazz . getMethods ( ) ) . filter ( m -> Optional . ofNullable ( m . getAnnotation ( FEELProperty . class ) ) . map ( ann -> ann . value ( ) . equals ( field ) ) . orElse ( false ) ) . findFirst ( ) . orElse ( getAccessor ( clazz , field ) ) ) ; }
FEEL annotated or else Java accessor .