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: { Type = (global::Prisel.Protobuf.PacketType)input.ReadEnum(); break; } case 16: { message_ = input.ReadEnum(); messageCase_ = MessageOneofCase.SystemAction; break; } case 26: { Action = input.ReadString(); break; } case 34: { RequestId = input.ReadString(); break; } case 42: { if (status_ == null) { Status = new global::Prisel.Protobuf.Status(); } input.ReadMessage(Status); break; } case 50: { if (payload_ == null) { Payload = new global::Prisel.Protobuf.Payload(); } input.ReadMessage(Payload); 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: { Type = (global::Prisel.Protobuf.PacketType)input.ReadEnum(); break; } case 16: { message_ = input.ReadEnum(); messageCase_ = MessageOneofCase.SystemAction; break; } case 26: { Action = input.ReadString(); break; } case 34: { RequestId = input.ReadString(); break; } case 42: { if (status_ == null) { Status = new global::Prisel.Protobuf.Status(); } input.ReadMessage(Status); break; } case 50: { if (payload_ == null) { Payload = new global::Prisel.Protobuf.Payload(); } input.ReadMessage(Payload); break; } } } }
public void MergeFrom(Packet other) { if (other == null) { return; } if (other.Type != global::Prisel.Protobuf.PacketType.Default) { Type = other.Type; } if (other.HasRequestId) { RequestId = other.RequestId; } if (other.status_ != null) { if (status_ == null) { Status = new global::Prisel.Protobuf.Status(); } Status.MergeFrom(other.Status); } if (other.payload_ != null) { if (payload_ == null) { Payload = new global::Prisel.Protobuf.Payload(); } Payload.MergeFrom(other.Payload); } switch (other.MessageCase) { case MessageOneofCase.SystemAction: SystemAction = other.SystemAction; break; case MessageOneofCase.Action: Action = other.Action; break; } _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); }