message.pb.go 38.6 KB
Newer Older
1 2 3 4 5
// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: message.proto

package graphsync_message_pb

6 7 8 9 10
import (
	fmt "fmt"
	io "io"
	math "math"
	math_bits "math/bits"
Hannah Howard's avatar
Hannah Howard committed
11 12 13

	_ "github.com/gogo/protobuf/gogoproto"
	proto "github.com/gogo/protobuf/proto"
14
)
15 16 17 18 19 20 21 22 23 24

// 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.
25
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
26 27 28

type Message struct {
	// the actual data included in this message
29
	CompleteRequestList bool               `protobuf:"varint,1,opt,name=completeRequestList,proto3" json:"completeRequestList,omitempty"`
30 31 32
	Requests            []Message_Request  `protobuf:"bytes,2,rep,name=requests,proto3" json:"requests"`
	Responses           []Message_Response `protobuf:"bytes,3,rep,name=responses,proto3" json:"responses"`
	Data                []Message_Block    `protobuf:"bytes,4,rep,name=data,proto3" json:"data"`
33 34 35 36 37 38
}

func (m *Message) Reset()         { *m = Message{} }
func (m *Message) String() string { return proto.CompactTextString(m) }
func (*Message) ProtoMessage()    {}
func (*Message) Descriptor() ([]byte, []int) {
39
	return fileDescriptor_33c57e4bae7b9afd, []int{0}
40 41 42 43 44 45 46 47 48
}
func (m *Message) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Message.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
49
		n, err := m.MarshalToSizedBuffer(b)
50 51 52 53 54 55
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
56 57
func (m *Message) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Message.Merge(m, src)
58 59 60 61 62 63 64 65 66 67
}
func (m *Message) XXX_Size() int {
	return m.Size()
}
func (m *Message) XXX_DiscardUnknown() {
	xxx_messageInfo_Message.DiscardUnknown(m)
}

var xxx_messageInfo_Message proto.InternalMessageInfo

68
func (m *Message) GetCompleteRequestList() bool {
69
	if m != nil {
70 71 72 73 74 75 76 77 78 79 80 81 82 83 84
		return m.CompleteRequestList
	}
	return false
}

func (m *Message) GetRequests() []Message_Request {
	if m != nil {
		return m.Requests
	}
	return nil
}

func (m *Message) GetResponses() []Message_Response {
	if m != nil {
		return m.Responses
85 86 87 88
	}
	return nil
}

89
func (m *Message) GetData() []Message_Block {
90
	if m != nil {
91
		return m.Data
92 93 94 95 96
	}
	return nil
}

type Message_Request struct {
97 98 99
	Id         int32             `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Root       []byte            `protobuf:"bytes,2,opt,name=root,proto3" json:"root,omitempty"`
	Selector   []byte            `protobuf:"bytes,3,opt,name=selector,proto3" json:"selector,omitempty"`
100
	Extensions map[string][]byte `protobuf:"bytes,4,rep,name=extensions,proto3" json:"extensions,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
101 102
	Priority   int32             `protobuf:"varint,5,opt,name=priority,proto3" json:"priority,omitempty"`
	Cancel     bool              `protobuf:"varint,6,opt,name=cancel,proto3" json:"cancel,omitempty"`
Hannah Howard's avatar
Hannah Howard committed
103
	Update     bool              `protobuf:"varint,7,opt,name=update,proto3" json:"update,omitempty"`
104 105 106 107 108 109
}

func (m *Message_Request) Reset()         { *m = Message_Request{} }
func (m *Message_Request) String() string { return proto.CompactTextString(m) }
func (*Message_Request) ProtoMessage()    {}
func (*Message_Request) Descriptor() ([]byte, []int) {
110
	return fileDescriptor_33c57e4bae7b9afd, []int{0, 0}
111 112 113 114 115 116 117 118 119
}
func (m *Message_Request) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Message_Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Message_Request.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
120
		n, err := m.MarshalToSizedBuffer(b)
121 122 123 124 125 126
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
127 128
func (m *Message_Request) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Message_Request.Merge(m, src)
129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145
}
func (m *Message_Request) XXX_Size() int {
	return m.Size()
}
func (m *Message_Request) XXX_DiscardUnknown() {
	xxx_messageInfo_Message_Request.DiscardUnknown(m)
}

var xxx_messageInfo_Message_Request proto.InternalMessageInfo

func (m *Message_Request) GetId() int32 {
	if m != nil {
		return m.Id
	}
	return 0
}

146 147 148 149 150 151 152
func (m *Message_Request) GetRoot() []byte {
	if m != nil {
		return m.Root
	}
	return nil
}

153 154 155 156 157 158 159
func (m *Message_Request) GetSelector() []byte {
	if m != nil {
		return m.Selector
	}
	return nil
}

160
func (m *Message_Request) GetExtensions() map[string][]byte {
161
	if m != nil {
162
		return m.Extensions
163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180
	}
	return nil
}

func (m *Message_Request) GetPriority() int32 {
	if m != nil {
		return m.Priority
	}
	return 0
}

func (m *Message_Request) GetCancel() bool {
	if m != nil {
		return m.Cancel
	}
	return false
}

