github.com/m3db/m3@v1.5.0/src/m3ninx/generated/proto/fswriter/fswriter.pb.go (about) 1 // Code generated by protoc-gen-gogo. DO NOT EDIT. 2 // source: github.com/m3db/m3/src/m3ninx/generated/proto/fswriter/fswriter.proto 3 4 // Copyright (c) 2019 Uber Technologies, Inc. 5 // 6 // Permission is hereby granted, free of charge, to any person obtaining a copy 7 // of this software and associated documentation files (the "Software"), to deal 8 // in the Software without restriction, including without limitation the rights 9 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 // copies of the Software, and to permit persons to whom the Software is 11 // furnished to do so, subject to the following conditions: 12 // 13 // The above copyright notice and this permission notice shall be included in 14 // all copies or substantial portions of the Software. 15 // 16 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 // THE SOFTWARE. 23 24 /* 25 Package fswriter is a generated protocol buffer package. 26 27 It is generated from these files: 28 github.com/m3db/m3/src/m3ninx/generated/proto/fswriter/fswriter.proto 29 30 It has these top-level messages: 31 Metadata 32 FieldData 33 */ 34 package fswriter 35 36 import proto "github.com/gogo/protobuf/proto" 37 import fmt "fmt" 38 import math "math" 39 40 import io "io" 41 42 // Reference imports to suppress errors if they are not otherwise used. 43 var _ = proto.Marshal 44 var _ = fmt.Errorf 45 var _ = math.Inf 46 47 // This is a compile-time assertion to ensure that this generated file 48 // is compatible with the proto package it is being compiled against. 49 // A compilation error at this line likely means your copy of the 50 // proto package needs to be updated. 51 const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package 52 53 type SegmentType int32 54 55 const ( 56 SegmentType_FST_SEGMENT_TYPE SegmentType = 0 57 ) 58 59 var SegmentType_name = map[int32]string{ 60 0: "FST_SEGMENT_TYPE", 61 } 62 var SegmentType_value = map[string]int32{ 63 "FST_SEGMENT_TYPE": 0, 64 } 65 66 func (x SegmentType) String() string { 67 return proto.EnumName(SegmentType_name, int32(x)) 68 } 69 func (SegmentType) EnumDescriptor() ([]byte, []int) { return fileDescriptorFswriter, []int{0} } 70 71 type FSTSegmentFileType int32 72 73 const ( 74 FSTSegmentFileType_DOCUMENTS_INDEX FSTSegmentFileType = 0 75 FSTSegmentFileType_DOCUMENTS_DATA FSTSegmentFileType = 1 76 FSTSegmentFileType_POSTINGS_DATA FSTSegmentFileType = 2 77 FSTSegmentFileType_FST_TERMS FSTSegmentFileType = 3 78 FSTSegmentFileType_FST_FIELDS FSTSegmentFileType = 4 79 ) 80 81 var FSTSegmentFileType_name = map[int32]string{ 82 0: "DOCUMENTS_INDEX", 83 1: "DOCUMENTS_DATA", 84 2: "POSTINGS_DATA", 85 3: "FST_TERMS", 86 4: "FST_FIELDS", 87 } 88 var FSTSegmentFileType_value = map[string]int32{ 89 "DOCUMENTS_INDEX": 0, 90 "DOCUMENTS_DATA": 1, 91 "POSTINGS_DATA": 2, 92 "FST_TERMS": 3, 93 "FST_FIELDS": 4, 94 } 95 96 func (x FSTSegmentFileType) String() string { 97 return proto.EnumName(FSTSegmentFileType_name, int32(x)) 98 } 99 func (FSTSegmentFileType) EnumDescriptor() ([]byte, []int) { return fileDescriptorFswriter, []int{1} } 100 101 type PostingsFormat int32 102 103 const ( 104 PostingsFormat_PILOSAV1_POSTINGS_FORMAT PostingsFormat = 0 105 ) 106 107 var PostingsFormat_name = map[int32]string{ 108 0: "PILOSAV1_POSTINGS_FORMAT", 109 } 110 var PostingsFormat_value = map[string]int32{ 111 "PILOSAV1_POSTINGS_FORMAT": 0, 112 } 113 114 func (x PostingsFormat) String() string { 115 return proto.EnumName(PostingsFormat_name, int32(x)) 116 } 117 func (PostingsFormat) EnumDescriptor() ([]byte, []int) { return fileDescriptorFswriter, []int{2} } 118 119 type Metadata struct { 120 PostingsFormat PostingsFormat `protobuf:"varint,1,opt,name=postingsFormat,proto3,enum=fswriter.PostingsFormat" json:"postingsFormat,omitempty"` 121 NumDocs int64 `protobuf:"varint,2,opt,name=numDocs,proto3" json:"numDocs,omitempty"` 122 } 123 124 func (m *Metadata) Reset() { *m = Metadata{} } 125 func (m *Metadata) String() string { return proto.CompactTextString(m) } 126 func (*Metadata) ProtoMessage() {} 127 func (*Metadata) Descriptor() ([]byte, []int) { return fileDescriptorFswriter, []int{0} } 128 129 func (m *Metadata) GetPostingsFormat() PostingsFormat { 130 if m != nil { 131 return m.PostingsFormat 132 } 133 return PostingsFormat_PILOSAV1_POSTINGS_FORMAT 134 } 135 136 func (m *Metadata) GetNumDocs() int64 { 137 if m != nil { 138 return m.NumDocs 139 } 140 return 0 141 } 142 143 // additional metadata stored per Field in the corpus. 144 type FieldData struct { 145 // postingsOffset for the pl corresponding to the union of all documents 146 // which have a given field. 147 FieldPostingsListOffset uint64 `protobuf:"varint,1,opt,name=fieldPostingsListOffset,proto3" json:"fieldPostingsListOffset,omitempty"` 148 } 149 150 func (m *FieldData) Reset() { *m = FieldData{} } 151 func (m *FieldData) String() string { return proto.CompactTextString(m) } 152 func (*FieldData) ProtoMessage() {} 153 func (*FieldData) Descriptor() ([]byte, []int) { return fileDescriptorFswriter, []int{1} } 154 155 func (m *FieldData) GetFieldPostingsListOffset() uint64 { 156 if m != nil { 157 return m.FieldPostingsListOffset 158 } 159 return 0 160 } 161 162 func init() { 163 proto.RegisterType((*Metadata)(nil), "fswriter.Metadata") 164 proto.RegisterType((*FieldData)(nil), "fswriter.FieldData") 165 proto.RegisterEnum("fswriter.SegmentType", SegmentType_name, SegmentType_value) 166 proto.RegisterEnum("fswriter.FSTSegmentFileType", FSTSegmentFileType_name, FSTSegmentFileType_value) 167 proto.RegisterEnum("fswriter.PostingsFormat", PostingsFormat_name, PostingsFormat_value) 168 } 169 func (m *Metadata) Marshal() (dAtA []byte, err error) { 170 size := m.Size() 171 dAtA = make([]byte, size) 172 n, err := m.MarshalTo(dAtA) 173 if err != nil { 174 return nil, err 175 } 176 return dAtA[:n], nil 177 } 178 179 func (m *Metadata) MarshalTo(dAtA []byte) (int, error) { 180 var i int 181 _ = i 182 var l int 183 _ = l 184 if m.PostingsFormat != 0 { 185 dAtA[i] = 0x8 186 i++ 187 i = encodeVarintFswriter(dAtA, i, uint64(m.PostingsFormat)) 188 } 189 if m.NumDocs != 0 { 190 dAtA[i] = 0x10 191 i++ 192 i = encodeVarintFswriter(dAtA, i, uint64(m.NumDocs)) 193 } 194 return i, nil 195 } 196 197 func (m *FieldData) Marshal() (dAtA []byte, err error) { 198 size := m.Size() 199 dAtA = make([]byte, size) 200 n, err := m.MarshalTo(dAtA) 201 if err != nil { 202 return nil, err 203 } 204 return dAtA[:n], nil 205 } 206 207 func (m *FieldData) MarshalTo(dAtA []byte) (int, error) { 208 var i int 209 _ = i 210 var l int 211 _ = l 212 if m.FieldPostingsListOffset != 0 { 213 dAtA[i] = 0x8 214 i++ 215 i = encodeVarintFswriter(dAtA, i, uint64(m.FieldPostingsListOffset)) 216 } 217 return i, nil 218 } 219 220 func encodeVarintFswriter(dAtA []byte, offset int, v uint64) int { 221 for v >= 1<<7 { 222 dAtA[offset] = uint8(v&0x7f | 0x80) 223 v >>= 7 224 offset++ 225 } 226 dAtA[offset] = uint8(v) 227 return offset + 1 228 } 229 func (m *Metadata) Size() (n int) { 230 var l int 231 _ = l 232 if m.PostingsFormat != 0 { 233 n += 1 + sovFswriter(uint64(m.PostingsFormat)) 234 } 235 if m.NumDocs != 0 { 236 n += 1 + sovFswriter(uint64(m.NumDocs)) 237 } 238 return n 239 } 240 241 func (m *FieldData) Size() (n int) { 242 var l int 243 _ = l 244 if m.FieldPostingsListOffset != 0 { 245 n += 1 + sovFswriter(uint64(m.FieldPostingsListOffset)) 246 } 247 return n 248 } 249 250 func sovFswriter(x uint64) (n int) { 251 for { 252 n++ 253 x >>= 7 254 if x == 0 { 255 break 256 } 257 } 258 return n 259 } 260 func sozFswriter(x uint64) (n int) { 261 return sovFswriter(uint64((x << 1) ^ uint64((int64(x) >> 63)))) 262 } 263 func (m *Metadata) Unmarshal(dAtA []byte) error { 264 l := len(dAtA) 265 iNdEx := 0 266 for iNdEx < l { 267 preIndex := iNdEx 268 var wire uint64 269 for shift := uint(0); ; shift += 7 { 270 if shift >= 64 { 271 return ErrIntOverflowFswriter 272 } 273 if iNdEx >= l { 274 return io.ErrUnexpectedEOF 275 } 276 b := dAtA[iNdEx] 277 iNdEx++ 278 wire |= (uint64(b) & 0x7F) << shift 279 if b < 0x80 { 280 break 281 } 282 } 283 fieldNum := int32(wire >> 3) 284 wireType := int(wire & 0x7) 285 if wireType == 4 { 286 return fmt.Errorf("proto: Metadata: wiretype end group for non-group") 287 } 288 if fieldNum <= 0 { 289 return fmt.Errorf("proto: Metadata: illegal tag %d (wire type %d)", fieldNum, wire) 290 } 291 switch fieldNum { 292 case 1: 293 if wireType != 0 { 294 return fmt.Errorf("proto: wrong wireType = %d for field PostingsFormat", wireType) 295 } 296 m.PostingsFormat = 0 297 for shift := uint(0); ; shift += 7 { 298 if shift >= 64 { 299 return ErrIntOverflowFswriter 300 } 301 if iNdEx >= l { 302 return io.ErrUnexpectedEOF 303 } 304 b := dAtA[iNdEx] 305 iNdEx++ 306 m.PostingsFormat |= (PostingsFormat(b) & 0x7F) << shift 307 if b < 0x80 { 308 break 309 } 310 } 311 case 2: 312 if wireType != 0 { 313 return fmt.Errorf("proto: wrong wireType = %d for field NumDocs", wireType) 314 } 315 m.NumDocs = 0 316 for shift := uint(0); ; shift += 7 { 317 if shift >= 64 { 318 return ErrIntOverflowFswriter 319 } 320 if iNdEx >= l { 321 return io.ErrUnexpectedEOF 322 } 323 b := dAtA[iNdEx] 324 iNdEx++ 325 m.NumDocs |= (int64(b) & 0x7F) << shift 326 if b < 0x80 { 327 break 328 } 329 } 330 default: 331 iNdEx = preIndex 332 skippy, err := skipFswriter(dAtA[iNdEx:]) 333 if err != nil { 334 return err 335 } 336 if skippy < 0 { 337 return ErrInvalidLengthFswriter 338 } 339 if (iNdEx + skippy) > l { 340 return io.ErrUnexpectedEOF 341 } 342 iNdEx += skippy 343 } 344 } 345 346 if iNdEx > l { 347 return io.ErrUnexpectedEOF 348 } 349 return nil 350 } 351 func (m *FieldData) Unmarshal(dAtA []byte) error { 352 l := len(dAtA) 353 iNdEx := 0 354 for iNdEx < l { 355 preIndex := iNdEx 356 var wire uint64 357 for shift := uint(0); ; shift += 7 { 358 if shift >= 64 { 359 return ErrIntOverflowFswriter 360 } 361 if iNdEx >= l { 362 return io.ErrUnexpectedEOF 363 } 364 b := dAtA[iNdEx] 365 iNdEx++ 366 wire |= (uint64(b) & 0x7F) << shift 367 if b < 0x80 { 368 break 369 } 370 } 371 fieldNum := int32(wire >> 3) 372 wireType := int(wire & 0x7) 373 if wireType == 4 { 374 return fmt.Errorf("proto: FieldData: wiretype end group for non-group") 375 } 376 if fieldNum <= 0 { 377 return fmt.Errorf("proto: FieldData: illegal tag %d (wire type %d)", fieldNum, wire) 378 } 379 switch fieldNum { 380 case 1: 381 if wireType != 0 { 382 return fmt.Errorf("proto: wrong wireType = %d for field FieldPostingsListOffset", wireType) 383 } 384 m.FieldPostingsListOffset = 0 385 for shift := uint(0); ; shift += 7 { 386 if shift >= 64 { 387 return ErrIntOverflowFswriter 388 } 389 if iNdEx >= l { 390 return io.ErrUnexpectedEOF 391 } 392 b := dAtA[iNdEx] 393 iNdEx++ 394 m.FieldPostingsListOffset |= (uint64(b) & 0x7F) << shift 395 if b < 0x80 { 396 break 397 } 398 } 399 default: 400 iNdEx = preIndex 401 skippy, err := skipFswriter(dAtA[iNdEx:]) 402 if err != nil { 403 return err 404 } 405 if skippy < 0 { 406 return ErrInvalidLengthFswriter 407 } 408 if (iNdEx + skippy) > l { 409 return io.ErrUnexpectedEOF 410 } 411 iNdEx += skippy 412 } 413 } 414 415 if iNdEx > l { 416 return io.ErrUnexpectedEOF 417 } 418 return nil 419 } 420 func skipFswriter(dAtA []byte) (n int, err error) { 421 l := len(dAtA) 422 iNdEx := 0 423 for iNdEx < l { 424 var wire uint64 425 for shift := uint(0); ; shift += 7 { 426 if shift >= 64 { 427 return 0, ErrIntOverflowFswriter 428 } 429 if iNdEx >= l { 430 return 0, io.ErrUnexpectedEOF 431 } 432 b := dAtA[iNdEx] 433 iNdEx++ 434 wire |= (uint64(b) & 0x7F) << shift 435 if b < 0x80 { 436 break 437 } 438 } 439 wireType := int(wire & 0x7) 440 switch wireType { 441 case 0: 442 for shift := uint(0); ; shift += 7 { 443 if shift >= 64 { 444 return 0, ErrIntOverflowFswriter 445 } 446 if iNdEx >= l { 447 return 0, io.ErrUnexpectedEOF 448 } 449 iNdEx++ 450 if dAtA[iNdEx-1] < 0x80 { 451 break 452 } 453 } 454 return iNdEx, nil 455 case 1: 456 iNdEx += 8 457 return iNdEx, nil 458 case 2: 459 var length int 460 for shift := uint(0); ; shift += 7 { 461 if shift >= 64 { 462 return 0, ErrIntOverflowFswriter 463 } 464 if iNdEx >= l { 465 return 0, io.ErrUnexpectedEOF 466 } 467 b := dAtA[iNdEx] 468 iNdEx++ 469 length |= (int(b) & 0x7F) << shift 470 if b < 0x80 { 471 break 472 } 473 } 474 iNdEx += length 475 if length < 0 { 476 return 0, ErrInvalidLengthFswriter 477 } 478 return iNdEx, nil 479 case 3: 480 for { 481 var innerWire uint64 482 var start int = iNdEx 483 for shift := uint(0); ; shift += 7 { 484 if shift >= 64 { 485 return 0, ErrIntOverflowFswriter 486 } 487 if iNdEx >= l { 488 return 0, io.ErrUnexpectedEOF 489 } 490 b := dAtA[iNdEx] 491 iNdEx++ 492 innerWire |= (uint64(b) & 0x7F) << shift 493 if b < 0x80 { 494 break 495 } 496 } 497 innerWireType := int(innerWire & 0x7) 498 if innerWireType == 4 { 499 break 500 } 501 next, err := skipFswriter(dAtA[start:]) 502 if err != nil { 503 return 0, err 504 } 505 iNdEx = start + next 506 } 507 return iNdEx, nil 508 case 4: 509 return iNdEx, nil 510 case 5: 511 iNdEx += 4 512 return iNdEx, nil 513 default: 514 return 0, fmt.Errorf("proto: illegal wireType %d", wireType) 515 } 516 } 517 panic("unreachable") 518 } 519 520 var ( 521 ErrInvalidLengthFswriter = fmt.Errorf("proto: negative length found during unmarshaling") 522 ErrIntOverflowFswriter = fmt.Errorf("proto: integer overflow") 523 ) 524 525 func init() { 526 proto.RegisterFile("github.com/m3db/m3/src/m3ninx/generated/proto/fswriter/fswriter.proto", fileDescriptorFswriter) 527 } 528 529 var fileDescriptorFswriter = []byte{ 530 // 359 bytes of a gzipped FileDescriptorProto 531 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x91, 0xc1, 0x8a, 0x9b, 0x40, 532 0x18, 0xc7, 0x35, 0x09, 0x6d, 0xf2, 0x95, 0xd8, 0xe9, 0xb4, 0x50, 0x0f, 0x45, 0x42, 0x7a, 0x09, 533 0x39, 0x28, 0xad, 0x97, 0x1e, 0x6b, 0xeb, 0x18, 0x84, 0x18, 0xc5, 0x99, 0x96, 0xf6, 0x24, 0x26, 534 0x8e, 0xae, 0x10, 0x35, 0xe8, 0x84, 0xdd, 0x7d, 0x8b, 0x7d, 0xac, 0x3d, 0xee, 0x23, 0x2c, 0xd9, 535 0x17, 0x59, 0xcc, 0x26, 0x59, 0xb2, 0xb0, 0xb7, 0xf9, 0xfd, 0xbf, 0xdf, 0x7c, 0x7f, 0x98, 0x01, 536 0x92, 0xe5, 0xe2, 0x62, 0xbb, 0xd4, 0x57, 0x55, 0x61, 0x14, 0x66, 0xb2, 0x34, 0x0a, 0xd3, 0x68, 537 0xea, 0x95, 0x51, 0x98, 0x65, 0x5e, 0x5e, 0x19, 0x19, 0x2f, 0x79, 0x1d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