| /* |
| Copyright 2016 The Transicator Authors |
| |
| Licensed under the Apache License, Version 2.0 (the "License"); |
| you may not use this file except in compliance with the License. |
| You may obtain a copy of the License at |
| |
| http://www.apache.org/licenses/LICENSE-2.0 |
| |
| Unless required by applicable law or agreed to in writing, software |
| distributed under the License is distributed on an "AS IS" BASIS, |
| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| See the License for the specific language governing permissions and |
| limitations under the License. |
| */ |
| // Code generated by protoc-gen-go. |
| // source: transicator.proto |
| // DO NOT EDIT! |
| |
| /* |
| Package common is a generated protocol buffer package. |
| |
| It is generated from these files: |
| transicator.proto |
| |
| It has these top-level messages: |
| ValuePb |
| ColumnPb |
| ChangePb |
| ChangeListPb |
| SnapshotHeaderPb |
| TableHeaderPb |
| RowPb |
| StreamMessagePb |
| */ |
| package common |
| |
| import proto "github.com/golang/protobuf/proto" |
| import fmt "fmt" |
| import math "math" |
| |
| // Reference imports to suppress errors if they are not otherwise used. |
| var _ = proto.Marshal |
| var _ = fmt.Errorf |
| var _ = math.Inf |
| |
| // This is a compile-time assertion to ensure that this generated file |
| // is compatible with the proto package it is being compiled against. |
| // A compilation error at this line likely means your copy of the |
| // proto package needs to be updated. |
| const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package |
| |
| type ValuePb struct { |
| // Types that are valid to be assigned to Value: |
| // *ValuePb_String_ |
| // *ValuePb_Int |
| // *ValuePb_Uint |
| // *ValuePb_Double |
| // *ValuePb_Bytes |
| // *ValuePb_Bool |
| // *ValuePb_Timestamp |
| Value isValuePb_Value `protobuf_oneof:"value"` |
| XXX_unrecognized []byte `json:"-"` |
| } |
| |
| func (m *ValuePb) Reset() { *m = ValuePb{} } |
| func (m *ValuePb) String() string { return proto.CompactTextString(m) } |
| func (*ValuePb) ProtoMessage() {} |
| func (*ValuePb) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} } |
| |
| type isValuePb_Value interface { |
| isValuePb_Value() |
| } |
| |
| type ValuePb_String_ struct { |
| String_ string `protobuf:"bytes,1,opt,name=string,oneof"` |
| } |
| type ValuePb_Int struct { |
| Int int64 `protobuf:"varint,2,opt,name=int,oneof"` |
| } |
| type ValuePb_Uint struct { |
| Uint uint64 `protobuf:"varint,3,opt,name=uint,oneof"` |
| } |
| type ValuePb_Double struct { |
| Double float64 `protobuf:"fixed64,4,opt,name=double,oneof"` |
| } |
| type ValuePb_Bytes struct { |
| Bytes []byte `protobuf:"bytes,5,opt,name=bytes,oneof"` |
| } |
| type ValuePb_Bool struct { |
| Bool bool `protobuf:"varint,6,opt,name=bool,oneof"` |
| } |
| type ValuePb_Timestamp struct { |
| Timestamp int64 `protobuf:"varint,7,opt,name=timestamp,oneof"` |
| } |
| |
| func (*ValuePb_String_) isValuePb_Value() {} |
| func (*ValuePb_Int) isValuePb_Value() {} |
| func (*ValuePb_Uint) isValuePb_Value() {} |
| func (*ValuePb_Double) isValuePb_Value() {} |
| func (*ValuePb_Bytes) isValuePb_Value() {} |
| func (*ValuePb_Bool) isValuePb_Value() {} |
| func (*ValuePb_Timestamp) isValuePb_Value() {} |
| |
| func (m *ValuePb) GetValue() isValuePb_Value { |
| if m != nil { |
| return m.Value |
| } |
| return nil |
| } |
| |
| func (m *ValuePb) GetString_() string { |
| if x, ok := m.GetValue().(*ValuePb_String_); ok { |
| return x.String_ |
| } |
| return "" |
| } |
| |
| func (m *ValuePb) GetInt() int64 { |
| if x, ok := m.GetValue().(*ValuePb_Int); ok { |
| return x.Int |
| } |
| return 0 |
| } |
| |
| func (m *ValuePb) GetUint() uint64 { |
| if x, ok := m.GetValue().(*ValuePb_Uint); ok { |
| return x.Uint |
| } |
| return 0 |
| } |
| |
| func (m *ValuePb) GetDouble() float64 { |
| if x, ok := m.GetValue().(*ValuePb_Double); ok { |
| return x.Double |
| } |
| return 0 |
| } |
| |
| func (m *ValuePb) GetBytes() []byte { |
| if x, ok := m.GetValue().(*ValuePb_Bytes); ok { |
| return x.Bytes |
| } |
| return nil |
| } |
| |
| func (m *ValuePb) GetBool() bool { |
| if x, ok := m.GetValue().(*ValuePb_Bool); ok { |
| return x.Bool |
| } |
| return false |
| } |
| |
| func (m *ValuePb) GetTimestamp() int64 { |
| if x, ok := m.GetValue().(*ValuePb_Timestamp); ok { |
| return x.Timestamp |
| } |
| return 0 |
| } |
| |
| // XXX_OneofFuncs is for the internal use of the proto package. |
| func (*ValuePb) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) { |
| return _ValuePb_OneofMarshaler, _ValuePb_OneofUnmarshaler, _ValuePb_OneofSizer, []interface{}{ |
| (*ValuePb_String_)(nil), |
| (*ValuePb_Int)(nil), |
| (*ValuePb_Uint)(nil), |
| (*ValuePb_Double)(nil), |
| (*ValuePb_Bytes)(nil), |
| (*ValuePb_Bool)(nil), |
| (*ValuePb_Timestamp)(nil), |
| } |
| } |
| |
| func _ValuePb_OneofMarshaler(msg proto.Message, b *proto.Buffer) error { |
| m := msg.(*ValuePb) |
| // value |
| switch x := m.Value.(type) { |
| case *ValuePb_String_: |
| b.EncodeVarint(1<<3 | proto.WireBytes) |
| b.EncodeStringBytes(x.String_) |
| case *ValuePb_Int: |
| b.EncodeVarint(2<<3 | proto.WireVarint) |
| b.EncodeVarint(uint64(x.Int)) |
| case *ValuePb_Uint: |
| b.EncodeVarint(3<<3 | proto.WireVarint) |
| b.EncodeVarint(uint64(x.Uint)) |
| case *ValuePb_Double: |
| b.EncodeVarint(4<<3 | proto.WireFixed64) |
| b.EncodeFixed64(math.Float64bits(x.Double)) |
| case *ValuePb_Bytes: |
| b.EncodeVarint(5<<3 | proto.WireBytes) |
| b.EncodeRawBytes(x.Bytes) |
| case *ValuePb_Bool: |
| t := uint64(0) |
| if x.Bool { |
| t = 1 |
| } |
| b.EncodeVarint(6<<3 | proto.WireVarint) |
| b.EncodeVarint(t) |
| case *ValuePb_Timestamp: |
| b.EncodeVarint(7<<3 | proto.WireVarint) |
| b.EncodeVarint(uint64(x.Timestamp)) |
| case nil: |
| default: |
| return fmt.Errorf("ValuePb.Value has unexpected type %T", x) |
| } |
| return nil |
| } |
| |
| func _ValuePb_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) { |
| m := msg.(*ValuePb) |
| switch tag { |
| case 1: // value.string |
| if wire != proto.WireBytes { |
| return true, proto.ErrInternalBadWireType |
| } |
| x, err := b.DecodeStringBytes() |
| m.Value = &ValuePb_String_{x} |
| return true, err |
| case 2: // value.int |
| if wire != proto.WireVarint { |
| return true, proto.ErrInternalBadWireType |
| } |
| x, err := b.DecodeVarint() |
| m.Value = &ValuePb_Int{int64(x)} |
| return true, err |
| case 3: // value.uint |
| if wire != proto.WireVarint { |
| return true, proto.ErrInternalBadWireType |
| } |
| x, err := b.DecodeVarint() |
| m.Value = &ValuePb_Uint{x} |
| return true, err |
| case 4: // value.double |
| if wire != proto.WireFixed64 { |
| return true, proto.ErrInternalBadWireType |
| } |
| x, err := b.DecodeFixed64() |
| m.Value = &ValuePb_Double{math.Float64frombits(x)} |
| return true, err |
| case 5: // value.bytes |
| if wire != proto.WireBytes { |
| return true, proto.ErrInternalBadWireType |
| } |
| x, err := b.DecodeRawBytes(true) |
| m.Value = &ValuePb_Bytes{x} |
| return true, err |
| case 6: // value.bool |
| if wire != proto.WireVarint { |
| return true, proto.ErrInternalBadWireType |
| } |
| x, err := b.DecodeVarint() |
| m.Value = &ValuePb_Bool{x != 0} |
| return true, err |
| case 7: // value.timestamp |
| if wire != proto.WireVarint { |
| return true, proto.ErrInternalBadWireType |
| } |
| x, err := b.DecodeVarint() |
| m.Value = &ValuePb_Timestamp{int64(x)} |
| return true, err |
| default: |
| return false, nil |
| } |
| } |
| |
| func _ValuePb_OneofSizer(msg proto.Message) (n int) { |
| m := msg.(*ValuePb) |
| // value |
| switch x := m.Value.(type) { |
| case *ValuePb_String_: |
| n += proto.SizeVarint(1<<3 | proto.WireBytes) |
| n += proto.SizeVarint(uint64(len(x.String_))) |
| n += len(x.String_) |
| case *ValuePb_Int: |
| n += proto.SizeVarint(2<<3 | proto.WireVarint) |
| n += proto.SizeVarint(uint64(x.Int)) |
| case *ValuePb_Uint: |
| n += proto.SizeVarint(3<<3 | proto.WireVarint) |
| n += proto.SizeVarint(uint64(x.Uint)) |
| case *ValuePb_Double: |
| n += proto.SizeVarint(4<<3 | proto.WireFixed64) |
| n += 8 |
| case *ValuePb_Bytes: |
| n += proto.SizeVarint(5<<3 | proto.WireBytes) |
| n += proto.SizeVarint(uint64(len(x.Bytes))) |
| n += len(x.Bytes) |
| case *ValuePb_Bool: |
| n += proto.SizeVarint(6<<3 | proto.WireVarint) |
| n += 1 |
| case *ValuePb_Timestamp: |
| n += proto.SizeVarint(7<<3 | proto.WireVarint) |
| n += proto.SizeVarint(uint64(x.Timestamp)) |
| case nil: |
| default: |
| panic(fmt.Sprintf("proto: unexpected type %T in oneof", x)) |
| } |
| return n |
| } |
| |
| type ColumnPb struct { |
| Name *string `protobuf:"bytes,1,req,name=name" json:"name,omitempty"` |
| Value *ValuePb `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"` |
| Type *int32 `protobuf:"varint,3,opt,name=type" json:"type,omitempty"` |
| XXX_unrecognized []byte `json:"-"` |
| } |
| |
| func (m *ColumnPb) Reset() { *m = ColumnPb{} } |
| func (m *ColumnPb) String() string { return proto.CompactTextString(m) } |
| func (*ColumnPb) ProtoMessage() {} |
| func (*ColumnPb) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} } |
| |
| func (m *ColumnPb) GetName() string { |
| if m != nil && m.Name != nil { |
| return *m.Name |
| } |
| return "" |
| } |
| |
| func (m *ColumnPb) GetValue() *ValuePb { |
| if m != nil { |
| return m.Value |
| } |
| return nil |
| } |
| |
| func (m *ColumnPb) GetType() int32 { |
| if m != nil && m.Type != nil { |
| return *m.Type |
| } |
| return 0 |
| } |
| |
| type ChangePb struct { |
| // operation -- May be 1, 2, 3 for insert, update, or delete |
| Operation *int32 `protobuf:"varint,1,req,name=operation" json:"operation,omitempty"` |
| // Table name, in "schema.table" format |
| Table *string `protobuf:"bytes,2,req,name=table" json:"table,omitempty"` |
| // Sequence number is generated by the change server by combining |
| // the commitSequence and commitIndex |
| Sequence *string `protobuf:"bytes,3,opt,name=sequence" json:"sequence,omitempty"` |
| // LSN when the transaction was committed. Primary sort order. |
| CommitSequence *uint64 `protobuf:"varint,4,opt,name=commitSequence" json:"commitSequence,omitempty"` |
| // LSN when the change was made. Mostly of academic interest. |
| ChangeSequence *uint64 `protobuf:"varint,5,opt,name=changeSequence" json:"changeSequence,omitempty"` |
| // Order in which the change was made inside the transaction. |
| // Secondary sort order. |
| CommitIndex *uint32 `protobuf:"varint,6,opt,name=commitIndex" json:"commitIndex,omitempty"` |
| // 32-bit Postgres transaction ID. Not used by newer code. |
| // Rolls over. |
| TransactionID *uint32 `protobuf:"varint,7,opt,name=transactionID" json:"transactionID,omitempty"` |
| // Row added to an insert, or new row for an update. |
| NewColumns []*ColumnPb `protobuf:"bytes,8,rep,name=newColumns" json:"newColumns,omitempty"` |
| // Row removed on a delete, or old row for an update. |
| OldColumns []*ColumnPb `protobuf:"bytes,9,rep,name=oldColumns" json:"oldColumns,omitempty"` |
| // Time when the record was inserted, in seconds since the |
| // Unix epoch. |
| Timestamp *int64 `protobuf:"varint,10,opt,name=timestamp" json:"timestamp,omitempty"` |
| // 64-bit Postgres transaction id, including the epoch. Will not |
| // roll over. |
| TransactionIDEpoch *uint64 `protobuf:"varint,11,opt,name=transactionIDEpoch" json:"transactionIDEpoch,omitempty"` |
| XXX_unrecognized []byte `json:"-"` |
| } |
| |
| func (m *ChangePb) Reset() { *m = ChangePb{} } |
| func (m *ChangePb) String() string { return proto.CompactTextString(m) } |
| func (*ChangePb) ProtoMessage() {} |
| func (*ChangePb) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} } |
| |
| func (m *ChangePb) GetOperation() int32 { |
| if m != nil && m.Operation != nil { |
| return *m.Operation |
| } |
| return 0 |
| } |
| |
| func (m *ChangePb) GetTable() string { |
| if m != nil && m.Table != nil { |
| return *m.Table |
| } |
| return "" |
| } |
| |
| func (m *ChangePb) GetSequence() string { |
| if m != nil && m.Sequence != nil { |
| return *m.Sequence |
| } |
| return "" |
| } |
| |
| func (m *ChangePb) GetCommitSequence() uint64 { |
| if m != nil && m.CommitSequence != nil { |
| return *m.CommitSequence |
| } |
| return 0 |
| } |
| |
| func (m *ChangePb) GetChangeSequence() uint64 { |
| if m != nil && m.ChangeSequence != nil { |
| return *m.ChangeSequence |
| } |
| return 0 |
| } |
| |
| func (m *ChangePb) GetCommitIndex() uint32 { |
| if m != nil && m.CommitIndex != nil { |
| return *m.CommitIndex |
| } |
| return 0 |
| } |
| |
| func (m *ChangePb) GetTransactionID() uint32 { |
| if m != nil && m.TransactionID != nil { |
| return *m.TransactionID |
| } |
| return 0 |
| } |
| |
| func (m *ChangePb) GetNewColumns() []*ColumnPb { |
| if m != nil { |
| return m.NewColumns |
| } |
| return nil |
| } |
| |
| func (m *ChangePb) GetOldColumns() []*ColumnPb { |
| if m != nil { |
| return m.OldColumns |
| } |
| return nil |
| } |
| |
| func (m *ChangePb) GetTimestamp() int64 { |
| if m != nil && m.Timestamp != nil { |
| return *m.Timestamp |
| } |
| return 0 |
| } |
| |
| func (m *ChangePb) GetTransactionIDEpoch() uint64 { |
| if m != nil && m.TransactionIDEpoch != nil { |
| return *m.TransactionIDEpoch |
| } |
| return 0 |
| } |
| |
| type ChangeListPb struct { |
| LastSequence *string `protobuf:"bytes,1,opt,name=lastSequence" json:"lastSequence,omitempty"` |
| FirstSequence *string `protobuf:"bytes,2,opt,name=firstSequence" json:"firstSequence,omitempty"` |
| Changes []*ChangePb `protobuf:"bytes,3,rep,name=changes" json:"changes,omitempty"` |
| XXX_unrecognized []byte `json:"-"` |
| } |
| |
| func (m *ChangeListPb) Reset() { *m = ChangeListPb{} } |
| func (m *ChangeListPb) String() string { return proto.CompactTextString(m) } |
| func (*ChangeListPb) ProtoMessage() {} |
| func (*ChangeListPb) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} } |
| |
| func (m *ChangeListPb) GetLastSequence() string { |
| if m != nil && m.LastSequence != nil { |
| return *m.LastSequence |
| } |
| return "" |
| } |
| |
| func (m *ChangeListPb) GetFirstSequence() string { |
| if m != nil && m.FirstSequence != nil { |
| return *m.FirstSequence |
| } |
| return "" |
| } |
| |
| func (m *ChangeListPb) GetChanges() []*ChangePb { |
| if m != nil { |
| return m.Changes |
| } |
| return nil |
| } |
| |
| type SnapshotHeaderPb struct { |
| Timestamp *string `protobuf:"bytes,1,req,name=timestamp" json:"timestamp,omitempty"` |
| Snapshot *string `protobuf:"bytes,2,req,name=snapshot" json:"snapshot,omitempty"` |
| XXX_unrecognized []byte `json:"-"` |
| } |
| |
| func (m *SnapshotHeaderPb) Reset() { *m = SnapshotHeaderPb{} } |
| func (m *SnapshotHeaderPb) String() string { return proto.CompactTextString(m) } |
| func (*SnapshotHeaderPb) ProtoMessage() {} |
| func (*SnapshotHeaderPb) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} } |
| |
| func (m *SnapshotHeaderPb) GetTimestamp() string { |
| if m != nil && m.Timestamp != nil { |
| return *m.Timestamp |
| } |
| return "" |
| } |
| |
| func (m *SnapshotHeaderPb) GetSnapshot() string { |
| if m != nil && m.Snapshot != nil { |
| return *m.Snapshot |
| } |
| return "" |
| } |
| |
| type TableHeaderPb struct { |
| Name *string `protobuf:"bytes,1,req,name=name" json:"name,omitempty"` |
| Columns []*ColumnPb `protobuf:"bytes,2,rep,name=columns" json:"columns,omitempty"` |
| XXX_unrecognized []byte `json:"-"` |
| } |
| |
| func (m *TableHeaderPb) Reset() { *m = TableHeaderPb{} } |
| func (m *TableHeaderPb) String() string { return proto.CompactTextString(m) } |
| func (*TableHeaderPb) ProtoMessage() {} |
| func (*TableHeaderPb) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} } |
| |
| func (m *TableHeaderPb) GetName() string { |
| if m != nil && m.Name != nil { |
| return *m.Name |
| } |
| return "" |
| } |
| |
| func (m *TableHeaderPb) GetColumns() []*ColumnPb { |
| if m != nil { |
| return m.Columns |
| } |
| return nil |
| } |
| |
| type RowPb struct { |
| Values []*ValuePb `protobuf:"bytes,1,rep,name=values" json:"values,omitempty"` |
| XXX_unrecognized []byte `json:"-"` |
| } |
| |
| func (m *RowPb) Reset() { *m = RowPb{} } |
| func (m *RowPb) String() string { return proto.CompactTextString(m) } |
| func (*RowPb) ProtoMessage() {} |
| func (*RowPb) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} } |
| |
| func (m *RowPb) GetValues() []*ValuePb { |
| if m != nil { |
| return m.Values |
| } |
| return nil |
| } |
| |
| type StreamMessagePb struct { |
| // Types that are valid to be assigned to Message: |
| // *StreamMessagePb_Table |
| // *StreamMessagePb_Row |
| Message isStreamMessagePb_Message `protobuf_oneof:"message"` |
| XXX_unrecognized []byte `json:"-"` |
| } |
| |
| func (m *StreamMessagePb) Reset() { *m = StreamMessagePb{} } |
| func (m *StreamMessagePb) String() string { return proto.CompactTextString(m) } |
| func (*StreamMessagePb) ProtoMessage() {} |
| func (*StreamMessagePb) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} } |
| |
| type isStreamMessagePb_Message interface { |
| isStreamMessagePb_Message() |
| } |
| |
| type StreamMessagePb_Table struct { |
| Table *TableHeaderPb `protobuf:"bytes,1,opt,name=table,oneof"` |
| } |
| type StreamMessagePb_Row struct { |
| Row *RowPb `protobuf:"bytes,2,opt,name=row,oneof"` |
| } |
| |
| func (*StreamMessagePb_Table) isStreamMessagePb_Message() {} |
| func (*StreamMessagePb_Row) isStreamMessagePb_Message() {} |
| |
| func (m *StreamMessagePb) GetMessage() isStreamMessagePb_Message { |
| if m != nil { |
| return m.Message |
| } |
| return nil |
| } |
| |
| func (m *StreamMessagePb) GetTable() *TableHeaderPb { |
| if x, ok := m.GetMessage().(*StreamMessagePb_Table); ok { |
| return x.Table |
| } |
| return nil |
| } |
| |
| func (m *StreamMessagePb) GetRow() *RowPb { |
| if x, ok := m.GetMessage().(*StreamMessagePb_Row); ok { |
| return x.Row |
| } |
| return nil |
| } |
| |
| // XXX_OneofFuncs is for the internal use of the proto package. |
| func (*StreamMessagePb) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) { |
| return _StreamMessagePb_OneofMarshaler, _StreamMessagePb_OneofUnmarshaler, _StreamMessagePb_OneofSizer, []interface{}{ |
| (*StreamMessagePb_Table)(nil), |
| (*StreamMessagePb_Row)(nil), |
| } |
| } |
| |
| func _StreamMessagePb_OneofMarshaler(msg proto.Message, b *proto.Buffer) error { |
| m := msg.(*StreamMessagePb) |
| // message |
| switch x := m.Message.(type) { |
| case *StreamMessagePb_Table: |
| b.EncodeVarint(1<<3 | proto.WireBytes) |
| if err := b.EncodeMessage(x.Table); err != nil { |
| return err |
| } |
| case *StreamMessagePb_Row: |
| b.EncodeVarint(2<<3 | proto.WireBytes) |
| if err := b.EncodeMessage(x.Row); err != nil { |
| return err |
| } |
| case nil: |
| default: |
| return fmt.Errorf("StreamMessagePb.Message has unexpected type %T", x) |
| } |
| return nil |
| } |
| |
| func _StreamMessagePb_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) { |
| m := msg.(*StreamMessagePb) |
| switch tag { |
| case 1: // message.table |
| if wire != proto.WireBytes { |
| return true, proto.ErrInternalBadWireType |
| } |
| msg := new(TableHeaderPb) |
| err := b.DecodeMessage(msg) |
| m.Message = &StreamMessagePb_Table{msg} |
| return true, err |
| case 2: // message.row |
| if wire != proto.WireBytes { |
| return true, proto.ErrInternalBadWireType |
| } |
| msg := new(RowPb) |
| err := b.DecodeMessage(msg) |
| m.Message = &StreamMessagePb_Row{msg} |
| return true, err |
| default: |
| return false, nil |
| } |
| } |
| |
| func _StreamMessagePb_OneofSizer(msg proto.Message) (n int) { |
| m := msg.(*StreamMessagePb) |
| // message |
| switch x := m.Message.(type) { |
| case *StreamMessagePb_Table: |
| s := proto.Size(x.Table) |
| n += proto.SizeVarint(1<<3 | proto.WireBytes) |
| n += proto.SizeVarint(uint64(s)) |
| n += s |
| case *StreamMessagePb_Row: |
| s := proto.Size(x.Row) |
| n += proto.SizeVarint(2<<3 | proto.WireBytes) |
| n += proto.SizeVarint(uint64(s)) |
| n += s |
| case nil: |
| default: |
| panic(fmt.Sprintf("proto: unexpected type %T in oneof", x)) |
| } |
| return n |
| } |
| |
| func init() { |
| proto.RegisterType((*ValuePb)(nil), "common.ValuePb") |
| proto.RegisterType((*ColumnPb)(nil), "common.ColumnPb") |
| proto.RegisterType((*ChangePb)(nil), "common.ChangePb") |
| proto.RegisterType((*ChangeListPb)(nil), "common.ChangeListPb") |
| proto.RegisterType((*SnapshotHeaderPb)(nil), "common.SnapshotHeaderPb") |
| proto.RegisterType((*TableHeaderPb)(nil), "common.TableHeaderPb") |
| proto.RegisterType((*RowPb)(nil), "common.RowPb") |
| proto.RegisterType((*StreamMessagePb)(nil), "common.StreamMessagePb") |
| } |
| |
| func init() { proto.RegisterFile("transicator.proto", fileDescriptor0) } |
| |
| var fileDescriptor0 = []byte{ |
| // 490 bytes of a gzipped FileDescriptorProto |
| 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x74, 0x52, 0x4d, 0x8f, 0xd3, 0x30, |
| 0x14, 0x24, 0x5f, 0x4d, 0xf3, 0xda, 0x6c, 0x5b, 0x2f, 0x8b, 0x22, 0x84, 0x60, 0x89, 0x10, 0xea, |
| 0xa9, 0x07, 0x2e, 0x5c, 0x11, 0x5f, 0xda, 0x95, 0x40, 0x42, 0x14, 0x71, 0x44, 0x72, 0x52, 0xb3, |
| 0x8d, 0x94, 0xd8, 0xc1, 0x76, 0x28, 0xfb, 0x1b, 0x38, 0xf3, 0x7f, 0x79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