Hannah Howard's avatar
Hannah Howard committed
181 182 183 184 185 186 187
func (m *Message_Request) GetUpdate() bool {
	if m != nil {
		return m.Update
	}
	return false
}

188
type Message_Response struct {
189 190
	Id         int32             `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Status     int32             `protobuf:"varint,2,opt,name=status,proto3" json:"status,omitempty"`
191
	Extensions map[string][]byte `protobuf:"bytes,3,rep,name=extensions,proto3" json:"extensions,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
192 193 194 195 196 197
}

func (m *Message_Response) Reset()         { *m = Message_Response{} }
func (m *Message_Response) String() string { return proto.CompactTextString(m) }
func (*Message_Response) ProtoMessage()    {}
func (*Message_Response) Descriptor() ([]byte, []int) {
198
	return fileDescriptor_33c57e4bae7b9afd, []int{0, 1}
199 200 201 202 203 204 205 206 207
}
func (m *Message_Response) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Message_Response) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Message_Response.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
208
		n, err := m.MarshalToSizedBuffer(b)
209 210 211 212 213 214
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
215 216
func (m *Message_Response) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Message_Response.Merge(m, src)
217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240
}
func (m *Message_Response) XXX_Size() int {
	return m.Size()
}
func (m *Message_Response) XXX_DiscardUnknown() {
	xxx_messageInfo_Message_Response.DiscardUnknown(m)
}

var xxx_messageInfo_Message_Response proto.InternalMessageInfo

func (m *Message_Response) GetId() int32 {
	if m != nil {
		return m.Id
	}
	return 0
}

func (m *Message_Response) GetStatus() int32 {
	if m != nil {
		return m.Status
	}
	return 0
}

241
func (m *Message_Response) GetExtensions() map[string][]byte {
242
	if m != nil {
243
		return m.Extensions
244 245 246 247
	}
	return nil
}

248 249 250 251 252 253 254 255 256
type Message_Block struct {
	Prefix []byte `protobuf:"bytes,1,opt,name=prefix,proto3" json:"prefix,omitempty"`
	Data   []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
}

func (m *Message_Block) Reset()         { *m = Message_Block{} }
func (m *Message_Block) String() string { return proto.CompactTextString(m) }
func (*Message_Block) ProtoMessage()    {}
func (*Message_Block) Descriptor() ([]byte, []int) {
257
	return fileDescriptor_33c57e4bae7b9afd, []int{0, 2}
258 259 260 261 262 263 264 265 266
}
func (m *Message_Block) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Message_Block) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Message_Block.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
267
		n, err := m.MarshalToSizedBuffer(b)
268 269 270 271 272 273
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
274 275
func (m *Message_Block) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Message_Block.Merge(m, src)
276 277 278 279 280 281 282 283 284 285 286
}
func (m *Message_Block) XXX_Size() int {
	return m.Size()
}
func (m *Message_Block) XXX_DiscardUnknown() {
	xxx_messageInfo_Message_Block.DiscardUnknown(m)
}

var xxx_messageInfo_Message_Block proto.InternalMessageInfo

func (m *Message_Block) GetPrefix() []byte {
287
	if m != nil {
288 289 290 291 292 293 294 295
		return m.Prefix
	}
	return nil
}

func (m *Message_Block) GetData() []byte {
	if m != nil {
		return m.Data
296 297 298 299 300 301 302
	}
	return nil
}

func init() {
	proto.RegisterType((*Message)(nil), "graphsync.message.pb.Message")
	proto.RegisterType((*Message_Request)(nil), "graphsync.message.pb.Message.Request")
303
	proto.RegisterMapType((map[string][]byte)(nil), "graphsync.message.pb.Message.Request.ExtensionsEntry")
304
	proto.RegisterType((*Message_Response)(nil), "graphsync.message.pb.Message.Response")
305
	proto.RegisterMapType((map[string][]byte)(nil), "graphsync.message.pb.Message.Response.ExtensionsEntry")
306
	proto.RegisterType((*Message_Block)(nil), "graphsync.message.pb.Message.Block")
307
}
308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343

func init() { proto.RegisterFile("message.proto", fileDescriptor_33c57e4bae7b9afd) }

