github.com/cockroachdb/cockroach@v20.2.0-alpha.1+incompatible/pkg/kv/kvserver/protectedts/ptstorage/storage.pb.go (about) 1 // Code generated by protoc-gen-gogo. DO NOT EDIT. 2 // source: kv/kvserver/protectedts/ptstorage/storage.proto 3 4 package ptstorage 5 6 import proto "github.com/gogo/protobuf/proto" 7 import fmt "fmt" 8 import math "math" 9 import roachpb "github.com/cockroachdb/cockroach/pkg/roachpb" 10 11 import io "io" 12 13 // Reference imports to suppress errors if they are not otherwise used. 14 var _ = proto.Marshal 15 var _ = fmt.Errorf 16 var _ = math.Inf 17 18 // This is a compile-time assertion to ensure that this generated file 19 // is compatible with the proto package it is being compiled against. 20 // A compilation error at this line likely means your copy of the 21 // proto package needs to be updated. 22 const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package 23 24 // Spans is the format of the message encoded in the spans column of a the 25 // system.protectedts_records table. 26 type Spans struct { 27 // Spans are the set of spans protected by a Record. 28 Spans []roachpb.Span `protobuf:"bytes,7,rep,name=spans,proto3" json:"spans"` 29 } 30 31 func (m *Spans) Reset() { *m = Spans{} } 32 func (m *Spans) String() string { return proto.CompactTextString(m) } 33 func (*Spans) ProtoMessage() {} 34 func (*Spans) Descriptor() ([]byte, []int) { 35 return fileDescriptor_storage_af582c1bcb16afac, []int{0} 36 } 37 func (m *Spans) XXX_Unmarshal(b []byte) error { 38 return m.Unmarshal(b) 39 } 40 func (m *Spans) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 41 b = b[:cap(b)] 42 n, err := m.MarshalTo(b) 43 if err != nil { 44 return nil, err 45 } 46 return b[:n], nil 47 } 48 func (dst *Spans) XXX_Merge(src proto.Message) { 49 xxx_messageInfo_Spans.Merge(dst, src) 50 } 51 func (m *Spans) XXX_Size() int { 52 return m.Size() 53 } 54 func (m *Spans) XXX_DiscardUnknown() { 55 xxx_messageInfo_Spans.DiscardUnknown(m) 56 } 57 58 var xxx_messageInfo_Spans proto.InternalMessageInfo 59 60 func init() { 61 proto.RegisterType((*Spans)(nil), "cockroach.protectedts.Spans") 62 } 63 func (m *Spans) Marshal() (dAtA []byte, err error) { 64 size := m.Size() 65 dAtA = make([]byte, size) 66 n, err := m.MarshalTo(dAtA) 67 if err != nil { 68 return nil, err 69 } 70 return dAtA[:n], nil 71 } 72 73 func (m *Spans) MarshalTo(dAtA []byte) (int, error) { 74 var i int 75 _ = i 76 var l int 77 _ = l 78 if len(m.Spans) > 0 { 79 for _, msg := range m.Spans { 80 dAtA[i] = 0x3a 81 i++ 82 i = encodeVarintStorage(dAtA, i, uint64(msg.Size())) 83 n, err := msg.MarshalTo(dAtA[i:]) 84 if err != nil { 85 return 0, err 86 } 87 i += n 88 } 89 } 90 return i, nil 91 } 92 93 func encodeVarintStorage(dAtA []byte, offset int, v uint64) int { 94 for v >= 1<<7 { 95 dAtA[offset] = uint8(v&0x7f | 0x80) 96 v >>= 7 97 offset++ 98 } 99 dAtA[offset] = uint8(v) 100 return offset + 1 101 } 102 func (m *Spans) Size() (n int) { 103 if m == nil { 104 return 0 105 } 106 var l int 107 _ = l 108 if len(m.Spans) > 0 { 109 for _, e := range m.Spans { 110 l = e.Size() 111 n += 1 + l + sovStorage(uint64(l)) 112 } 113 } 114 return n 115 } 116 117 func sovStorage(x uint64) (n int) { 118 for { 119 n++ 120 x >>= 7 121 if x == 0 { 122 break 123 } 124 } 125 return n 126 } 127 func sozStorage(x uint64) (n int) { 128 return sovStorage(uint64((x << 1) ^ uint64((int64(x) >> 63)))) 129 } 130 func (m *Spans) Unmarshal(dAtA []byte) error { 131 l := len(dAtA) 132 iNdEx := 0 133 for iNdEx < l { 134 preIndex := iNdEx 135 var wire uint64 136 for shift := uint(0); ; shift += 7 { 137 if shift >= 64 { 138 return ErrIntOverflowStorage 139 } 140 if iNdEx >= l { 141 return io.ErrUnexpectedEOF 142 } 143 b := dAtA[iNdEx] 144 iNdEx++ 145 wire |= (uint64(b) & 0x7F) << shift 146 if b < 0x80 { 147 break 148 } 149 } 150 fieldNum := int32(wire >> 3) 151 wireType := int(wire & 0x7) 152 if wireType == 4 { 153 return fmt.Errorf("proto: Spans: wiretype end group for non-group") 154 } 155 if fieldNum <= 0 { 156 return fmt.Errorf("proto: Spans: illegal tag %d (wire type %d)", fieldNum, wire) 157 } 158 switch fieldNum { 159 case 7: 160 if wireType != 2 { 161 return fmt.Errorf("proto: wrong wireType = %d for field Spans", wireType) 162 } 163 var msglen int 164 for shift := uint(0); ; shift += 7 { 165 if shift >= 64 { 166 return ErrIntOverflowStorage 167 } 168 if iNdEx >= l { 169 return io.ErrUnexpectedEOF 170 } 171 b := dAtA[iNdEx] 172 iNdEx++ 173 msglen |= (int(b) & 0x7F) << shift 174 if b < 0x80 { 175 break 176 } 177 } 178 if msglen < 0 { 179 return ErrInvalidLengthStorage 180 } 181 postIndex := iNdEx + msglen 182 if postIndex > l { 183 return io.ErrUnexpectedEOF 184 } 185 m.Spans = append(m.Spans, roachpb.Span{}) 186 if err := m.Spans[len(m.Spans)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 187 return err 188 } 189 iNdEx = postIndex 190 default: 191 iNdEx = preIndex 192 skippy, err := skipStorage(dAtA[iNdEx:]) 193 if err != nil { 194 return err 195 } 196 if skippy < 0 { 197 return ErrInvalidLengthStorage 198 } 199 if (iNdEx + skippy) > l { 200 return io.ErrUnexpectedEOF 201 } 202 iNdEx += skippy 203 } 204 } 205 206 if iNdEx > l { 207 return io.ErrUnexpectedEOF 208 } 209 return nil 210 } 211 func skipStorage(dAtA []byte) (n int, err error) { 212 l := len(dAtA) 213 iNdEx := 0 214 for iNdEx < l { 215 var wire uint64 216 for shift := uint(0); ; shift += 7 { 217 if shift >= 64 { 218 return 0, ErrIntOverflowStorage 219 } 220 if iNdEx >= l { 221 return 0, io.ErrUnexpectedEOF 222 } 223 b := dAtA[iNdEx] 224 iNdEx++ 225 wire |= (uint64(b) & 0x7F) << shift 226 if b < 0x80 { 227 break 228 } 229 } 230 wireType := int(wire & 0x7) 231 switch wireType { 232 case 0: 233 for shift := uint(0); ; shift += 7 { 234 if shift >= 64 { 235 return 0, ErrIntOverflowStorage 236 } 237 if iNdEx >= l { 238 return 0, io.ErrUnexpectedEOF 239 } 240 iNdEx++ 241 if dAtA[iNdEx-1] < 0x80 { 242 break 243 } 244 } 245 return iNdEx, nil 246 case 1: 247 iNdEx += 8 248 return iNdEx, nil 249 case 2: 250 var length int 251 for shift := uint(0); ; shift += 7 { 252 if shift >= 64 { 253 return 0, ErrIntOverflowStorage 254 } 255 if iNdEx >= l { 256 return 0, io.ErrUnexpectedEOF 257 } 258 b := dAtA[iNdEx] 259 iNdEx++ 260 length |= (int(b) & 0x7F) << shift 261 if b < 0x80 { 262 break 263 } 264 } 265 iNdEx += length 266 if length < 0 { 267 return 0, ErrInvalidLengthStorage 268 } 269 return iNdEx, nil 270 case 3: 271 for { 272 var innerWire uint64 273 var start int = iNdEx 274 for shift := uint(0); ; shift += 7 { 275 if shift >= 64 { 276 return 0, ErrIntOverflowStorage 277 } 278 if iNdEx >= l { 279 return 0, io.ErrUnexpectedEOF 280 } 281 b := dAtA[iNdEx] 282 iNdEx++ 283 innerWire |= (uint64(b) & 0x7F) << shift 284 if b < 0x80 { 285 break 286 } 287 } 288 innerWireType := int(innerWire & 0x7) 289 if innerWireType == 4 { 290 break 291 } 292 next, err := skipStorage(dAtA[start:]) 293 if err != nil { 294 return 0, err 295 } 296 iNdEx = start + next 297 } 298 return iNdEx, nil 299 case 4: 300 return iNdEx, nil 301 case 5: 302 iNdEx += 4 303 return iNdEx, nil 304 default: 305 return 0, fmt.Errorf("proto: illegal wireType %d", wireType) 306 } 307 } 308 panic("unreachable") 309 } 310 311 var ( 312 ErrInvalidLengthStorage = fmt.Errorf("proto: negative length found during unmarshaling") 313 ErrIntOverflowStorage = fmt.Errorf("proto: integer overflow") 314 ) 315 316 func init() { 317 proto.RegisterFile("kv/kvserver/protectedts/ptstorage/storage.proto", fileDescriptor_storage_af582c1bcb16afac) 318 } 319 320 var fileDescriptor_storage_af582c1bcb16afac = []byte{ 321 // 217 bytes of a gzipped FileDescriptorProto 322 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0xcf, 0x2e, 0xd3, 0xcf, 323 0x2e, 0x2b, 0x4e, 0x2d, 0x2a, 0x4b, 0x2d, 0xd2, 0x2f, 0x28, 0xca, 0x2f, 0x49, 0x4d, 0x2e, 0x49, 324 0x4d, 0x29, 0x29, 0xd6, 0x2f, 0x28, 0x29, 0x2e, 0xc9, 0x2f, 0x4a, 0x4c, 0x4f, 0xd5, 0x87, 0xd2, 325 0x7a, 0x20, 0xd9, 0x7c, 0x21, 0xd1, 0xe4, 0xfc, 0xe4, 0xec, 0xa2, 0xfc, 0xc4, 0xe4, 0x0c, 0x3d, 326 0x24, 0xe5, 0x52, 0x22, 0xe9, 0xf9, 0xe9, 0xf9, 0x60, 0x15, 0xfa, 0x20, 0x16, 0x44, 0xb1, 0x94, 327 0x4c, 0x7a, 0x7e, 0x7e, 0x7a, 0x4e, 0xaa, 0x7e, 0x62, 0x41, 0xa6, 0x7e, 0x62, 0x5e, 0x5e, 0x7e, 328 0x49, 0x62, 0x49, 0x66, 0x7e, 0x5e, 0x31, 0x54, 0x56, 0x08, 0x6c, 0x4c, 0x41, 0x92, 0x7e, 0x4a, 329 0x62, 0x49, 0x22, 0x44, 0x4c, 0xc9, 0x86, 0x8b, 0x35, 0xb8, 0x20, 0x31, 0xaf, 0x58, 0xc8, 0x98, 330 0x8b, 0xb5, 0x18, 0xc4, 0x90, 0x60, 0x57, 0x60, 0xd6, 0xe0, 0x36, 0x12, 0xd7, 0x43, 0xd8, 0x0b, 331 0xd5, 0xa6, 0x07, 0x52, 0xe8, 0xc4, 0x72, 0xe2, 0x9e, 0x3c, 0x43, 0x10, 0x44, 0xad, 0x93, 0xf6, 332 0x89, 0x87, 0x72, 0x0c, 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0x78, 0xe3, 0x91, 0x1c, 333 0xe3, 0x83, 0x47, 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 334 0x1c, 0x43, 0x14, 0x27, 0xdc, 0x5f, 0x49, 0x6c, 0x60, 0x1b, 0x8d, 0x01, 0x01, 0x00, 0x00, 0xff, 335 0xff, 0x14, 0xef, 0x14, 0xb4, 0x03, 0x01, 0x00, 0x00, 336 }