generated.pb.go 39 KB

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