var fileDescriptor_33c57e4bae7b9afd = []byte{
	// 458 bytes of a gzipped FileDescriptorProto
	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x53, 0xcb, 0x6e, 0xd3, 0x40,
	0x14, 0x8d, 0x9d, 0xd8, 0x49, 0x2f, 0xe5, 0xa1, 0xa1, 0xaa, 0x46, 0x5e, 0x98, 0x08, 0x04, 0xca,
	0x06, 0x17, 0x51, 0x81, 0x10, 0x52, 0x37, 0x91, 0x2a, 0x24, 0x04, 0x9b, 0x91, 0x60, 0xef, 0x38,
	0xb7, 0xae, 0x55, 0xc7, 0x63, 0x66, 0xc6, 0xa8, 0xfe, 0x0b, 0xfe, 0x83, 0x7f, 0x60, 0x5d, 0x76,
	0x5d, 0xb2, 0x42, 0x28, 0xf9, 0x11, 0xe4, 0x3b, 0x83, 0x79, 0x55, 0xa5, 0x12, 0xbb, 0x7b, 0xee,
	0xcc, 0x39, 0xf7, 0x71, 0x66, 0xe0, 0xfa, 0x0a, 0xb5, 0x4e, 0x73, 0x4c, 0x6a, 0x25, 0x8d, 0x64,
	0x3b, 0xb9, 0x4a, 0xeb, 0x63, 0xdd, 0x56, 0x59, 0xd2, 0x1f, 0x2c, 0xa2, 0x87, 0x79, 0x61, 0x8e,
	0x9b, 0x45, 0x92, 0xc9, 0xd5, 0x5e, 0x2e, 0x73, 0xb9, 0x47, 0x97, 0x17, 0xcd, 0x11, 0x21, 0x02,
	0x14, 0x59, 0x91, 0xbb, 0x9f, 0x42, 0x18, 0xbf, 0xb6, 0x6c, 0xf6, 0x08, 0x6e, 0x67, 0x72, 0x55,
	0x97, 0x68, 0x50, 0xe0, 0xbb, 0x06, 0xb5, 0x79, 0x55, 0x68, 0xc3, 0xbd, 0xa9, 0x37, 0x9b, 0x88,
	0x8b, 0x8e, 0xd8, 0x0b, 0x98, 0x28, 0x0b, 0x35, 0xf7, 0xa7, 0xc3, 0xd9, 0xb5, 0xc7, 0xf7, 0x93,
	0x8b, 0xba, 0x4a, 0x5c, 0x89, 0xc4, 0x91, 0xe7, 0xa3, 0xb3, 0xaf, 0x77, 0x06, 0xa2, 0x27, 0xb3,
	0x97, 0xb0, 0xa5, 0x50, 0xd7, 0xb2, 0xd2, 0xa8, 0xf9, 0x90, 0x94, 0x1e, 0xfc, 0x4b, 0xc9, 0x5e,
	0x77, 0x52, 0x3f, 0xe9, 0xec, 0x00, 0x46, 0xcb, 0xd4, 0xa4, 0x7c, 0x44, 0x32, 0xf7, 0x2e, 0x97,
	0x99, 0x97, 0x32, 0x3b, 0x71, 0x1a, 0x44, 0x8b, 0x3e, 0xfa, 0x30, 0x76, 0x6d, 0xb2, 0x1b, 0xe0,
	0x17, 0x4b, 0x5a, 0x40, 0x20, 0xfc, 0x62, 0xc9, 0x18, 0x8c, 0x94, 0x94, 0x86, 0xfb, 0x53, 0x6f,
	0xb6, 0x2d, 0x28, 0x66, 0x11, 0x4c, 0x34, 0x96, 0x98, 0x19, 0xa9, 0xf8, 0x90, 0xf2, 0x3d, 0x66,
	0x6f, 0x00, 0xf0, 0xd4, 0x60, 0xa5, 0x0b, 0x59, 0x69, 0xd7, 0xd0, 0x93, 0x2b, 0x6d, 0x28, 0x39,
	0xec, 0x79, 0x87, 0x95, 0x51, 0xad, 0xf8, 0x45, 0xa8, 0x2b, 0x59, 0xab, 0x42, 0xaa, 0xc2, 0xb4,
	0x3c, 0xa0, 0xe6, 0x7a, 0xcc, 0x76, 0x21, 0xcc, 0xd2, 0x2a, 0xc3, 0x92, 0x87, 0xe4, 0x9b, 0x43,
	0x5d, 0xbe, 0xa9, 0x97, 0xa9, 0x41, 0x3e, 0xb6, 0x79, 0x8b, 0xa2, 0x03, 0xb8, 0xf9, 0x47, 0x29,
	0x76, 0x0b, 0x86, 0x27, 0xd8, 0xd2, 0xd8, 0x5b, 0xa2, 0x0b, 0xd9, 0x0e, 0x04, 0xef, 0xd3, 0xb2,
	0x41, 0x37, 0xb8, 0x05, 0xcf, 0xfd, 0x67, 0x5e, 0xf4, 0xd9, 0x83, 0xc9, 0x0f, 0x2b, 0xfe, 0x5a,
	0xd7, 0x2e, 0x84, 0xda, 0xa4, 0xa6, 0xd1, 0xc4, 0x0b, 0x84, 0x43, 0xec, 0xed, 0x6f, 0x6b, 0xb1,
	0x76, 0x3f, 0xbd, 0x9a, 0xdd, 0x97, 0xed, 0xe5, 0x7f, 0x67, 0xd9, 0x87, 0x80, 0x9e, 0x43, 0xd7,
	0x77, 0xad, 0xf0, 0xa8, 0x38, 0x25, 0xde, 0xb6, 0x70, 0xa8, 0xb3, 0x9f, 0x5e, 0x96, 0xb3, 0xbf,
	0x8b, 0xe7, 0xfc, 0x6c, 0x1d, 0x7b, 0xe7, 0xeb, 0xd8, 0xfb, 0xb6, 0x8e, 0xbd, 0x0f, 0x9b, 0x78,
	0x70, 0xbe, 0x89, 0x07, 0x5f, 0x36, 0xf1, 0x60, 0x11, 0xd2, 0x0f, 0xdb, 0xff, 0x1e, 0x00, 0x00,
	0xff, 0xff, 0xaa, 0x5e, 0x01, 0x7e, 0xb7, 0x03, 0x00, 0x00,
}

