ReflectDatumReader uses Class in serialize function