generated.pb.go 36 KB

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