344 345 346
func (m *Message) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
347
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
348 349 350 351 352 353 354
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Message) MarshalTo(dAtA []byte) (int, error) {
355 356 357 358 359 360
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Message) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
361 362 363
	_ = i
	var l int
	_ = l
364 365 366 367 368 369 370 371 372
	if len(m.Data) > 0 {
		for iNdEx := len(m.Data) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Data[iNdEx].MarshalToSizedBuffer(dAtA[:i])
				if err != nil {
					return 0, err
				}
				i -= size
				i = encodeVarintMessage(dAtA, i, uint64(size))
373
			}
374 375
			i--
			dAtA[i] = 0x22
376 377
		}
	}
378
	if len(m.Responses) > 0 {
379 380 381 382 383 384 385 386
		for iNdEx := len(m.Responses) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Responses[iNdEx].MarshalToSizedBuffer(dAtA[:i])
				if err != nil {
					return 0, err
				}
				i -= size
				i = encodeVarintMessage(dAtA, i, uint64(size))
387
			}
388 389
			i--
			dAtA[i] = 0x1a
390 391
		}
	}
392 393 394 395 396 397 398 399 400
	if len(m.Requests) > 0 {
		for iNdEx := len(m.Requests) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Requests[iNdEx].MarshalToSizedBuffer(dAtA[:i])
				if err != nil {
					return 0, err
				}
				i -= size
				i = encodeVarintMessage(dAtA, i, uint64(size))
401
			}
402 403 404 405 406 407 408 409 410 411
			i--
			dAtA[i] = 0x12
		}
	}
	if m.CompleteRequestList {
		i--
		if m.CompleteRequestList {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
412
		}
413 414
		i--
		dAtA[i] = 0x8
415
	}
416
	return len(dAtA) - i, nil
417 418 419 420 421
}

func (m *Message_Request) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
422
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
423 424 425 426 427 428 429
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Message_Request) MarshalTo(dAtA []byte) (int, error) {
430 431 432 433 434 435
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Message_Request) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
436 437 438
	_ = i
	var l int
	_ = l
439 440 441 442 443 444 445 446 447
	if m.Update {
		i--
		if m.Update {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i--
		dAtA[i] = 0x38
448
	}
449 450 451 452 453 454 455 456 457
	if m.Cancel {
		i--
		if m.Cancel {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i--
		dAtA[i] = 0x30
458
	}
459 460 461 462
	if m.Priority != 0 {
		i = encodeVarintMessage(dAtA, i, uint64(m.Priority))
		i--
		dAtA[i] = 0x28
463
	}
464
	if len(m.Extensions) > 0 {
465
		for k := range m.Extensions {
466
			v := m.Extensions[k]
467
			baseI := i
468
			if len(v) > 0 {
469 470
				i -= len(v)
				copy(dAtA[i:], v)
471
				i = encodeVarintMessage(dAtA, i, uint64(len(v)))
472 473
				i--
				dAtA[i] = 0x12
474
			}
475 476 477 478 479 480 481 482
			i -= len(k)
			copy(dAtA[i:], k)
			i = encodeVarintMessage(dAtA, i, uint64(len(k)))
			i--
			dAtA[i] = 0xa
			i = encodeVarintMessage(dAtA, i, uint64(baseI-i))
			i--
			dAtA[i] = 0x22
483
		}
484
	}
485 486 487 488 489 490
	if len(m.Selector) > 0 {
		i -= len(m.Selector)
		copy(dAtA[i:], m.Selector)
		i = encodeVarintMessage(dAtA, i, uint64(len(m.Selector)))
		i--
		dAtA[i] = 0x1a
491
	}
492 493 494 495 496 497
	if len(m.Root) > 0 {
		i -= len(m.Root)
		copy(dAtA[i:], m.Root)
		i = encodeVarintMessage(dAtA, i, uint64(len(m.Root)))
		i--
		dAtA[i] = 0x12
498
	}
499 500 501 502
	if m.Id != 0 {
		i = encodeVarintMessage(dAtA, i, uint64(m.Id))
		i--
		dAtA[i] = 0x8
Hannah Howard's avatar
Hannah Howard committed
503
	}
504
	return len(dAtA) - i, nil
505 506 507 508 509
}

func (m *Message_Response) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
510
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
511 512 513 514 515 516 517
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Message_Response) MarshalTo(dAtA []byte) (int, error) {
518 519 520 521 522 523
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Message_Response) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
524 525 526
	_ = i
	var l int
	_ = l
527
	if len(m.Extensions) > 0 {
528
		for k := range m.Extensions {
529
			v := m.Extensions[k]
530
			baseI := i
531
			if len(v) > 0 {
532 533
				i -= len(v)
				copy(dAtA[i:], v)
534
				i = encodeVarintMessage(dAtA, i, uint64(len(v)))
535 536
				i--
				dAtA[i] = 0x12
537
			}
538 539 540 541 542 543 544 545
			i -= len(k)
			copy(dAtA[i:], k)
			i = encodeVarintMessage(dAtA, i, uint64(len(k)))
			i--
			dAtA[i] = 0xa
			i = encodeVarintMessage(dAtA, i, uint64(baseI-i))
			i--
			dAtA[i] = 0x1a
546
		}
547
	}
