Matteo Scandolo | a428586 | 2020-12-01 18:10:10 -0800 | [diff] [blame^] | 1 | /* |
| 2 | Copyright The Kubernetes Authors. |
| 3 | |
| 4 | Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | you may not use this file except in compliance with the License. |
| 6 | You may obtain a copy of the License at |
| 7 | |
| 8 | http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | |
| 10 | Unless required by applicable law or agreed to in writing, software |
| 11 | distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | See the License for the specific language governing permissions and |
| 14 | limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | // Code generated by protoc-gen-gogo. DO NOT EDIT. |
| 18 | // source: k8s.io/kubernetes/vendor/k8s.io/api/node/v1alpha1/generated.proto |
| 19 | |
| 20 | package v1alpha1 |
| 21 | |
| 22 | import ( |
| 23 | fmt "fmt" |
| 24 | |
| 25 | io "io" |
| 26 | |
| 27 | proto "github.com/gogo/protobuf/proto" |
| 28 | github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" |
| 29 | k8s_io_api_core_v1 "k8s.io/api/core/v1" |
| 30 | v11 "k8s.io/api/core/v1" |
| 31 | k8s_io_apimachinery_pkg_api_resource "k8s.io/apimachinery/pkg/api/resource" |
| 32 | resource "k8s.io/apimachinery/pkg/api/resource" |
| 33 | |
| 34 | math "math" |
| 35 | math_bits "math/bits" |
| 36 | reflect "reflect" |
| 37 | strings "strings" |
| 38 | ) |
| 39 | |
| 40 | // Reference imports to suppress errors if they are not otherwise used. |
| 41 | var _ = proto.Marshal |
| 42 | var _ = fmt.Errorf |
| 43 | var _ = math.Inf |
| 44 | |
| 45 | // This is a compile-time assertion to ensure that this generated file |
| 46 | // is compatible with the proto package it is being compiled against. |
| 47 | // A compilation error at this line likely means your copy of the |
| 48 | // proto package needs to be updated. |
| 49 | const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package |
| 50 | |
| 51 | func (m *Overhead) Reset() { *m = Overhead{} } |
| 52 | func (*Overhead) ProtoMessage() {} |
| 53 | func (*Overhead) Descriptor() ([]byte, []int) { |
| 54 | return fileDescriptor_82a78945ab308218, []int{0} |
| 55 | } |
| 56 | func (m *Overhead) XXX_Unmarshal(b []byte) error { |
| 57 | return m.Unmarshal(b) |
| 58 | } |
| 59 | func (m *Overhead) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { |
| 60 | b = b[:cap(b)] |
| 61 | n, err := m.MarshalToSizedBuffer(b) |
| 62 | if err != nil { |
| 63 | return nil, err |
| 64 | } |
| 65 | return b[:n], nil |
| 66 | } |
| 67 | func (m *Overhead) XXX_Merge(src proto.Message) { |
| 68 | xxx_messageInfo_Overhead.Merge(m, src) |
| 69 | } |
| 70 | func (m *Overhead) XXX_Size() int { |
| 71 | return m.Size() |
| 72 | } |
| 73 | func (m *Overhead) XXX_DiscardUnknown() { |
| 74 | xxx_messageInfo_Overhead.DiscardUnknown(m) |
| 75 | } |
| 76 | |
| 77 | var xxx_messageInfo_Overhead proto.InternalMessageInfo |
| 78 | |
| 79 | func (m *RuntimeClass) Reset() { *m = RuntimeClass{} } |
| 80 | func (*RuntimeClass) ProtoMessage() {} |
| 81 | func (*RuntimeClass) Descriptor() ([]byte, []int) { |
| 82 | return fileDescriptor_82a78945ab308218, []int{1} |
| 83 | } |
| 84 | func (m *RuntimeClass) XXX_Unmarshal(b []byte) error { |
| 85 | return m.Unmarshal(b) |
| 86 | } |
| 87 | func (m *RuntimeClass) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { |
| 88 | b = b[:cap(b)] |
| 89 | n, err := m.MarshalToSizedBuffer(b) |
| 90 | if err != nil { |
| 91 | return nil, err |
| 92 | } |
| 93 | return b[:n], nil |
| 94 | } |
| 95 | func (m *RuntimeClass) XXX_Merge(src proto.Message) { |
| 96 | xxx_messageInfo_RuntimeClass.Merge(m, src) |
| 97 | } |
| 98 | func (m *RuntimeClass) XXX_Size() int { |
| 99 | return m.Size() |
| 100 | } |
| 101 | func (m *RuntimeClass) XXX_DiscardUnknown() { |
| 102 | xxx_messageInfo_RuntimeClass.DiscardUnknown(m) |
| 103 | } |
| 104 | |
| 105 | var xxx_messageInfo_RuntimeClass proto.InternalMessageInfo |
| 106 | |
| 107 | func (m *RuntimeClassList) Reset() { *m = RuntimeClassList{} } |
| 108 | func (*RuntimeClassList) ProtoMessage() {} |
| 109 | func (*RuntimeClassList) Descriptor() ([]byte, []int) { |
| 110 | return fileDescriptor_82a78945ab308218, []int{2} |
| 111 | } |
| 112 | func (m *RuntimeClassList) XXX_Unmarshal(b []byte) error { |
| 113 | return m.Unmarshal(b) |
| 114 | } |
| 115 | func (m *RuntimeClassList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { |
| 116 | b = b[:cap(b)] |
| 117 | n, err := m.MarshalToSizedBuffer(b) |
| 118 | if err != nil { |
| 119 | return nil, err |
| 120 | } |
| 121 | return b[:n], nil |
| 122 | } |
| 123 | func (m *RuntimeClassList) XXX_Merge(src proto.Message) { |
| 124 | xxx_messageInfo_RuntimeClassList.Merge(m, src) |
| 125 | } |
| 126 | func (m *RuntimeClassList) XXX_Size() int { |
| 127 | return m.Size() |
| 128 | } |
| 129 | func (m *RuntimeClassList) XXX_DiscardUnknown() { |
| 130 | xxx_messageInfo_RuntimeClassList.DiscardUnknown(m) |
| 131 | } |
| 132 | |
| 133 | var xxx_messageInfo_RuntimeClassList proto.InternalMessageInfo |
| 134 | |
| 135 | func (m *RuntimeClassSpec) Reset() { *m = RuntimeClassSpec{} } |
| 136 | func (*RuntimeClassSpec) ProtoMessage() {} |
| 137 | func (*RuntimeClassSpec) Descriptor() ([]byte, []int) { |
| 138 | return fileDescriptor_82a78945ab308218, []int{3} |
| 139 | } |
| 140 | func (m *RuntimeClassSpec) XXX_Unmarshal(b []byte) error { |
| 141 | return m.Unmarshal(b) |
| 142 | } |
| 143 | func (m *RuntimeClassSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { |
| 144 | b = b[:cap(b)] |
| 145 | n, err := m.MarshalToSizedBuffer(b) |
| 146 | if err != nil { |
| 147 | return nil, err |
| 148 | } |
| 149 | return b[:n], nil |
| 150 | } |
| 151 | func (m *RuntimeClassSpec) XXX_Merge(src proto.Message) { |
| 152 | xxx_messageInfo_RuntimeClassSpec.Merge(m, src) |
| 153 | } |
| 154 | func (m *RuntimeClassSpec) XXX_Size() int { |
| 155 | return m.Size() |
| 156 | } |
| 157 | func (m *RuntimeClassSpec) XXX_DiscardUnknown() { |
| 158 | xxx_messageInfo_RuntimeClassSpec.DiscardUnknown(m) |
| 159 | } |
| 160 | |
| 161 | var xxx_messageInfo_RuntimeClassSpec proto.InternalMessageInfo |
| 162 | |
| 163 | func (m *Scheduling) Reset() { *m = Scheduling{} } |
| 164 | func (*Scheduling) ProtoMessage() {} |
| 165 | func (*Scheduling) Descriptor() ([]byte, []int) { |
| 166 | return fileDescriptor_82a78945ab308218, []int{4} |
| 167 | } |
| 168 | func (m *Scheduling) XXX_Unmarshal(b []byte) error { |
| 169 | return m.Unmarshal(b) |
| 170 | } |
| 171 | func (m *Scheduling) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { |
| 172 | b = b[:cap(b)] |
| 173 | n, err := m.MarshalToSizedBuffer(b) |
| 174 | if err != nil { |
| 175 | return nil, err |
| 176 | } |
| 177 | return b[:n], nil |
| 178 | } |
| 179 | func (m *Scheduling) XXX_Merge(src proto.Message) { |
| 180 | xxx_messageInfo_Scheduling.Merge(m, src) |
| 181 | } |
| 182 | func (m *Scheduling) XXX_Size() int { |
| 183 | return m.Size() |
| 184 | } |
| 185 | func (m *Scheduling) XXX_DiscardUnknown() { |
| 186 | xxx_messageInfo_Scheduling.DiscardUnknown(m) |
| 187 | } |
| 188 | |
| 189 | var xxx_messageInfo_Scheduling proto.InternalMessageInfo |
| 190 | |
| 191 | func init() { |
| 192 | proto.RegisterType((*Overhead)(nil), "k8s.io.api.node.v1alpha1.Overhead") |
| 193 | proto.RegisterMapType((k8s_io_api_core_v1.ResourceList)(nil), "k8s.io.api.node.v1alpha1.Overhead.PodFixedEntry") |
| 194 | proto.RegisterType((*RuntimeClass)(nil), "k8s.io.api.node.v1alpha1.RuntimeClass") |
| 195 | proto.RegisterType((*RuntimeClassList)(nil), "k8s.io.api.node.v1alpha1.RuntimeClassList") |
| 196 | proto.RegisterType((*RuntimeClassSpec)(nil), "k8s.io.api.node.v1alpha1.RuntimeClassSpec") |
| 197 | proto.RegisterType((*Scheduling)(nil), "k8s.io.api.node.v1alpha1.Scheduling") |
| 198 | proto.RegisterMapType((map[string]string)(nil), "k8s.io.api.node.v1alpha1.Scheduling.NodeSelectorEntry") |
| 199 | } |
| 200 | |
| 201 | func init() { |
| 202 | proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/api/node/v1alpha1/generated.proto", fileDescriptor_82a78945ab308218) |
| 203 | } |
| 204 | |
| 205 | var fileDescriptor_82a78945ab308218 = []byte{ |
| 206 | // 698 bytes of a gzipped FileDescriptorProto |
| 207 | 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x54, 0xbf, 0x6f, 0xd3, 0x4e, |
| 208 | 0x14, 0xcf, 0xa5, 0xad, 0x94, 0x5e, 0xd2, 0xaa, 0x5f, 0x7f, 0x2b, 0x14, 0x65, 0x70, 0x2a, 0x0b, |
| 209 | 0xa1, 0x0a, 0xa9, 0x67, 0x5a, 0xa1, 0xaa, 0x62, 0x00, 0x61, 0x7e, 0x08, 0x44, 0x69, 0xc1, 0x2d, |
| 210 | 0x0b, 0x62, 0xe0, 0x62, 0x3f, 0x1c, 0x13, 0xdb, 0x67, 0xd9, 0xe7, 0x88, 0x6c, 0x88, 0x05, 0x89, |
| 211 | 0x89, 0x89, 0xff, 0x06, 0xe6, 0x8e, 0x9d, 0x50, 0xa7, 0x96, 0x86, 0xff, 0x81, 0x81, 0x09, 0x9d, |
| 212 | 0x7d, 0x4e, 0x9c, 0xa4, 0xa1, 0x61, 0xf3, 0xdd, 0x7d, 0x7e, 0xdc, 0xfb, 0xbc, 0x7b, 0xc6, 0x77, |
| 213 | 0x3b, 0x3b, 0x31, 0x71, 0x99, 0xde, 0x49, 0x5a, 0x10, 0x05, 0xc0, 0x21, 0xd6, 0xbb, 0x10, 0xd8, |
| 214 | 0x2c, 0xd2, 0xe5, 0x01, 0x0d, 0x5d, 0x3d, 0x60, 0x36, 0xe8, 0xdd, 0x4d, 0xea, 0x85, 0x6d, 0xba, |
| 215 | 0xa9, 0x3b, 0x10, 0x40, 0x44, 0x39, 0xd8, 0x24, 0x8c, 0x18, 0x67, 0x4a, 0x3d, 0x43, 0x12, 0x1a, |
| 216 | 0xba, 0x44, 0x20, 0x49, 0x8e, 0x6c, 0x6c, 0x38, 0x2e, 0x6f, 0x27, 0x2d, 0x62, 0x31, 0x5f, 0x77, |
| 217 | 0x98, 0xc3, 0xf4, 0x94, 0xd0, 0x4a, 0xde, 0xa4, 0xab, 0x74, 0x91, 0x7e, 0x65, 0x42, 0x0d, 0xad, |
| 218 | 0x60, 0x69, 0xb1, 0x48, 0x58, 0x8e, 0x9b, 0x35, 0x6e, 0x0e, 0x31, 0x3e, 0xb5, 0xda, 0x6e, 0x00, |
| 219 | 0x51, 0x4f, 0x0f, 0x3b, 0x4e, 0x4a, 0x8a, 0x20, 0x66, 0x49, 0x64, 0xc1, 0x3f, 0xb1, 0x62, 0xdd, |
| 220 | 0x07, 0x4e, 0x2f, 0xf2, 0xd2, 0xa7, 0xb1, 0xa2, 0x24, 0xe0, 0xae, 0x3f, 0x69, 0xb3, 0x7d, 0x19, |
| 221 | 0x21, 0xb6, 0xda, 0xe0, 0xd3, 0x71, 0x9e, 0x76, 0x5c, 0xc6, 0x95, 0xfd, 0x2e, 0x44, 0x6d, 0xa0, |
| 222 | 0xb6, 0xf2, 0x1d, 0xe1, 0x4a, 0xc8, 0xec, 0x87, 0xee, 0x3b, 0xb0, 0xeb, 0x68, 0x6d, 0x6e, 0xbd, |
| 223 | 0xba, 0x75, 0x83, 0x4c, 0x8b, 0x98, 0xe4, 0x34, 0xf2, 0x4c, 0x52, 0x1e, 0x04, 0x3c, 0xea, 0x19, |
| 224 | 0x1f, 0xd1, 0xd1, 0x69, 0xb3, 0xd4, 0x3f, 0x6d, 0x56, 0xf2, 0xfd, 0xdf, 0xa7, 0xcd, 0xe6, 0x64, |
| 225 | 0xbe, 0xc4, 0x94, 0x91, 0xed, 0xba, 0x31, 0xff, 0x70, 0xf6, 0x57, 0xc8, 0x1e, 0xf5, 0xe1, 0xd3, |
| 226 | 0x59, 0x73, 0x63, 0x96, 0x0e, 0x90, 0xe7, 0x09, 0x0d, 0xb8, 0xcb, 0x7b, 0xe6, 0xa0, 0x96, 0x46, |
| 227 | 0x07, 0x2f, 0x8d, 0x5c, 0x52, 0x59, 0xc1, 0x73, 0x1d, 0xe8, 0xd5, 0xd1, 0x1a, 0x5a, 0x5f, 0x34, |
| 228 | 0xc5, 0xa7, 0x72, 0x1f, 0x2f, 0x74, 0xa9, 0x97, 0x40, 0xbd, 0xbc, 0x86, 0xd6, 0xab, 0x5b, 0xa4, |
| 229 | 0x50, 0xf7, 0xc0, 0x8b, 0x84, 0x1d, 0x27, 0x0d, 0x62, 0xd2, 0x2b, 0x23, 0xdf, 0x2a, 0xef, 0x20, |
| 230 | 0xed, 0x1b, 0xc2, 0x35, 0x33, 0x4b, 0xfd, 0x9e, 0x47, 0xe3, 0x58, 0x79, 0x8d, 0x2b, 0xa2, 0xcf, |
| 231 | 0x36, 0xe5, 0x34, 0x75, 0x1c, 0x4d, 0x75, 0x42, 0x3d, 0x26, 0x02, 0x4d, 0xba, 0x9b, 0x64, 0xbf, |
| 232 | 0xf5, 0x16, 0x2c, 0xfe, 0x14, 0x38, 0x35, 0x14, 0x19, 0x2a, 0x1e, 0xee, 0x99, 0x03, 0x55, 0x65, |
| 233 | 0x17, 0xcf, 0xc7, 0x21, 0x58, 0xf2, 0xee, 0xd7, 0xa7, 0xf7, 0xac, 0x78, 0xaf, 0x83, 0x10, 0x2c, |
| 234 | 0xa3, 0x26, 0x75, 0xe7, 0xc5, 0xca, 0x4c, 0x55, 0xb4, 0xaf, 0x08, 0xaf, 0x14, 0x81, 0xa2, 0x41, |
| 235 | 0xca, 0xab, 0x89, 0x22, 0xc8, 0x6c, 0x45, 0x08, 0x76, 0x5a, 0xc2, 0x4a, 0xfe, 0x2e, 0xf2, 0x9d, |
| 236 | 0x42, 0x01, 0x4f, 0xf0, 0x82, 0xcb, 0xc1, 0x8f, 0xeb, 0xe5, 0xf4, 0xd5, 0x5d, 0x9b, 0xad, 0x02, |
| 237 | 0x63, 0x49, 0x4a, 0x2e, 0x3c, 0x16, 0x64, 0x33, 0xd3, 0xd0, 0x7e, 0x8d, 0xdd, 0x5f, 0x94, 0xa6, |
| 238 | 0xdc, 0xc6, 0xcb, 0x72, 0x14, 0x1e, 0xd1, 0xc0, 0xf6, 0x20, 0xca, 0x9a, 0x6f, 0x5c, 0x91, 0x12, |
| 239 | 0xcb, 0xe6, 0xc8, 0xa9, 0x39, 0x86, 0x56, 0x76, 0x71, 0x85, 0xc9, 0x07, 0x2f, 0x63, 0xd6, 0x2e, |
| 240 | 0x1f, 0x0d, 0xa3, 0x26, 0xea, 0xcd, 0x57, 0xe6, 0x40, 0x41, 0x39, 0xc4, 0x58, 0x0c, 0xa4, 0x9d, |
| 241 | 0x78, 0x6e, 0xe0, 0xd4, 0xe7, 0x52, 0xbd, 0xab, 0xd3, 0xf5, 0x0e, 0x06, 0x58, 0x63, 0x59, 0x3c, |
| 242 | 0x82, 0xe1, 0xda, 0x2c, 0xe8, 0x68, 0x5f, 0xca, 0xb8, 0x70, 0xa4, 0x84, 0xb8, 0x26, 0x64, 0x0e, |
| 243 | 0xc0, 0x03, 0x8b, 0xb3, 0x48, 0x4e, 0xf4, 0xf6, 0x2c, 0x36, 0x64, 0xaf, 0x40, 0xcc, 0xe6, 0x7a, |
| 244 | 0x55, 0x06, 0x55, 0x2b, 0x1e, 0x99, 0x23, 0x0e, 0xca, 0x0b, 0x5c, 0xe5, 0xcc, 0x13, 0x3f, 0x18, |
| 245 | 0x97, 0x05, 0x79, 0x33, 0xd5, 0xa2, 0xa1, 0x98, 0x6c, 0xf1, 0x2a, 0x0e, 0x07, 0x30, 0xe3, 0x7f, |
| 246 | 0x29, 0x5c, 0x1d, 0xee, 0xc5, 0x66, 0x51, 0xa7, 0x71, 0x07, 0xff, 0x37, 0x71, 0x9f, 0x0b, 0x46, |
| 247 | 0x78, 0xb5, 0x38, 0xc2, 0x8b, 0x85, 0x91, 0x34, 0xc8, 0xd1, 0xb9, 0x5a, 0x3a, 0x3e, 0x57, 0x4b, |
| 248 | 0x27, 0xe7, 0x6a, 0xe9, 0x7d, 0x5f, 0x45, 0x47, 0x7d, 0x15, 0x1d, 0xf7, 0x55, 0x74, 0xd2, 0x57, |
| 249 | 0xd1, 0x8f, 0xbe, 0x8a, 0x3e, 0xff, 0x54, 0x4b, 0x2f, 0x2b, 0x79, 0x10, 0x7f, 0x02, 0x00, 0x00, |
| 250 | 0xff, 0xff, 0xa8, 0x77, 0xef, 0x80, 0x9b, 0x06, 0x00, 0x00, |
| 251 | } |
| 252 | |
| 253 | func (m *Overhead) Marshal() (dAtA []byte, err error) { |
| 254 | size := m.Size() |
| 255 | dAtA = make([]byte, size) |
| 256 | n, err := m.MarshalToSizedBuffer(dAtA[:size]) |
| 257 | if err != nil { |
| 258 | return nil, err |
| 259 | } |
| 260 | return dAtA[:n], nil |
| 261 | } |
| 262 | |
| 263 | func (m *Overhead) MarshalTo(dAtA []byte) (int, error) { |
| 264 | size := m.Size() |
| 265 | return m.MarshalToSizedBuffer(dAtA[:size]) |
| 266 | } |
| 267 | |
| 268 | func (m *Overhead) MarshalToSizedBuffer(dAtA []byte) (int, error) { |
| 269 | i := len(dAtA) |
| 270 | _ = i |
| 271 | var l int |
| 272 | _ = l |
| 273 | if len(m.PodFixed) > 0 { |
| 274 | keysForPodFixed := make([]string, 0, len(m.PodFixed)) |
| 275 | for k := range m.PodFixed { |
| 276 | keysForPodFixed = append(keysForPodFixed, string(k)) |
| 277 | } |
| 278 | github_com_gogo_protobuf_sortkeys.Strings(keysForPodFixed) |
| 279 | for iNdEx := len(keysForPodFixed) - 1; iNdEx >= 0; iNdEx-- { |
| 280 | v := m.PodFixed[k8s_io_api_core_v1.ResourceName(keysForPodFixed[iNdEx])] |
| 281 | baseI := i |
| 282 | { |
| 283 | size, err := ((*resource.Quantity)(&v)).MarshalToSizedBuffer(dAtA[:i]) |
| 284 | if err != nil { |
| 285 | return 0, err |
| 286 | } |
| 287 | i -= size |
| 288 | i = encodeVarintGenerated(dAtA, i, uint64(size)) |
| 289 | } |
| 290 | i-- |
| 291 | dAtA[i] = 0x12 |
| 292 | i -= len(keysForPodFixed[iNdEx]) |
| 293 | copy(dAtA[i:], keysForPodFixed[iNdEx]) |
| 294 | i = encodeVarintGenerated(dAtA, i, uint64(len(keysForPodFixed[iNdEx]))) |
| 295 | i-- |
| 296 | dAtA[i] = 0xa |
| 297 | i = encodeVarintGenerated(dAtA, i, uint64(baseI-i)) |
| 298 | i-- |
| 299 | dAtA[i] = 0xa |
| 300 | } |
| 301 | } |
| 302 | return len(dAtA) - i, nil |
| 303 | } |
| 304 | |
| 305 | func (m *RuntimeClass) Marshal() (dAtA []byte, err error) { |
| 306 | size := m.Size() |
| 307 | dAtA = make([]byte, size) |
| 308 | n, err := m.MarshalToSizedBuffer(dAtA[:size]) |
| 309 | if err != nil { |
| 310 | return nil, err |
| 311 | } |
| 312 | return dAtA[:n], nil |
| 313 | } |
| 314 | |
| 315 | func (m *RuntimeClass) MarshalTo(dAtA []byte) (int, error) { |
| 316 | size := m.Size() |
| 317 | return m.MarshalToSizedBuffer(dAtA[:size]) |
| 318 | } |
| 319 | |
| 320 | func (m *RuntimeClass) MarshalToSizedBuffer(dAtA []byte) (int, error) { |
| 321 | i := len(dAtA) |
| 322 | _ = i |
| 323 | var l int |
| 324 | _ = l |
| 325 | { |
| 326 | size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) |
| 327 | if err != nil { |
| 328 | return 0, err |
| 329 | } |
| 330 | i -= size |
| 331 | i = encodeVarintGenerated(dAtA, i, uint64(size)) |
| 332 | } |
| 333 | i-- |
| 334 | dAtA[i] = 0x12 |
| 335 | { |
| 336 | size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) |
| 337 | if err != nil { |
| 338 | return 0, err |
| 339 | } |
| 340 | i -= size |
| 341 | i = encodeVarintGenerated(dAtA, i, uint64(size)) |
| 342 | } |
| 343 | i-- |
| 344 | dAtA[i] = 0xa |
| 345 | return len(dAtA) - i, nil |
| 346 | } |
| 347 | |
| 348 | func (m *RuntimeClassList) Marshal() (dAtA []byte, err error) { |
| 349 | size := m.Size() |
| 350 | dAtA = make([]byte, size) |
| 351 | n, err := m.MarshalToSizedBuffer(dAtA[:size]) |
| 352 | if err != nil { |
| 353 | return nil, err |
| 354 | } |
| 355 | return dAtA[:n], nil |
| 356 | } |
| 357 | |
| 358 | func (m *RuntimeClassList) MarshalTo(dAtA []byte) (int, error) { |
| 359 | size := m.Size() |
| 360 | return m.MarshalToSizedBuffer(dAtA[:size]) |
| 361 | } |
| 362 | |
| 363 | func (m *RuntimeClassList) MarshalToSizedBuffer(dAtA []byte) (int, error) { |
| 364 | i := len(dAtA) |
| 365 | _ = i |
| 366 | var l int |
| 367 | _ = l |
| 368 | if len(m.Items) > 0 { |
| 369 | for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { |
| 370 | { |
| 371 | size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) |
| 372 | if err != nil { |
| 373 | return 0, err |
| 374 | } |
| 375 | i -= size |
| 376 | i = encodeVarintGenerated(dAtA, i, uint64(size)) |
| 377 | } |
| 378 | i-- |
| 379 | dAtA[i] = 0x12 |
| 380 | } |
| 381 | } |
| 382 | { |
| 383 | size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) |
| 384 | if err != nil { |
| 385 | return 0, err |
| 386 | } |
| 387 | i -= size |
| 388 | i = encodeVarintGenerated(dAtA, i, uint64(size)) |
| 389 | } |
| 390 | i-- |
| 391 | dAtA[i] = 0xa |
| 392 | return len(dAtA) - i, nil |
| 393 | } |
| 394 | |
| 395 | func (m *RuntimeClassSpec) Marshal() (dAtA []byte, err error) { |
| 396 | size := m.Size() |
| 397 | dAtA = make([]byte, size) |
| 398 | n, err := m.MarshalToSizedBuffer(dAtA[:size]) |
| 399 | if err != nil { |
| 400 | return nil, err |
| 401 | } |
| 402 | return dAtA[:n], nil |
| 403 | } |
| 404 | |
| 405 | func (m *RuntimeClassSpec) MarshalTo(dAtA []byte) (int, error) { |
| 406 | size := m.Size() |
| 407 | return m.MarshalToSizedBuffer(dAtA[:size]) |
| 408 | } |
| 409 | |
| 410 | func (m *RuntimeClassSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { |
| 411 | i := len(dAtA) |
| 412 | _ = i |
| 413 | var l int |
| 414 | _ = l |
| 415 | if m.Scheduling != nil { |
| 416 | { |
| 417 | size, err := m.Scheduling.MarshalToSizedBuffer(dAtA[:i]) |
| 418 | if err != nil { |
| 419 | return 0, err |
| 420 | } |
| 421 | i -= size |
| 422 | i = encodeVarintGenerated(dAtA, i, uint64(size)) |
| 423 | } |
| 424 | i-- |
| 425 | dAtA[i] = 0x1a |
| 426 | } |
| 427 | if m.Overhead != nil { |
| 428 | { |
| 429 | size, err := m.Overhead.MarshalToSizedBuffer(dAtA[:i]) |
| 430 | if err != nil { |
| 431 | return 0, err |
| 432 | } |
| 433 | i -= size |
| 434 | i = encodeVarintGenerated(dAtA, i, uint64(size)) |
| 435 | } |
| 436 | i-- |
| 437 | dAtA[i] = 0x12 |
| 438 | } |
| 439 | i -= len(m.RuntimeHandler) |
| 440 | copy(dAtA[i:], m.RuntimeHandler) |
| 441 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.RuntimeHandler))) |
| 442 | i-- |
| 443 | dAtA[i] = 0xa |
| 444 | return len(dAtA) - i, nil |
| 445 | } |
| 446 | |
| 447 | func (m *Scheduling) Marshal() (dAtA []byte, err error) { |
| 448 | size := m.Size() |
| 449 | dAtA = make([]byte, size) |
| 450 | n, err := m.MarshalToSizedBuffer(dAtA[:size]) |
| 451 | if err != nil { |
| 452 | return nil, err |
| 453 | } |
| 454 | return dAtA[:n], nil |
| 455 | } |
| 456 | |
| 457 | func (m *Scheduling) MarshalTo(dAtA []byte) (int, error) { |
| 458 | size := m.Size() |
| 459 | return m.MarshalToSizedBuffer(dAtA[:size]) |
| 460 | } |
| 461 | |
| 462 | func (m *Scheduling) MarshalToSizedBuffer(dAtA []byte) (int, error) { |
| 463 | i := len(dAtA) |
| 464 | _ = i |
| 465 | var l int |
| 466 | _ = l |
| 467 | if len(m.Tolerations) > 0 { |
| 468 | for iNdEx := len(m.Tolerations) - 1; iNdEx >= 0; iNdEx-- { |
| 469 | { |
| 470 | size, err := m.Tolerations[iNdEx].MarshalToSizedBuffer(dAtA[:i]) |
| 471 | if err != nil { |
| 472 | return 0, err |
| 473 | } |
| 474 | i -= size |
| 475 | i = encodeVarintGenerated(dAtA, i, uint64(size)) |
| 476 | } |
| 477 | i-- |
| 478 | dAtA[i] = 0x12 |
| 479 | } |
| 480 | } |
| 481 | if len(m.NodeSelector) > 0 { |
| 482 | keysForNodeSelector := make([]string, 0, len(m.NodeSelector)) |
| 483 | for k := range m.NodeSelector { |
| 484 | keysForNodeSelector = append(keysForNodeSelector, string(k)) |
| 485 | } |
| 486 | github_com_gogo_protobuf_sortkeys.Strings(keysForNodeSelector) |
| 487 | for iNdEx := len(keysForNodeSelector) - 1; iNdEx >= 0; iNdEx-- { |
| 488 | v := m.NodeSelector[string(keysForNodeSelector[iNdEx])] |
| 489 | baseI := i |
| 490 | i -= len(v) |
| 491 | copy(dAtA[i:], v) |
| 492 | i = encodeVarintGenerated(dAtA, i, uint64(len(v))) |
| 493 | i-- |
| 494 | dAtA[i] = 0x12 |
| 495 | i -= len(keysForNodeSelector[iNdEx]) |
| 496 | copy(dAtA[i:], keysForNodeSelector[iNdEx]) |
| 497 | i = encodeVarintGenerated(dAtA, i, uint64(len(keysForNodeSelector[iNdEx]))) |
| 498 | i-- |
| 499 | dAtA[i] = 0xa |
| 500 | i = encodeVarintGenerated(dAtA, i, uint64(baseI-i)) |
| 501 | i-- |
| 502 | dAtA[i] = 0xa |
| 503 | } |
| 504 | } |
| 505 | return len(dAtA) - i, nil |
| 506 | } |
| 507 | |
| 508 | func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { |
| 509 | offset -= sovGenerated(v) |
| 510 | base := offset |
| 511 | for v >= 1<<7 { |
| 512 | dAtA[offset] = uint8(v&0x7f | 0x80) |
| 513 | v >>= 7 |
| 514 | offset++ |
| 515 | } |
| 516 | dAtA[offset] = uint8(v) |
| 517 | return base |
| 518 | } |
| 519 | func (m *Overhead) Size() (n int) { |
| 520 | if m == nil { |
| 521 | return 0 |
| 522 | } |
| 523 | var l int |
| 524 | _ = l |
| 525 | if len(m.PodFixed) > 0 { |
| 526 | for k, v := range m.PodFixed { |
| 527 | _ = k |
| 528 | _ = v |
| 529 | l = ((*resource.Quantity)(&v)).Size() |
| 530 | mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l)) |
| 531 | n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) |
| 532 | } |
| 533 | } |
| 534 | return n |
| 535 | } |
| 536 | |
| 537 | func (m *RuntimeClass) Size() (n int) { |
| 538 | if m == nil { |
| 539 | return 0 |
| 540 | } |
| 541 | var l int |
| 542 | _ = l |
| 543 | l = m.ObjectMeta.Size() |
| 544 | n += 1 + l + sovGenerated(uint64(l)) |
| 545 | l = m.Spec.Size() |
| 546 | n += 1 + l + sovGenerated(uint64(l)) |
| 547 | return n |
| 548 | } |
| 549 | |
| 550 | func (m *RuntimeClassList) Size() (n int) { |
| 551 | if m == nil { |
| 552 | return 0 |
| 553 | } |
| 554 | var l int |
| 555 | _ = l |
| 556 | l = m.ListMeta.Size() |
| 557 | n += 1 + l + sovGenerated(uint64(l)) |
| 558 | if len(m.Items) > 0 { |
| 559 | for _, e := range m.Items { |
| 560 | l = e.Size() |
| 561 | n += 1 + l + sovGenerated(uint64(l)) |
| 562 | } |
| 563 | } |
| 564 | return n |
| 565 | } |
| 566 | |
| 567 | func (m *RuntimeClassSpec) Size() (n int) { |
| 568 | if m == nil { |
| 569 | return 0 |
| 570 | } |
| 571 | var l int |
| 572 | _ = l |
| 573 | l = len(m.RuntimeHandler) |
| 574 | n += 1 + l + sovGenerated(uint64(l)) |
| 575 | if m.Overhead != nil { |
| 576 | l = m.Overhead.Size() |
| 577 | n += 1 + l + sovGenerated(uint64(l)) |
| 578 | } |
| 579 | if m.Scheduling != nil { |
| 580 | l = m.Scheduling.Size() |
| 581 | n += 1 + l + sovGenerated(uint64(l)) |
| 582 | } |
| 583 | return n |
| 584 | } |
| 585 | |
| 586 | func (m *Scheduling) Size() (n int) { |
| 587 | if m == nil { |
| 588 | return 0 |
| 589 | } |
| 590 | var l int |
| 591 | _ = l |
| 592 | if len(m.NodeSelector) > 0 { |
| 593 | for k, v := range m.NodeSelector { |
| 594 | _ = k |
| 595 | _ = v |
| 596 | mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) |
| 597 | n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) |
| 598 | } |
| 599 | } |
| 600 | if len(m.Tolerations) > 0 { |
| 601 | for _, e := range m.Tolerations { |
| 602 | l = e.Size() |
| 603 | n += 1 + l + sovGenerated(uint64(l)) |
| 604 | } |
| 605 | } |
| 606 | return n |
| 607 | } |
| 608 | |
| 609 | func sovGenerated(x uint64) (n int) { |
| 610 | return (math_bits.Len64(x|1) + 6) / 7 |
| 611 | } |
| 612 | func sozGenerated(x uint64) (n int) { |
| 613 | return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) |
| 614 | } |
| 615 | func (this *Overhead) String() string { |
| 616 | if this == nil { |
| 617 | return "nil" |
| 618 | } |
| 619 | keysForPodFixed := make([]string, 0, len(this.PodFixed)) |
| 620 | for k := range this.PodFixed { |
| 621 | keysForPodFixed = append(keysForPodFixed, string(k)) |
| 622 | } |
| 623 | github_com_gogo_protobuf_sortkeys.Strings(keysForPodFixed) |
| 624 | mapStringForPodFixed := "k8s_io_api_core_v1.ResourceList{" |
| 625 | for _, k := range keysForPodFixed { |
| 626 | mapStringForPodFixed += fmt.Sprintf("%v: %v,", k, this.PodFixed[k8s_io_api_core_v1.ResourceName(k)]) |
| 627 | } |
| 628 | mapStringForPodFixed += "}" |
| 629 | s := strings.Join([]string{`&Overhead{`, |
| 630 | `PodFixed:` + mapStringForPodFixed + `,`, |
| 631 | `}`, |
| 632 | }, "") |
| 633 | return s |
| 634 | } |
| 635 | func (this *RuntimeClass) String() string { |
| 636 | if this == nil { |
| 637 | return "nil" |
| 638 | } |
| 639 | s := strings.Join([]string{`&RuntimeClass{`, |
| 640 | `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, |
| 641 | `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "RuntimeClassSpec", "RuntimeClassSpec", 1), `&`, ``, 1) + `,`, |
| 642 | `}`, |
| 643 | }, "") |
| 644 | return s |
| 645 | } |
| 646 | func (this *RuntimeClassList) String() string { |
| 647 | if this == nil { |
| 648 | return "nil" |
| 649 | } |
| 650 | repeatedStringForItems := "[]RuntimeClass{" |
| 651 | for _, f := range this.Items { |
| 652 | repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "RuntimeClass", "RuntimeClass", 1), `&`, ``, 1) + "," |
| 653 | } |
| 654 | repeatedStringForItems += "}" |
| 655 | s := strings.Join([]string{`&RuntimeClassList{`, |
| 656 | `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, |
| 657 | `Items:` + repeatedStringForItems + `,`, |
| 658 | `}`, |
| 659 | }, "") |
| 660 | return s |
| 661 | } |
| 662 | func (this *RuntimeClassSpec) String() string { |
| 663 | if this == nil { |
| 664 | return "nil" |
| 665 | } |
| 666 | s := strings.Join([]string{`&RuntimeClassSpec{`, |
| 667 | `RuntimeHandler:` + fmt.Sprintf("%v", this.RuntimeHandler) + `,`, |
| 668 | `Overhead:` + strings.Replace(this.Overhead.String(), "Overhead", "Overhead", 1) + `,`, |
| 669 | `Scheduling:` + strings.Replace(this.Scheduling.String(), "Scheduling", "Scheduling", 1) + `,`, |
| 670 | `}`, |
| 671 | }, "") |
| 672 | return s |
| 673 | } |
| 674 | func (this *Scheduling) String() string { |
| 675 | if this == nil { |
| 676 | return "nil" |
| 677 | } |
| 678 | repeatedStringForTolerations := "[]Toleration{" |
| 679 | for _, f := range this.Tolerations { |
| 680 | repeatedStringForTolerations += fmt.Sprintf("%v", f) + "," |
| 681 | } |
| 682 | repeatedStringForTolerations += "}" |
| 683 | keysForNodeSelector := make([]string, 0, len(this.NodeSelector)) |
| 684 | for k := range this.NodeSelector { |
| 685 | keysForNodeSelector = append(keysForNodeSelector, k) |
| 686 | } |
| 687 | github_com_gogo_protobuf_sortkeys.Strings(keysForNodeSelector) |
| 688 | mapStringForNodeSelector := "map[string]string{" |
| 689 | for _, k := range keysForNodeSelector { |
| 690 | mapStringForNodeSelector += fmt.Sprintf("%v: %v,", k, this.NodeSelector[k]) |
| 691 | } |
| 692 | mapStringForNodeSelector += "}" |
| 693 | s := strings.Join([]string{`&Scheduling{`, |
| 694 | `NodeSelector:` + mapStringForNodeSelector + `,`, |
| 695 | `Tolerations:` + repeatedStringForTolerations + `,`, |
| 696 | `}`, |
| 697 | }, "") |
| 698 | return s |
| 699 | } |
| 700 | func valueToStringGenerated(v interface{}) string { |
| 701 | rv := reflect.ValueOf(v) |
| 702 | if rv.IsNil() { |
| 703 | return "nil" |
| 704 | } |
| 705 | pv := reflect.Indirect(rv).Interface() |
| 706 | return fmt.Sprintf("*%v", pv) |
| 707 | } |
| 708 | func (m *Overhead) Unmarshal(dAtA []byte) error { |
| 709 | l := len(dAtA) |
| 710 | iNdEx := 0 |
| 711 | for iNdEx < l { |
| 712 | preIndex := iNdEx |
| 713 | var wire uint64 |
| 714 | for shift := uint(0); ; shift += 7 { |
| 715 | if shift >= 64 { |
| 716 | return ErrIntOverflowGenerated |
| 717 | } |
| 718 | if iNdEx >= l { |
| 719 | return io.ErrUnexpectedEOF |
| 720 | } |
| 721 | b := dAtA[iNdEx] |
| 722 | iNdEx++ |
| 723 | wire |= uint64(b&0x7F) << shift |
| 724 | if b < 0x80 { |
| 725 | break |
| 726 | } |
| 727 | } |
| 728 | fieldNum := int32(wire >> 3) |
| 729 | wireType := int(wire & 0x7) |
| 730 | if wireType == 4 { |
| 731 | return fmt.Errorf("proto: Overhead: wiretype end group for non-group") |
| 732 | } |
| 733 | if fieldNum <= 0 { |
| 734 | return fmt.Errorf("proto: Overhead: illegal tag %d (wire type %d)", fieldNum, wire) |
| 735 | } |
| 736 | switch fieldNum { |
| 737 | case 1: |
| 738 | if wireType != 2 { |
| 739 | return fmt.Errorf("proto: wrong wireType = %d for field PodFixed", wireType) |
| 740 | } |
| 741 | var msglen int |
| 742 | for shift := uint(0); ; shift += 7 { |
| 743 | if shift >= 64 { |
| 744 | return ErrIntOverflowGenerated |
| 745 | } |
| 746 | if iNdEx >= l { |
| 747 | return io.ErrUnexpectedEOF |
| 748 | } |
| 749 | b := dAtA[iNdEx] |
| 750 | iNdEx++ |
| 751 | msglen |= int(b&0x7F) << shift |
| 752 | if b < 0x80 { |
| 753 | break |
| 754 | } |
| 755 | } |
| 756 | if msglen < 0 { |
| 757 | return ErrInvalidLengthGenerated |
| 758 | } |
| 759 | postIndex := iNdEx + msglen |
| 760 | if postIndex < 0 { |
| 761 | return ErrInvalidLengthGenerated |
| 762 | } |
| 763 | if postIndex > l { |
| 764 | return io.ErrUnexpectedEOF |
| 765 | } |
| 766 | if m.PodFixed == nil { |
| 767 | m.PodFixed = make(k8s_io_api_core_v1.ResourceList) |
| 768 | } |
| 769 | var mapkey k8s_io_api_core_v1.ResourceName |
| 770 | mapvalue := &resource.Quantity{} |
| 771 | for iNdEx < postIndex { |
| 772 | entryPreIndex := iNdEx |
| 773 | var wire uint64 |
| 774 | for shift := uint(0); ; shift += 7 { |
| 775 | if shift >= 64 { |
| 776 | return ErrIntOverflowGenerated |
| 777 | } |
| 778 | if iNdEx >= l { |
| 779 | return io.ErrUnexpectedEOF |
| 780 | } |
| 781 | b := dAtA[iNdEx] |
| 782 | iNdEx++ |
| 783 | wire |= uint64(b&0x7F) << shift |
| 784 | if b < 0x80 { |
| 785 | break |
| 786 | } |
| 787 | } |
| 788 | fieldNum := int32(wire >> 3) |
| 789 | if fieldNum == 1 { |
| 790 | var stringLenmapkey uint64 |
| 791 | for shift := uint(0); ; shift += 7 { |
| 792 | if shift >= 64 { |
| 793 | return ErrIntOverflowGenerated |
| 794 | } |
| 795 | if iNdEx >= l { |
| 796 | return io.ErrUnexpectedEOF |
| 797 | } |
| 798 | b := dAtA[iNdEx] |
| 799 | iNdEx++ |
| 800 | stringLenmapkey |= uint64(b&0x7F) << shift |
| 801 | if b < 0x80 { |
| 802 | break |
| 803 | } |
| 804 | } |
| 805 | intStringLenmapkey := int(stringLenmapkey) |
| 806 | if intStringLenmapkey < 0 { |
| 807 | return ErrInvalidLengthGenerated |
| 808 | } |
| 809 | postStringIndexmapkey := iNdEx + intStringLenmapkey |
| 810 | if postStringIndexmapkey < 0 { |
| 811 | return ErrInvalidLengthGenerated |
| 812 | } |
| 813 | if postStringIndexmapkey > l { |
| 814 | return io.ErrUnexpectedEOF |
| 815 | } |
| 816 | mapkey = k8s_io_api_core_v1.ResourceName(dAtA[iNdEx:postStringIndexmapkey]) |
| 817 | iNdEx = postStringIndexmapkey |
| 818 | } else if fieldNum == 2 { |
| 819 | var mapmsglen int |
| 820 | for shift := uint(0); ; shift += 7 { |
| 821 | if shift >= 64 { |
| 822 | return ErrIntOverflowGenerated |
| 823 | } |
| 824 | if iNdEx >= l { |
| 825 | return io.ErrUnexpectedEOF |
| 826 | } |
| 827 | b := dAtA[iNdEx] |
| 828 | iNdEx++ |
| 829 | mapmsglen |= int(b&0x7F) << shift |
| 830 | if b < 0x80 { |
| 831 | break |
| 832 | } |
| 833 | } |
| 834 | if mapmsglen < 0 { |
| 835 | return ErrInvalidLengthGenerated |
| 836 | } |
| 837 | postmsgIndex := iNdEx + mapmsglen |
| 838 | if postmsgIndex < 0 { |
| 839 | return ErrInvalidLengthGenerated |
| 840 | } |
| 841 | if postmsgIndex > l { |
| 842 | return io.ErrUnexpectedEOF |
| 843 | } |
| 844 | mapvalue = &resource.Quantity{} |
| 845 | if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { |
| 846 | return err |
| 847 | } |
| 848 | iNdEx = postmsgIndex |
| 849 | } else { |
| 850 | iNdEx = entryPreIndex |
| 851 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 852 | if err != nil { |
| 853 | return err |
| 854 | } |
| 855 | if skippy < 0 { |
| 856 | return ErrInvalidLengthGenerated |
| 857 | } |
| 858 | if (iNdEx + skippy) > postIndex { |
| 859 | return io.ErrUnexpectedEOF |
| 860 | } |
| 861 | iNdEx += skippy |
| 862 | } |
| 863 | } |
| 864 | m.PodFixed[k8s_io_api_core_v1.ResourceName(mapkey)] = ((k8s_io_apimachinery_pkg_api_resource.Quantity)(*mapvalue)) |
| 865 | iNdEx = postIndex |
| 866 | default: |
| 867 | iNdEx = preIndex |
| 868 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 869 | if err != nil { |
| 870 | return err |
| 871 | } |
| 872 | if skippy < 0 { |
| 873 | return ErrInvalidLengthGenerated |
| 874 | } |
| 875 | if (iNdEx + skippy) < 0 { |
| 876 | return ErrInvalidLengthGenerated |
| 877 | } |
| 878 | if (iNdEx + skippy) > l { |
| 879 | return io.ErrUnexpectedEOF |
| 880 | } |
| 881 | iNdEx += skippy |
| 882 | } |
| 883 | } |
| 884 | |
| 885 | if iNdEx > l { |
| 886 | return io.ErrUnexpectedEOF |
| 887 | } |
| 888 | return nil |
| 889 | } |
| 890 | func (m *RuntimeClass) Unmarshal(dAtA []byte) error { |
| 891 | l := len(dAtA) |
| 892 | iNdEx := 0 |
| 893 | for iNdEx < l { |
| 894 | preIndex := iNdEx |
| 895 | var wire uint64 |
| 896 | for shift := uint(0); ; shift += 7 { |
| 897 | if shift >= 64 { |
| 898 | return ErrIntOverflowGenerated |
| 899 | } |
| 900 | if iNdEx >= l { |
| 901 | return io.ErrUnexpectedEOF |
| 902 | } |
| 903 | b := dAtA[iNdEx] |
| 904 | iNdEx++ |
| 905 | wire |= uint64(b&0x7F) << shift |
| 906 | if b < 0x80 { |
| 907 | break |
| 908 | } |
| 909 | } |
| 910 | fieldNum := int32(wire >> 3) |
| 911 | wireType := int(wire & 0x7) |
| 912 | if wireType == 4 { |
| 913 | return fmt.Errorf("proto: RuntimeClass: wiretype end group for non-group") |
| 914 | } |
| 915 | if fieldNum <= 0 { |
| 916 | return fmt.Errorf("proto: RuntimeClass: illegal tag %d (wire type %d)", fieldNum, wire) |
| 917 | } |
| 918 | switch fieldNum { |
| 919 | case 1: |
| 920 | if wireType != 2 { |
| 921 | return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) |
| 922 | } |
| 923 | var msglen int |
| 924 | for shift := uint(0); ; shift += 7 { |
| 925 | if shift >= 64 { |
| 926 | return ErrIntOverflowGenerated |
| 927 | } |
| 928 | if iNdEx >= l { |
| 929 | return io.ErrUnexpectedEOF |
| 930 | } |
| 931 | b := dAtA[iNdEx] |
| 932 | iNdEx++ |
| 933 | msglen |= int(b&0x7F) << shift |
| 934 | if b < 0x80 { |
| 935 | break |
| 936 | } |
| 937 | } |
| 938 | if msglen < 0 { |
| 939 | return ErrInvalidLengthGenerated |
| 940 | } |
| 941 | postIndex := iNdEx + msglen |
| 942 | if postIndex < 0 { |
| 943 | return ErrInvalidLengthGenerated |
| 944 | } |
| 945 | if postIndex > l { |
| 946 | return io.ErrUnexpectedEOF |
| 947 | } |
| 948 | if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 949 | return err |
| 950 | } |
| 951 | iNdEx = postIndex |
| 952 | case 2: |
| 953 | if wireType != 2 { |
| 954 | return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) |
| 955 | } |
| 956 | var msglen int |
| 957 | for shift := uint(0); ; shift += 7 { |
| 958 | if shift >= 64 { |
| 959 | return ErrIntOverflowGenerated |
| 960 | } |
| 961 | if iNdEx >= l { |
| 962 | return io.ErrUnexpectedEOF |
| 963 | } |
| 964 | b := dAtA[iNdEx] |
| 965 | iNdEx++ |
| 966 | msglen |= int(b&0x7F) << shift |
| 967 | if b < 0x80 { |
| 968 | break |
| 969 | } |
| 970 | } |
| 971 | if msglen < 0 { |
| 972 | return ErrInvalidLengthGenerated |
| 973 | } |
| 974 | postIndex := iNdEx + msglen |
| 975 | if postIndex < 0 { |
| 976 | return ErrInvalidLengthGenerated |
| 977 | } |
| 978 | if postIndex > l { |
| 979 | return io.ErrUnexpectedEOF |
| 980 | } |
| 981 | if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 982 | return err |
| 983 | } |
| 984 | iNdEx = postIndex |
| 985 | default: |
| 986 | iNdEx = preIndex |
| 987 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 988 | if err != nil { |
| 989 | return err |
| 990 | } |
| 991 | if skippy < 0 { |
| 992 | return ErrInvalidLengthGenerated |
| 993 | } |
| 994 | if (iNdEx + skippy) < 0 { |
| 995 | return ErrInvalidLengthGenerated |
| 996 | } |
| 997 | if (iNdEx + skippy) > l { |
| 998 | return io.ErrUnexpectedEOF |
| 999 | } |
| 1000 | iNdEx += skippy |
| 1001 | } |
| 1002 | } |
| 1003 | |
| 1004 | if iNdEx > l { |
| 1005 | return io.ErrUnexpectedEOF |
| 1006 | } |
| 1007 | return nil |
| 1008 | } |
| 1009 | func (m *RuntimeClassList) Unmarshal(dAtA []byte) error { |
| 1010 | l := len(dAtA) |
| 1011 | iNdEx := 0 |
| 1012 | for iNdEx < l { |
| 1013 | preIndex := iNdEx |
| 1014 | var wire uint64 |
| 1015 | for shift := uint(0); ; shift += 7 { |
| 1016 | if shift >= 64 { |
| 1017 | return ErrIntOverflowGenerated |
| 1018 | } |
| 1019 | if iNdEx >= l { |
| 1020 | return io.ErrUnexpectedEOF |
| 1021 | } |
| 1022 | b := dAtA[iNdEx] |
| 1023 | iNdEx++ |
| 1024 | wire |= uint64(b&0x7F) << shift |
| 1025 | if b < 0x80 { |
| 1026 | break |
| 1027 | } |
| 1028 | } |
| 1029 | fieldNum := int32(wire >> 3) |
| 1030 | wireType := int(wire & 0x7) |
| 1031 | if wireType == 4 { |
| 1032 | return fmt.Errorf("proto: RuntimeClassList: wiretype end group for non-group") |
| 1033 | } |
| 1034 | if fieldNum <= 0 { |
| 1035 | return fmt.Errorf("proto: RuntimeClassList: illegal tag %d (wire type %d)", fieldNum, wire) |
| 1036 | } |
| 1037 | switch fieldNum { |
| 1038 | case 1: |
| 1039 | if wireType != 2 { |
| 1040 | return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) |
| 1041 | } |
| 1042 | var msglen int |
| 1043 | for shift := uint(0); ; shift += 7 { |
| 1044 | if shift >= 64 { |
| 1045 | return ErrIntOverflowGenerated |
| 1046 | } |
| 1047 | if iNdEx >= l { |
| 1048 | return io.ErrUnexpectedEOF |
| 1049 | } |
| 1050 | b := dAtA[iNdEx] |
| 1051 | iNdEx++ |
| 1052 | msglen |= int(b&0x7F) << shift |
| 1053 | if b < 0x80 { |
| 1054 | break |
| 1055 | } |
| 1056 | } |
| 1057 | if msglen < 0 { |
| 1058 | return ErrInvalidLengthGenerated |
| 1059 | } |
| 1060 | postIndex := iNdEx + msglen |
| 1061 | if postIndex < 0 { |
| 1062 | return ErrInvalidLengthGenerated |
| 1063 | } |
| 1064 | if postIndex > l { |
| 1065 | return io.ErrUnexpectedEOF |
| 1066 | } |
| 1067 | if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 1068 | return err |
| 1069 | } |
| 1070 | iNdEx = postIndex |
| 1071 | case 2: |
| 1072 | if wireType != 2 { |
| 1073 | return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) |
| 1074 | } |
| 1075 | var msglen int |
| 1076 | for shift := uint(0); ; shift += 7 { |
| 1077 | if shift >= 64 { |
| 1078 | return ErrIntOverflowGenerated |
| 1079 | } |
| 1080 | if iNdEx >= l { |
| 1081 | return io.ErrUnexpectedEOF |
| 1082 | } |
| 1083 | b := dAtA[iNdEx] |
| 1084 | iNdEx++ |
| 1085 | msglen |= int(b&0x7F) << shift |
| 1086 | if b < 0x80 { |
| 1087 | break |
| 1088 | } |
| 1089 | } |
| 1090 | if msglen < 0 { |
| 1091 | return ErrInvalidLengthGenerated |
| 1092 | } |
| 1093 | postIndex := iNdEx + msglen |
| 1094 | if postIndex < 0 { |
| 1095 | return ErrInvalidLengthGenerated |
| 1096 | } |
| 1097 | if postIndex > l { |
| 1098 | return io.ErrUnexpectedEOF |
| 1099 | } |
| 1100 | m.Items = append(m.Items, RuntimeClass{}) |
| 1101 | if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 1102 | return err |
| 1103 | } |
| 1104 | iNdEx = postIndex |
| 1105 | default: |
| 1106 | iNdEx = preIndex |
| 1107 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 1108 | if err != nil { |
| 1109 | return err |
| 1110 | } |
| 1111 | if skippy < 0 { |
| 1112 | return ErrInvalidLengthGenerated |
| 1113 | } |
| 1114 | if (iNdEx + skippy) < 0 { |
| 1115 | return ErrInvalidLengthGenerated |
| 1116 | } |
| 1117 | if (iNdEx + skippy) > l { |
| 1118 | return io.ErrUnexpectedEOF |
| 1119 | } |
| 1120 | iNdEx += skippy |
| 1121 | } |
| 1122 | } |
| 1123 | |
| 1124 | if iNdEx > l { |
| 1125 | return io.ErrUnexpectedEOF |
| 1126 | } |
| 1127 | return nil |
| 1128 | } |
| 1129 | func (m *RuntimeClassSpec) Unmarshal(dAtA []byte) error { |
| 1130 | l := len(dAtA) |
| 1131 | iNdEx := 0 |
| 1132 | for iNdEx < l { |
| 1133 | preIndex := iNdEx |
| 1134 | var wire uint64 |
| 1135 | for shift := uint(0); ; shift += 7 { |
| 1136 | if shift >= 64 { |
| 1137 | return ErrIntOverflowGenerated |
| 1138 | } |
| 1139 | if iNdEx >= l { |
| 1140 | return io.ErrUnexpectedEOF |
| 1141 | } |
| 1142 | b := dAtA[iNdEx] |
| 1143 | iNdEx++ |
| 1144 | wire |= uint64(b&0x7F) << shift |
| 1145 | if b < 0x80 { |
| 1146 | break |
| 1147 | } |
| 1148 | } |
| 1149 | fieldNum := int32(wire >> 3) |
| 1150 | wireType := int(wire & 0x7) |
| 1151 | if wireType == 4 { |
| 1152 | return fmt.Errorf("proto: RuntimeClassSpec: wiretype end group for non-group") |
| 1153 | } |
| 1154 | if fieldNum <= 0 { |
| 1155 | return fmt.Errorf("proto: RuntimeClassSpec: illegal tag %d (wire type %d)", fieldNum, wire) |
| 1156 | } |
| 1157 | switch fieldNum { |
| 1158 | case 1: |
| 1159 | if wireType != 2 { |
| 1160 | return fmt.Errorf("proto: wrong wireType = %d for field RuntimeHandler", wireType) |
| 1161 | } |
| 1162 | var stringLen uint64 |
| 1163 | for shift := uint(0); ; shift += 7 { |
| 1164 | if shift >= 64 { |
| 1165 | return ErrIntOverflowGenerated |
| 1166 | } |
| 1167 | if iNdEx >= l { |
| 1168 | return io.ErrUnexpectedEOF |
| 1169 | } |
| 1170 | b := dAtA[iNdEx] |
| 1171 | iNdEx++ |
| 1172 | stringLen |= uint64(b&0x7F) << shift |
| 1173 | if b < 0x80 { |
| 1174 | break |
| 1175 | } |
| 1176 | } |
| 1177 | intStringLen := int(stringLen) |
| 1178 | if intStringLen < 0 { |
| 1179 | return ErrInvalidLengthGenerated |
| 1180 | } |
| 1181 | postIndex := iNdEx + intStringLen |
| 1182 | if postIndex < 0 { |
| 1183 | return ErrInvalidLengthGenerated |
| 1184 | } |
| 1185 | if postIndex > l { |
| 1186 | return io.ErrUnexpectedEOF |
| 1187 | } |
| 1188 | m.RuntimeHandler = string(dAtA[iNdEx:postIndex]) |
| 1189 | iNdEx = postIndex |
| 1190 | case 2: |
| 1191 | if wireType != 2 { |
| 1192 | return fmt.Errorf("proto: wrong wireType = %d for field Overhead", wireType) |
| 1193 | } |
| 1194 | var msglen int |
| 1195 | for shift := uint(0); ; shift += 7 { |
| 1196 | if shift >= 64 { |
| 1197 | return ErrIntOverflowGenerated |
| 1198 | } |
| 1199 | if iNdEx >= l { |
| 1200 | return io.ErrUnexpectedEOF |
| 1201 | } |
| 1202 | b := dAtA[iNdEx] |
| 1203 | iNdEx++ |
| 1204 | msglen |= int(b&0x7F) << shift |
| 1205 | if b < 0x80 { |
| 1206 | break |
| 1207 | } |
| 1208 | } |
| 1209 | if msglen < 0 { |
| 1210 | return ErrInvalidLengthGenerated |
| 1211 | } |
| 1212 | postIndex := iNdEx + msglen |
| 1213 | if postIndex < 0 { |
| 1214 | return ErrInvalidLengthGenerated |
| 1215 | } |
| 1216 | if postIndex > l { |
| 1217 | return io.ErrUnexpectedEOF |
| 1218 | } |
| 1219 | if m.Overhead == nil { |
| 1220 | m.Overhead = &Overhead{} |
| 1221 | } |
| 1222 | if err := m.Overhead.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 1223 | return err |
| 1224 | } |
| 1225 | iNdEx = postIndex |
| 1226 | case 3: |
| 1227 | if wireType != 2 { |
| 1228 | return fmt.Errorf("proto: wrong wireType = %d for field Scheduling", wireType) |
| 1229 | } |
| 1230 | var msglen int |
| 1231 | for shift := uint(0); ; shift += 7 { |
| 1232 | if shift >= 64 { |
| 1233 | return ErrIntOverflowGenerated |
| 1234 | } |
| 1235 | if iNdEx >= l { |
| 1236 | return io.ErrUnexpectedEOF |
| 1237 | } |
| 1238 | b := dAtA[iNdEx] |
| 1239 | iNdEx++ |
| 1240 | msglen |= int(b&0x7F) << shift |
| 1241 | if b < 0x80 { |
| 1242 | break |
| 1243 | } |
| 1244 | } |
| 1245 | if msglen < 0 { |
| 1246 | return ErrInvalidLengthGenerated |
| 1247 | } |
| 1248 | postIndex := iNdEx + msglen |
| 1249 | if postIndex < 0 { |
| 1250 | return ErrInvalidLengthGenerated |
| 1251 | } |
| 1252 | if postIndex > l { |
| 1253 | return io.ErrUnexpectedEOF |
| 1254 | } |
| 1255 | if m.Scheduling == nil { |
| 1256 | m.Scheduling = &Scheduling{} |
| 1257 | } |
| 1258 | if err := m.Scheduling.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 1259 | return err |
| 1260 | } |
| 1261 | iNdEx = postIndex |
| 1262 | default: |
| 1263 | iNdEx = preIndex |
| 1264 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 1265 | if err != nil { |
| 1266 | return err |
| 1267 | } |
| 1268 | if skippy < 0 { |
| 1269 | return ErrInvalidLengthGenerated |
| 1270 | } |
| 1271 | if (iNdEx + skippy) < 0 { |
| 1272 | return ErrInvalidLengthGenerated |
| 1273 | } |
| 1274 | if (iNdEx + skippy) > l { |
| 1275 | return io.ErrUnexpectedEOF |
| 1276 | } |
| 1277 | iNdEx += skippy |
| 1278 | } |
| 1279 | } |
| 1280 | |
| 1281 | if iNdEx > l { |
| 1282 | return io.ErrUnexpectedEOF |
| 1283 | } |
| 1284 | return nil |
| 1285 | } |
| 1286 | func (m *Scheduling) Unmarshal(dAtA []byte) error { |
| 1287 | l := len(dAtA) |
| 1288 | iNdEx := 0 |
| 1289 | for iNdEx < l { |
| 1290 | preIndex := iNdEx |
| 1291 | var wire uint64 |
| 1292 | for shift := uint(0); ; shift += 7 { |
| 1293 | if shift >= 64 { |
| 1294 | return ErrIntOverflowGenerated |
| 1295 | } |
| 1296 | if iNdEx >= l { |
| 1297 | return io.ErrUnexpectedEOF |
| 1298 | } |
| 1299 | b := dAtA[iNdEx] |
| 1300 | iNdEx++ |
| 1301 | wire |= uint64(b&0x7F) << shift |
| 1302 | if b < 0x80 { |
| 1303 | break |
| 1304 | } |
| 1305 | } |
| 1306 | fieldNum := int32(wire >> 3) |
| 1307 | wireType := int(wire & 0x7) |
| 1308 | if wireType == 4 { |
| 1309 | return fmt.Errorf("proto: Scheduling: wiretype end group for non-group") |
| 1310 | } |
| 1311 | if fieldNum <= 0 { |
| 1312 | return fmt.Errorf("proto: Scheduling: illegal tag %d (wire type %d)", fieldNum, wire) |
| 1313 | } |
| 1314 | switch fieldNum { |
| 1315 | case 1: |
| 1316 | if wireType != 2 { |
| 1317 | return fmt.Errorf("proto: wrong wireType = %d for field NodeSelector", wireType) |
| 1318 | } |
| 1319 | var msglen int |
| 1320 | for shift := uint(0); ; shift += 7 { |
| 1321 | if shift >= 64 { |
| 1322 | return ErrIntOverflowGenerated |
| 1323 | } |
| 1324 | if iNdEx >= l { |
| 1325 | return io.ErrUnexpectedEOF |
| 1326 | } |
| 1327 | b := dAtA[iNdEx] |
| 1328 | iNdEx++ |
| 1329 | msglen |= int(b&0x7F) << shift |
| 1330 | if b < 0x80 { |
| 1331 | break |
| 1332 | } |
| 1333 | } |
| 1334 | if msglen < 0 { |
| 1335 | return ErrInvalidLengthGenerated |
| 1336 | } |
| 1337 | postIndex := iNdEx + msglen |
| 1338 | if postIndex < 0 { |
| 1339 | return ErrInvalidLengthGenerated |
| 1340 | } |
| 1341 | if postIndex > l { |
| 1342 | return io.ErrUnexpectedEOF |
| 1343 | } |
| 1344 | if m.NodeSelector == nil { |
| 1345 | m.NodeSelector = make(map[string]string) |
| 1346 | } |
| 1347 | var mapkey string |
| 1348 | var mapvalue string |
| 1349 | for iNdEx < postIndex { |
| 1350 | entryPreIndex := iNdEx |
| 1351 | var wire uint64 |
| 1352 | for shift := uint(0); ; shift += 7 { |
| 1353 | if shift >= 64 { |
| 1354 | return ErrIntOverflowGenerated |
| 1355 | } |
| 1356 | if iNdEx >= l { |
| 1357 | return io.ErrUnexpectedEOF |
| 1358 | } |
| 1359 | b := dAtA[iNdEx] |
| 1360 | iNdEx++ |
| 1361 | wire |= uint64(b&0x7F) << shift |
| 1362 | if b < 0x80 { |
| 1363 | break |
| 1364 | } |
| 1365 | } |
| 1366 | fieldNum := int32(wire >> 3) |
| 1367 | if fieldNum == 1 { |
| 1368 | var stringLenmapkey uint64 |
| 1369 | for shift := uint(0); ; shift += 7 { |
| 1370 | if shift >= 64 { |
| 1371 | return ErrIntOverflowGenerated |
| 1372 | } |
| 1373 | if iNdEx >= l { |
| 1374 | return io.ErrUnexpectedEOF |
| 1375 | } |
| 1376 | b := dAtA[iNdEx] |
| 1377 | iNdEx++ |
| 1378 | stringLenmapkey |= uint64(b&0x7F) << shift |
| 1379 | if b < 0x80 { |
| 1380 | break |
| 1381 | } |
| 1382 | } |
| 1383 | intStringLenmapkey := int(stringLenmapkey) |
| 1384 | if intStringLenmapkey < 0 { |
| 1385 | return ErrInvalidLengthGenerated |
| 1386 | } |
| 1387 | postStringIndexmapkey := iNdEx + intStringLenmapkey |
| 1388 | if postStringIndexmapkey < 0 { |
| 1389 | return ErrInvalidLengthGenerated |
| 1390 | } |
| 1391 | if postStringIndexmapkey > l { |
| 1392 | return io.ErrUnexpectedEOF |
| 1393 | } |
| 1394 | mapkey = string(dAtA[iNdEx:postStringIndexmapkey]) |
| 1395 | iNdEx = postStringIndexmapkey |
| 1396 | } else if fieldNum == 2 { |
| 1397 | var stringLenmapvalue uint64 |
| 1398 | for shift := uint(0); ; shift += 7 { |
| 1399 | if shift >= 64 { |
| 1400 | return ErrIntOverflowGenerated |
| 1401 | } |
| 1402 | if iNdEx >= l { |
| 1403 | return io.ErrUnexpectedEOF |
| 1404 | } |
| 1405 | b := dAtA[iNdEx] |
| 1406 | iNdEx++ |
| 1407 | stringLenmapvalue |= uint64(b&0x7F) << shift |
| 1408 | if b < 0x80 { |
| 1409 | break |
| 1410 | } |
| 1411 | } |
| 1412 | intStringLenmapvalue := int(stringLenmapvalue) |
| 1413 | if intStringLenmapvalue < 0 { |
| 1414 | return ErrInvalidLengthGenerated |
| 1415 | } |
| 1416 | postStringIndexmapvalue := iNdEx + intStringLenmapvalue |
| 1417 | if postStringIndexmapvalue < 0 { |
| 1418 | return ErrInvalidLengthGenerated |
| 1419 | } |
| 1420 | if postStringIndexmapvalue > l { |
| 1421 | return io.ErrUnexpectedEOF |
| 1422 | } |
| 1423 | mapvalue = string(dAtA[iNdEx:postStringIndexmapvalue]) |
| 1424 | iNdEx = postStringIndexmapvalue |
| 1425 | } else { |
| 1426 | iNdEx = entryPreIndex |
| 1427 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 1428 | if err != nil { |
| 1429 | return err |
| 1430 | } |
| 1431 | if skippy < 0 { |
| 1432 | return ErrInvalidLengthGenerated |
| 1433 | } |
| 1434 | if (iNdEx + skippy) > postIndex { |
| 1435 | return io.ErrUnexpectedEOF |
| 1436 | } |
| 1437 | iNdEx += skippy |
| 1438 | } |
| 1439 | } |
| 1440 | m.NodeSelector[mapkey] = mapvalue |
| 1441 | iNdEx = postIndex |
| 1442 | case 2: |
| 1443 | if wireType != 2 { |
| 1444 | return fmt.Errorf("proto: wrong wireType = %d for field Tolerations", wireType) |
| 1445 | } |
| 1446 | var msglen int |
| 1447 | for shift := uint(0); ; shift += 7 { |
| 1448 | if shift >= 64 { |
| 1449 | return ErrIntOverflowGenerated |
| 1450 | } |
| 1451 | if iNdEx >= l { |
| 1452 | return io.ErrUnexpectedEOF |
| 1453 | } |
| 1454 | b := dAtA[iNdEx] |
| 1455 | iNdEx++ |
| 1456 | msglen |= int(b&0x7F) << shift |
| 1457 | if b < 0x80 { |
| 1458 | break |
| 1459 | } |
| 1460 | } |
| 1461 | if msglen < 0 { |
| 1462 | return ErrInvalidLengthGenerated |
| 1463 | } |
| 1464 | postIndex := iNdEx + msglen |
| 1465 | if postIndex < 0 { |
| 1466 | return ErrInvalidLengthGenerated |
| 1467 | } |
| 1468 | if postIndex > l { |
| 1469 | return io.ErrUnexpectedEOF |
| 1470 | } |
| 1471 | m.Tolerations = append(m.Tolerations, v11.Toleration{}) |
| 1472 | if err := m.Tolerations[len(m.Tolerations)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 1473 | return err |
| 1474 | } |
| 1475 | iNdEx = postIndex |
| 1476 | default: |
| 1477 | iNdEx = preIndex |
| 1478 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 1479 | if err != nil { |
| 1480 | return err |
| 1481 | } |
| 1482 | if skippy < 0 { |
| 1483 | return ErrInvalidLengthGenerated |
| 1484 | } |
| 1485 | if (iNdEx + skippy) < 0 { |
| 1486 | return ErrInvalidLengthGenerated |
| 1487 | } |
| 1488 | if (iNdEx + skippy) > l { |
| 1489 | return io.ErrUnexpectedEOF |
| 1490 | } |
| 1491 | iNdEx += skippy |
| 1492 | } |
| 1493 | } |
| 1494 | |
| 1495 | if iNdEx > l { |
| 1496 | return io.ErrUnexpectedEOF |
| 1497 | } |
| 1498 | return nil |
| 1499 | } |
| 1500 | func skipGenerated(dAtA []byte) (n int, err error) { |
| 1501 | l := len(dAtA) |
| 1502 | iNdEx := 0 |
| 1503 | depth := 0 |
| 1504 | for iNdEx < l { |
| 1505 | var wire uint64 |
| 1506 | for shift := uint(0); ; shift += 7 { |
| 1507 | if shift >= 64 { |
| 1508 | return 0, ErrIntOverflowGenerated |
| 1509 | } |
| 1510 | if iNdEx >= l { |
| 1511 | return 0, io.ErrUnexpectedEOF |
| 1512 | } |
| 1513 | b := dAtA[iNdEx] |
| 1514 | iNdEx++ |
| 1515 | wire |= (uint64(b) & 0x7F) << shift |
| 1516 | if b < 0x80 { |
| 1517 | break |
| 1518 | } |
| 1519 | } |
| 1520 | wireType := int(wire & 0x7) |
| 1521 | switch wireType { |
| 1522 | case 0: |
| 1523 | for shift := uint(0); ; shift += 7 { |
| 1524 | if shift >= 64 { |
| 1525 | return 0, ErrIntOverflowGenerated |
| 1526 | } |
| 1527 | if iNdEx >= l { |
| 1528 | return 0, io.ErrUnexpectedEOF |
| 1529 | } |
| 1530 | iNdEx++ |
| 1531 | if dAtA[iNdEx-1] < 0x80 { |
| 1532 | break |
| 1533 | } |
| 1534 | } |
| 1535 | case 1: |
| 1536 | iNdEx += 8 |
| 1537 | case 2: |
| 1538 | var length int |
| 1539 | for shift := uint(0); ; shift += 7 { |
| 1540 | if shift >= 64 { |
| 1541 | return 0, ErrIntOverflowGenerated |
| 1542 | } |
| 1543 | if iNdEx >= l { |
| 1544 | return 0, io.ErrUnexpectedEOF |
| 1545 | } |
| 1546 | b := dAtA[iNdEx] |
| 1547 | iNdEx++ |
| 1548 | length |= (int(b) & 0x7F) << shift |
| 1549 | if b < 0x80 { |
| 1550 | break |
| 1551 | } |
| 1552 | } |
| 1553 | if length < 0 { |
| 1554 | return 0, ErrInvalidLengthGenerated |
| 1555 | } |
| 1556 | iNdEx += length |
| 1557 | case 3: |
| 1558 | depth++ |
| 1559 | case 4: |
| 1560 | if depth == 0 { |
| 1561 | return 0, ErrUnexpectedEndOfGroupGenerated |
| 1562 | } |
| 1563 | depth-- |
| 1564 | case 5: |
| 1565 | iNdEx += 4 |
| 1566 | default: |
| 1567 | return 0, fmt.Errorf("proto: illegal wireType %d", wireType) |
| 1568 | } |
| 1569 | if iNdEx < 0 { |
| 1570 | return 0, ErrInvalidLengthGenerated |
| 1571 | } |
| 1572 | if depth == 0 { |
| 1573 | return iNdEx, nil |
| 1574 | } |
| 1575 | } |
| 1576 | return 0, io.ErrUnexpectedEOF |
| 1577 | } |
| 1578 | |
| 1579 | var ( |
| 1580 | ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") |
| 1581 | ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") |
| 1582 | ErrUnexpectedEndOfGroupGenerated = fmt.Errorf("proto: unexpected end of group") |
| 1583 | ) |