private static <T> void inflateColumn( Cursor cursor, T dataModelObject, TableDetails.ColumnDetails columnDetails, int columnIndex) { // If the column details is not required, then check if it is null if (!columnDetails.isRequired() && cursor.isNull(columnIndex)) { return; } try { columnDetails.setFieldValue(cursor, columnIndex, dataModelObject); } catch (IllegalAccessException e) { throw new QuantumFluxException( "Not allowed to alter the value of the field, please change the access level: " + columnDetails.getColumnName()); } }