548 549 550 551 552 553 554 555 556 557 558
	if m.Status != 0 {
		i = encodeVarintMessage(dAtA, i, uint64(m.Status))
		i--
		dAtA[i] = 0x10
	}
	if m.Id != 0 {
		i = encodeVarintMessage(dAtA, i, uint64(m.Id))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
559 560
}

561 562 563
func (m *Message_Block) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
564
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
565 566 567 568 569 570 571
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Message_Block) MarshalTo(dAtA []byte) (int, error) {
572 573 574 575 576 577
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Message_Block) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
578 579 580 581
	_ = i
	var l int
	_ = l
	if len(m.Data) > 0 {
582 583
		i -= len(m.Data)
		copy(dAtA[i:], m.Data)
584
		i = encodeVarintMessage(dAtA, i, uint64(len(m.Data)))
585 586
		i--
		dAtA[i] = 0x12
587
	}
588 589 590 591 592 593 594 595
	if len(m.Prefix) > 0 {
		i -= len(m.Prefix)
		copy(dAtA[i:], m.Prefix)
		i = encodeVarintMessage(dAtA, i, uint64(len(m.Prefix)))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
596 597
}

598
func encodeVarintMessage(dAtA []byte, offset int, v uint64) int {
599 600
	offset -= sovMessage(v)
	base := offset
601 602 603 604 605 606
	for v >= 1<<7 {
		dAtA[offset] = uint8(v&0x7f | 0x80)
		v >>= 7
		offset++
	}
	dAtA[offset] = uint8(v)
607
	return base
608 609 610 611 612 613 614
}
func (m *Message) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
615 616 617 618 619
	if m.CompleteRequestList {
		n += 2
	}
	if len(m.Requests) > 0 {
		for _, e := range m.Requests {
620 621 622 623
			l = e.Size()
			n += 1 + l + sovMessage(uint64(l))
		}
	}
624 625 626 627 628 629 630 631
	if len(m.Responses) > 0 {
		for _, e := range m.Responses {
			l = e.Size()
			n += 1 + l + sovMessage(uint64(l))
		}
	}
	if len(m.Data) > 0 {
		for _, e := range m.Data {
632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647
			l = e.Size()
			n += 1 + l + sovMessage(uint64(l))
		}
	}
	return n
}

func (m *Message_Request) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Id != 0 {
		n += 1 + sovMessage(uint64(m.Id))
	}
648 649 650 651
	l = len(m.Root)
	if l > 0 {
		n += 1 + l + sovMessage(uint64(l))
	}
652 653 654 655
	l = len(m.Selector)
	if l > 0 {
		n += 1 + l + sovMessage(uint64(l))
	}
656 657 658 659 660 661 662 663 664 665 666
	if len(m.Extensions) > 0 {
		for k, v := range m.Extensions {
			_ = k
			_ = v
			l = 0
			if len(v) > 0 {
				l = 1 + len(v) + sovMessage(uint64(len(v)))
			}
			mapEntrySize := 1 + len(k) + sovMessage(uint64(len(k))) + l
			n += mapEntrySize + 1 + sovMessage(uint64(mapEntrySize))
		}
667 668 669 670 671 672 673
	}
	if m.Priority != 0 {
		n += 1 + sovMessage(uint64(m.Priority))
	}
	if m.Cancel {
		n += 2
	}
Hannah Howard's avatar
Hannah Howard committed
674 675 676
	if m.Update {
		n += 2
	}
677 678 679 680 681 682 683 684 685 686 687 688 689 690 691
	return n
}

func (m *Message_Response) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Id != 0 {
		n += 1 + sovMessage(uint64(m.Id))
	}
	if m.Status != 0 {
		n += 1 + sovMessage(uint64(m.Status))
	}
692 693 694 695 696 697 698 699 700 701 702
	if len(m.Extensions) > 0 {
		for k, v := range m.Extensions {
			_ = k
			_ = v
			l = 0
			if len(v) > 0 {
				l = 1 + len(v) + sovMessage(uint64(len(v)))
			}
			mapEntrySize := 1 + len(k) + sovMessage(uint64(len(k))) + l
			n += mapEntrySize + 1 + sovMessage(uint64(mapEntrySize))
		}
703
	}
704 705 706 707 708 709 710 711 712 713 714 715 716 717
	return n
}

func (m *Message_Block) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Prefix)
	if l > 0 {
		n += 1 + l + sovMessage(uint64(l))
	}
	l = len(m.Data)
718 719 720 721 722 723 724
	if l > 0 {
		n += 1 + l + sovMessage(uint64(l))
	}
	return n
}

func sovMessage(x uint64) (n int) {
725
	return (math_bits.Len64(x|1) + 6) / 7
726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744
}
func sozMessage(x uint64) (n int) {
	return sovMessage(uint64((x << 1) ^ uint64((int64(x) >> 63))))
}
func (m *Message) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowMessage
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
745
			wire |= uint64(b&0x7F) << shift
