public void Deserialize <TInput>(ref Reader <TInput> reader, SubType obj) { uint fieldId = 0; _baseTypeSerializer.Deserialize(ref reader, obj); while (true) { var header = reader.ReadFieldHeader(); if (header.IsEndBaseOrEndObject) { break; } fieldId += header.FieldIdDelta; switch (fieldId) { case 0: obj.String = _stringCodec.ReadValue(ref reader, header); break; case 1: obj.Int = _intCodec.ReadValue(ref reader, header); break; case 2: obj.Ref = _objectCodec.ReadValue(ref reader, header); break; default: reader.ConsumeUnknownField(header); break; } } }
public void Deserialize <TInput>(ref Reader <TInput> reader, TField value) => _codec.Deserialize(ref reader, value);