final PropertyMetaRowExtractor rowExtractor = pm.forRowExtraction();
if (pm.structure().isEmbeddedId()) {
Object compoundKey = rowExtractor.extractCompoundPrimaryKeyFromRow(row, meta, MANAGED);
pm.forValues().setValueToField(entity, compoundKey);
} else {
Object value = rowExtractor.invokeOnRowForFields(row);
pm.forValues().setValueToField(entity, value);
}
}
}