746 747 748 749 750 751 752 753 754 755 756 757 758 759
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Message: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Message: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
760 761 762 763 764 765 766 767 768 769 770 771 772
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field CompleteRequestList", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
773
				v |= int(b&0x7F) << shift
774 775 776 777 778 779
				if b < 0x80 {
					break
				}
			}
			m.CompleteRequestList = bool(v != 0)
		case 2:
780
			if wireType != 2 {
781
				return fmt.Errorf("proto: wrong wireType = %d for field Requests", wireType)
782 783 784 785 786 787 788 789 790 791 792
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
793
				msglen |= int(b&0x7F) << shift
794 795 796 797 798 799 800 801
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthMessage
			}
			postIndex := iNdEx + msglen
802 803 804
			if postIndex < 0 {
				return ErrInvalidLengthMessage
			}
805 806 807
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
808 809
			m.Requests = append(m.Requests, Message_Request{})
			if err := m.Requests[len(m.Requests)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
810 811 812
				return err
			}
			iNdEx = postIndex
813
		case 3:
814
			if wireType != 2 {
815
				return fmt.Errorf("proto: wrong wireType = %d for field Responses", wireType)
816 817 818 819 820 821 822 823 824 825 826
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
827
				msglen |= int(b&0x7F) << shift
828 829 830 831 832 833 834 835
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthMessage
			}
			postIndex := iNdEx + msglen
836 837 838
			if postIndex < 0 {
				return ErrInvalidLengthMessage
			}
839 840 841
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860
			m.Responses = append(m.Responses, Message_Response{})
			if err := m.Responses[len(m.Responses)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
861
				msglen |= int(b&0x7F) << shift
862 863 864 865 866 867 868 869
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthMessage
			}
			postIndex := iNdEx + msglen
870 871 872
			if postIndex < 0 {
				return ErrInvalidLengthMessage
			}
873 874 875 876 877
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Data = append(m.Data, Message_Block{})
			if err := m.Data[len(m.Data)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
878 879 880 881 882 883 884 885 886 887 888 889
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipMessage(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthMessage
			}
890 891 892
			if (iNdEx + skippy) < 0 {
				return ErrInvalidLengthMessage
			}
893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Message_Request) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowMessage
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
920
			wire |= uint64(b&0x7F) << shift
921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Request: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Request: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			m.Id = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
948
				m.Id |= int32(b&0x7F) << shift
949 950 951 952 953
				if b < 0x80 {
					break
				}
			}
		case 2:
954 955 956 957 958 959 960 961 962 963 964 965 966
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Root", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
967
				byteLen |= int(b&0x7F) << shift
968 969 970 971 972 973 974 975
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthMessage
			}
			postIndex := iNdEx + byteLen
976 977 978
			if postIndex < 0 {
				return ErrInvalidLengthMessage
			}
979 980 981 982 983 984 985 986 987
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Root = append(m.Root[:0], dAtA[iNdEx:postIndex]...)
			if m.Root == nil {
				m.Root = []byte{}
			}
			iNdEx = postIndex
		case 3:
988 989 990 991 992 993 994 995 996 997 998 999 1000
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1001
				byteLen |= int(b&0x7F) << shift
1002 1003 1004 1005 1006 1007 1008 1009
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthMessage
			}
			postIndex := iNdEx + byteLen
1010 1011 1012
			if postIndex < 0 {
				return ErrInvalidLengthMessage
			}
1013 1014 1015 1016 1017 1018 1019 1020
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Selector = append(m.Selector[:0], dAtA[iNdEx:postIndex]...)
			if m.Selector == nil {
				m.Selector = []byte{}
			}
			iNdEx = postIndex
1021
		case 4:
1022
			if wireType != 2 {
1023
				return fmt.Errorf("proto: wrong wireType = %d for field Extensions", wireType)
1024
			}
1025
			var msglen int
1026 1027 1028 1029 1030 1031 1032 1033 1034
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1035
				msglen |= int(b&0x7F) << shift
1036 1037 1038 1039
				if b < 0x80 {
					break
				}
			}
1040
			if msglen < 0 {
1041 1042
				return ErrInvalidLengthMessage
			}
1043
			postIndex := iNdEx + msglen
1044 1045 1046
			if postIndex < 0 {
				return ErrInvalidLengthMessage
			}
1047 1048 1049
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
1050 1051
			if m.Extensions == nil {
				m.Extensions = make(map[string][]byte)
1052
			}
