public void MergeFrom(Player other) { if (other == null) { return; } if (other.Id != 0) { Id = other.Id; } if (other.dateOfBirth_ != null) { if (dateOfBirth_ == null) { DateOfBirth = new global::Protos.DateOfBirth(); } DateOfBirth.MergeFrom(other.DateOfBirth); } if (other.FirstName.Length != 0) { FirstName = other.FirstName; } if (other.LastName.Length != 0) { LastName = other.LastName; } _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); }
public void MergeFrom(pb::CodedInputStream input) { #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE input.ReadRawMessage(this); #else uint tag; while ((tag = input.ReadTag()) != 0) { switch (tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Id = input.ReadInt32(); break; } case 18: { if (dateOfBirth_ == null) { DateOfBirth = new global::Protos.DateOfBirth(); } input.ReadMessage(DateOfBirth); break; } case 26: { FirstName = input.ReadString(); break; } case 34: { LastName = input.ReadString(); break; } } } #endif }
void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { uint tag; while ((tag = input.ReadTag()) != 0) { switch (tag) { default: _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); break; case 8: { Id = input.ReadInt32(); break; } case 18: { if (dateOfBirth_ == null) { DateOfBirth = new global::Protos.DateOfBirth(); } input.ReadMessage(DateOfBirth); break; } case 26: { FirstName = input.ReadString(); break; } case 34: { LastName = input.ReadString(); break; } } } }