}
int fieldPosition = expectedField.pos();
Object oldDatum =
(old != null) ? getField(record, fieldName, fieldPosition) : null;
addField(record, fieldName, fieldPosition,
read(oldDatum,actualField.schema(),expectedField.schema(), in));
size++;
}
if (expectedFields.size() > size) { // not all fields set
Set<String> actualFields = actual.getFields().keySet();
for (Map.Entry<String, Field> entry : expectedFields.entrySet()) {