private static Field getField(String fieldName, Class<?> where) {
        if (where == null) {
            throw new IllegalArgumentException("where cannot be null");
        }

        Field field = null;
        try {
            field = where.getDeclaredField(fieldName);
            field.setAccessible(true);
        } catch (NoSuchFieldException e) {
            throw new FieldNotFoundException("Field '" + fieldName + "' was not found in class " + where.getName()
                                                     + ".");
        }
        return field;
    }
private static Field getField ( String fieldName , Class < ? > where ) { if ( where == null ) { throw new IllegalArgumentException ( "where cannot be null" ) ; } Field field = null ; try { field = where . getDeclaredField ( fieldName ) ; field . setAccessible ( true ) ; } catch ( NoSuchFieldException e ) { throw new FieldNotFoundException ( "Field '" + fieldName + "' was not found in class " + where . getName ( ) + "." ) ; } return field ; }
Gets the field.

@param fieldName the field name
@param where     the where
@return the field