1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066
			var mapkey string
			mapvalue := []byte{}
			for iNdEx < postIndex {
				entryPreIndex := iNdEx
				var wire uint64
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return ErrIntOverflowMessage
					}
					if iNdEx >= l {
						return io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
1067
					wire |= uint64(b&0x7F) << shift
1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083
					if b < 0x80 {
						break
					}
				}
				fieldNum := int32(wire >> 3)
				if fieldNum == 1 {
					var stringLenmapkey uint64
					for shift := uint(0); ; shift += 7 {
						if shift >= 64 {
							return ErrIntOverflowMessage
						}
						if iNdEx >= l {
							return io.ErrUnexpectedEOF
						}
						b := dAtA[iNdEx]
						iNdEx++
1084
						stringLenmapkey |= uint64(b&0x7F) << shift
1085 1086 1087 1088 1089 1090 1091 1092 1093
						if b < 0x80 {
							break
						}
					}
					intStringLenmapkey := int(stringLenmapkey)
					if intStringLenmapkey < 0 {
						return ErrInvalidLengthMessage
					}
					postStringIndexmapkey := iNdEx + intStringLenmapkey
1094 1095 1096
					if postStringIndexmapkey < 0 {
						return ErrInvalidLengthMessage
					}
1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112
					if postStringIndexmapkey > l {
						return io.ErrUnexpectedEOF
					}
					mapkey = string(dAtA[iNdEx:postStringIndexmapkey])
					iNdEx = postStringIndexmapkey
				} else if fieldNum == 2 {
					var mapbyteLen uint64
					for shift := uint(0); ; shift += 7 {
						if shift >= 64 {
							return ErrIntOverflowMessage
						}
						if iNdEx >= l {
							return io.ErrUnexpectedEOF
						}
						b := dAtA[iNdEx]
						iNdEx++
1113
						mapbyteLen |= uint64(b&0x7F) << shift
1114 1115 1116 1117 1118 1119 1120 1121 1122
						if b < 0x80 {
							break
						}
					}
					intMapbyteLen := int(mapbyteLen)
					if intMapbyteLen < 0 {
						return ErrInvalidLengthMessage
					}
					postbytesIndex := iNdEx + intMapbyteLen
1123 1124 1125
					if postbytesIndex < 0 {
						return ErrInvalidLengthMessage
					}
1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147
					if postbytesIndex > l {
						return io.ErrUnexpectedEOF
					}
					mapvalue = make([]byte, mapbyteLen)
					copy(mapvalue, dAtA[iNdEx:postbytesIndex])
					iNdEx = postbytesIndex
				} else {
					iNdEx = entryPreIndex
					skippy, err := skipMessage(dAtA[iNdEx:])
					if err != nil {
						return err
					}
					if skippy < 0 {
						return ErrInvalidLengthMessage
					}
					if (iNdEx + skippy) > postIndex {
						return io.ErrUnexpectedEOF
					}
					iNdEx += skippy
				}
			}
			m.Extensions[mapkey] = mapvalue
1148
			iNdEx = postIndex
1149
		case 5:
1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Priority", wireType)
			}
			m.Priority = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1163
				m.Priority |= int32(b&0x7F) << shift
1164 1165 1166 1167
				if b < 0x80 {
					break
				}
			}
1168
		case 6:
1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Cancel", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1182
				v |= int(b&0x7F) << shift
1183 1184 1185 1186 1187
				if b < 0x80 {
					break
				}
			}
			m.Cancel = bool(v != 0)
Hannah Howard's avatar
Hannah Howard committed
1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201
		case 7:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Update", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1202
				v |= int(b&0x7F) << shift
Hannah Howard's avatar
Hannah Howard committed
1203 1204 1205 1206 1207
				if b < 0x80 {
					break
				}
			}
			m.Update = bool(v != 0)
1208 1209 1210 1211 1212 1213 1214 1215 1216
		default:
			iNdEx = preIndex
			skippy, err := skipMessage(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthMessage
			}
1217 1218 1219
			if (iNdEx + skippy) < 0 {
				return ErrInvalidLengthMessage
			}
1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Message_Response) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowMessage
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
1247
			wire |= uint64(b&0x7F) << shift
1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Response: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Response: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			m.Id = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1275
				m.Id |= int32(b&0x7F) << shift
1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
			}
			m.Status = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1294
				m.Status |= int32(b&0x7F) << shift
1295 1296 1297 1298 1299 1300
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
1301
				return fmt.Errorf("proto: wrong wireType = %d for field Extensions", wireType)
1302
			}
1303
			var msglen int
1304 1305 1306 1307 1308 1309 1310 1311 1312
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1313
				msglen |= int(b&0x7F) << shift
1314 1315 1316 1317
				if b < 0x80 {
					break
				}
			}
1318
			if msglen < 0 {
1319 1320
				return ErrInvalidLengthMessage
			}
1321
			postIndex := iNdEx + msglen
1322 1323 1324
			if postIndex < 0 {
				return ErrInvalidLengthMessage
			}
