コード例 #1
0
                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 26: {
                            Title = input.ReadString();
                            break;
                        }

                        case 32: {
                            PageCount = input.ReadInt32();
                            break;
                        }

                        case 42: {
                            if (author_ == null)
                            {
                                Author = new global::Google.Protobuf.Examples.AddressBook.Books.Types.BookInfo.Types.Author();
                            }
                            input.ReadMessage(Author);
                            break;
                        }

                        case 50: {
                            Description = input.ReadString();
                            break;
                        }
                        }
                    }
        #endif
                }
コード例 #2
0
                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 26: {
                            Title = input.ReadString();
                            break;
                        }

                        case 32: {
                            PageCount = input.ReadInt32();
                            break;
                        }

                        case 42: {
                            if (author_ == null)
                            {
                                Author = new global::Google.Protobuf.Examples.AddressBook.Books.Types.BookInfo.Types.Author();
                            }
                            input.ReadMessage(Author);
                            break;
                        }

                        case 50: {
                            Description = input.ReadString();
                            break;
                        }
                        }
                    }
                }
コード例 #3
0
                public void MergeFrom(pb::CodedInputStream input)
                {
                    uint tag;

                    while ((tag = input.ReadTag()) != 0)
                    {
                        switch (tag)
                        {
                        default:
                            _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
                            break;

                        case 8: {
                            Id = input.ReadInt32();
                            break;
                        }

                        case 26: {
                            Title = input.ReadString();
                            break;
                        }

                        case 32: {
                            PageCount = input.ReadInt32();
                            break;
                        }

                        case 42: {
                            if (author_ == null)
                            {
                                author_ = new global::Google.Protobuf.Examples.AddressBook.Books.Types.BookInfo.Types.Author();
                            }
                            input.ReadMessage(author_);
                            break;
                        }
                        }
                    }
                }