public Method getGetMethod ( final Object object , final String fieldName ) { if ( object == null ) { throw new NullPointerException ( "object should not be null" ) ; } else if ( fieldName == null ) { throw new NullPointerException ( "fieldName should not be null" ) ; } Method method = getCache . get ( object . getClass ( ) . getName ( ) , fieldName ) ; if ( method == null ) { method = ReflectionUtils . findGetter ( object , fieldName ) ; getCache . set ( object . getClass ( ) . getName ( ) , fieldName , method ) ; } return method ; }
Returns the getter method for field on an object .