1325 1326 1327
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344
			if m.Extensions == nil {
				m.Extensions = make(map[string][]byte)
			}
			var mapkey string
			mapvalue := []byte{}
			for iNdEx < postIndex {
				entryPreIndex := iNdEx
				var wire uint64
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return ErrIntOverflowMessage
					}
					if iNdEx >= l {
						return io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
1345
					wire |= uint64(b&0x7F) << shift
1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361
					if b < 0x80 {
						break
					}
				}
				fieldNum := int32(wire >> 3)
				if fieldNum == 1 {
					var stringLenmapkey uint64
					for shift := uint(0); ; shift += 7 {
						if shift >= 64 {
							return ErrIntOverflowMessage
						}
						if iNdEx >= l {
							return io.ErrUnexpectedEOF
						}
						b := dAtA[iNdEx]
						iNdEx++
1362
						stringLenmapkey |= uint64(b&0x7F) << shift
1363 1364 1365 1366 1367 1368 1369 1370 1371
						if b < 0x80 {
							break
						}
					}
					intStringLenmapkey := int(stringLenmapkey)
					if intStringLenmapkey < 0 {
						return ErrInvalidLengthMessage
					}
					postStringIndexmapkey := iNdEx + intStringLenmapkey
1372 1373 1374
					if postStringIndexmapkey < 0 {
						return ErrInvalidLengthMessage
					}
1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390
					if postStringIndexmapkey > l {
						return io.ErrUnexpectedEOF
					}
					mapkey = string(dAtA[iNdEx:postStringIndexmapkey])
					iNdEx = postStringIndexmapkey
				} else if fieldNum == 2 {
					var mapbyteLen uint64
					for shift := uint(0); ; shift += 7 {
						if shift >= 64 {
							return ErrIntOverflowMessage
						}
						if iNdEx >= l {
							return io.ErrUnexpectedEOF
						}
						b := dAtA[iNdEx]
						iNdEx++
1391
						mapbyteLen |= uint64(b&0x7F) << shift
1392 1393 1394 1395 1396 1397 1398 1399 1400
						if b < 0x80 {
							break
						}
					}
					intMapbyteLen := int(mapbyteLen)
					if intMapbyteLen < 0 {
						return ErrInvalidLengthMessage
					}
					postbytesIndex := iNdEx + intMapbyteLen
1401 1402 1403
					if postbytesIndex < 0 {
						return ErrInvalidLengthMessage
					}
1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423
					if postbytesIndex > l {
						return io.ErrUnexpectedEOF
					}
					mapvalue = make([]byte, mapbyteLen)
					copy(mapvalue, dAtA[iNdEx:postbytesIndex])
					iNdEx = postbytesIndex
				} else {
					iNdEx = entryPreIndex
					skippy, err := skipMessage(dAtA[iNdEx:])
					if err != nil {
						return err
					}
					if skippy < 0 {
						return ErrInvalidLengthMessage
					}
					if (iNdEx + skippy) > postIndex {
						return io.ErrUnexpectedEOF
					}
					iNdEx += skippy
				}
1424
			}
1425
			m.Extensions[mapkey] = mapvalue
1426
			iNdEx = postIndex
1427 1428 1429 1430 1431 1432 1433 1434 1435
		default:
			iNdEx = preIndex
			skippy, err := skipMessage(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthMessage
			}
1436 1437 1438
			if (iNdEx + skippy) < 0 {
				return ErrInvalidLengthMessage
			}
1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Message_Block) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowMessage
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
1466
			wire |= uint64(b&0x7F) << shift
1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Block: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Block: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
1481
			if wireType != 2 {
1482
				return fmt.Errorf("proto: wrong wireType = %d for field Prefix", wireType)
1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1494
				byteLen |= int(b&0x7F) << shift
1495 1496 1497 1498 1499 1500 1501 1502
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthMessage
			}
			postIndex := iNdEx + byteLen
1503 1504 1505
			if postIndex < 0 {
				return ErrInvalidLengthMessage
			}
1506 1507 1508
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527
			m.Prefix = append(m.Prefix[:0], dAtA[iNdEx:postIndex]...)
			if m.Prefix == nil {
				m.Prefix = []byte{}
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
1528
				byteLen |= int(b&0x7F) << shift
1529 1530 1531 1532 1533 1534 1535 1536
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthMessage
			}
			postIndex := iNdEx + byteLen
1537 1538 1539
			if postIndex < 0 {
				return ErrInvalidLengthMessage
			}
1540 1541 1542 1543 1544 1545
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
			if m.Data == nil {
				m.Data = []byte{}
1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipMessage(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthMessage
			}
1557 1558 1559
			if (iNdEx + skippy) < 0 {
				return ErrInvalidLengthMessage
			}
1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func skipMessage(dAtA []byte) (n int, err error) {
	l := len(dAtA)
	iNdEx := 0
1575
	depth := 0
1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627
	for iNdEx < l {
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return 0, ErrIntOverflowMessage
			}
			if iNdEx >= l {
				return 0, io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		wireType := int(wire & 0x7)
		switch wireType {
		case 0:
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				iNdEx++
				if dAtA[iNdEx-1] < 0x80 {
					break
				}
			}
		case 1:
			iNdEx += 8
		case 2:
			var length int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowMessage
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				length |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if length < 0 {
				return 0, ErrInvalidLengthMessage
			}
1628
			iNdEx += length
1629
		case 3:
1630
			depth++
1631
		case 4:
1632 1633 1634 1635
			if depth == 0 {
				return 0, ErrUnexpectedEndOfGroupMessage
			}
			depth--
1636 1637 1638 1639 1640
		case 5:
			iNdEx += 4
		default:
			return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
		}
1641 1642 1643 1644 1645 1646
		if iNdEx < 0 {
			return 0, ErrInvalidLengthMessage
		}
		if depth == 0 {
			return iNdEx, nil
		}
1647
	}
1648
	return 0, io.ErrUnexpectedEOF
1649 1650 1651
}

var (
1652 1653 1654
	ErrInvalidLengthMessage        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowMessage          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupMessage = fmt.Errorf("proto: unexpected end of group")
1655
)