generated.pb.go 110 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419
  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/autoscaling/v2beta2/generated.proto
  15. /*
  16. Package v2beta2 is a generated protocol buffer package.
  17. It is generated from these files:
  18. k8s.io/kubernetes/vendor/k8s.io/api/autoscaling/v2beta2/generated.proto
  19. It has these top-level messages:
  20. CrossVersionObjectReference
  21. ExternalMetricSource
  22. ExternalMetricStatus
  23. HorizontalPodAutoscaler
  24. HorizontalPodAutoscalerCondition
  25. HorizontalPodAutoscalerList
  26. HorizontalPodAutoscalerSpec
  27. HorizontalPodAutoscalerStatus
  28. MetricIdentifier
  29. MetricSpec
  30. MetricStatus
  31. MetricTarget
  32. MetricValueStatus
  33. ObjectMetricSource
  34. ObjectMetricStatus
  35. PodsMetricSource
  36. PodsMetricStatus
  37. ResourceMetricSource
  38. ResourceMetricStatus
  39. */
  40. package v2beta2
  41. import proto "github.com/gogo/protobuf/proto"
  42. import fmt "fmt"
  43. import math "math"
  44. import k8s_io_apimachinery_pkg_api_resource "k8s.io/apimachinery/pkg/api/resource"
  45. import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
  46. import k8s_io_api_core_v1 "k8s.io/api/core/v1"
  47. import strings "strings"
  48. import reflect "reflect"
  49. import io "io"
  50. // Reference imports to suppress errors if they are not otherwise used.
  51. var _ = proto.Marshal
  52. var _ = fmt.Errorf
  53. var _ = math.Inf
  54. // This is a compile-time assertion to ensure that this generated file
  55. // is compatible with the proto package it is being compiled against.
  56. // A compilation error at this line likely means your copy of the
  57. // proto package needs to be updated.
  58. const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
  59. func (m *CrossVersionObjectReference) Reset() { *m = CrossVersionObjectReference{} }
  60. func (*CrossVersionObjectReference) ProtoMessage() {}
  61. func (*CrossVersionObjectReference) Descriptor() ([]byte, []int) {
  62. return fileDescriptorGenerated, []int{0}
  63. }
  64. func (m *ExternalMetricSource) Reset() { *m = ExternalMetricSource{} }
  65. func (*ExternalMetricSource) ProtoMessage() {}
  66. func (*ExternalMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} }
  67. func (m *ExternalMetricStatus) Reset() { *m = ExternalMetricStatus{} }
  68. func (*ExternalMetricStatus) ProtoMessage() {}
  69. func (*ExternalMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} }
  70. func (m *HorizontalPodAutoscaler) Reset() { *m = HorizontalPodAutoscaler{} }
  71. func (*HorizontalPodAutoscaler) ProtoMessage() {}
  72. func (*HorizontalPodAutoscaler) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} }
  73. func (m *HorizontalPodAutoscalerCondition) Reset() { *m = HorizontalPodAutoscalerCondition{} }
  74. func (*HorizontalPodAutoscalerCondition) ProtoMessage() {}
  75. func (*HorizontalPodAutoscalerCondition) Descriptor() ([]byte, []int) {
  76. return fileDescriptorGenerated, []int{4}
  77. }
  78. func (m *HorizontalPodAutoscalerList) Reset() { *m = HorizontalPodAutoscalerList{} }
  79. func (*HorizontalPodAutoscalerList) ProtoMessage() {}
  80. func (*HorizontalPodAutoscalerList) Descriptor() ([]byte, []int) {
  81. return fileDescriptorGenerated, []int{5}
  82. }
  83. func (m *HorizontalPodAutoscalerSpec) Reset() { *m = HorizontalPodAutoscalerSpec{} }
  84. func (*HorizontalPodAutoscalerSpec) ProtoMessage() {}
  85. func (*HorizontalPodAutoscalerSpec) Descriptor() ([]byte, []int) {
  86. return fileDescriptorGenerated, []int{6}
  87. }
  88. func (m *HorizontalPodAutoscalerStatus) Reset() { *m = HorizontalPodAutoscalerStatus{} }
  89. func (*HorizontalPodAutoscalerStatus) ProtoMessage() {}
  90. func (*HorizontalPodAutoscalerStatus) Descriptor() ([]byte, []int) {
  91. return fileDescriptorGenerated, []int{7}
  92. }
  93. func (m *MetricIdentifier) Reset() { *m = MetricIdentifier{} }
  94. func (*MetricIdentifier) ProtoMessage() {}
  95. func (*MetricIdentifier) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} }
  96. func (m *MetricSpec) Reset() { *m = MetricSpec{} }
  97. func (*MetricSpec) ProtoMessage() {}
  98. func (*MetricSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} }
  99. func (m *MetricStatus) Reset() { *m = MetricStatus{} }
  100. func (*MetricStatus) ProtoMessage() {}
  101. func (*MetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} }
  102. func (m *MetricTarget) Reset() { *m = MetricTarget{} }
  103. func (*MetricTarget) ProtoMessage() {}
  104. func (*MetricTarget) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} }
  105. func (m *MetricValueStatus) Reset() { *m = MetricValueStatus{} }
  106. func (*MetricValueStatus) ProtoMessage() {}
  107. func (*MetricValueStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} }
  108. func (m *ObjectMetricSource) Reset() { *m = ObjectMetricSource{} }
  109. func (*ObjectMetricSource) ProtoMessage() {}
  110. func (*ObjectMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} }
  111. func (m *ObjectMetricStatus) Reset() { *m = ObjectMetricStatus{} }
  112. func (*ObjectMetricStatus) ProtoMessage() {}
  113. func (*ObjectMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} }
  114. func (m *PodsMetricSource) Reset() { *m = PodsMetricSource{} }
  115. func (*PodsMetricSource) ProtoMessage() {}
  116. func (*PodsMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} }
  117. func (m *PodsMetricStatus) Reset() { *m = PodsMetricStatus{} }
  118. func (*PodsMetricStatus) ProtoMessage() {}
  119. func (*PodsMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} }
  120. func (m *ResourceMetricSource) Reset() { *m = ResourceMetricSource{} }
  121. func (*ResourceMetricSource) ProtoMessage() {}
  122. func (*ResourceMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{17} }
  123. func (m *ResourceMetricStatus) Reset() { *m = ResourceMetricStatus{} }
  124. func (*ResourceMetricStatus) ProtoMessage() {}
  125. func (*ResourceMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{18} }
  126. func init() {
  127. proto.RegisterType((*CrossVersionObjectReference)(nil), "k8s.io.api.autoscaling.v2beta2.CrossVersionObjectReference")
  128. proto.RegisterType((*ExternalMetricSource)(nil), "k8s.io.api.autoscaling.v2beta2.ExternalMetricSource")
  129. proto.RegisterType((*ExternalMetricStatus)(nil), "k8s.io.api.autoscaling.v2beta2.ExternalMetricStatus")
  130. proto.RegisterType((*HorizontalPodAutoscaler)(nil), "k8s.io.api.autoscaling.v2beta2.HorizontalPodAutoscaler")
  131. proto.RegisterType((*HorizontalPodAutoscalerCondition)(nil), "k8s.io.api.autoscaling.v2beta2.HorizontalPodAutoscalerCondition")
  132. proto.RegisterType((*HorizontalPodAutoscalerList)(nil), "k8s.io.api.autoscaling.v2beta2.HorizontalPodAutoscalerList")
  133. proto.RegisterType((*HorizontalPodAutoscalerSpec)(nil), "k8s.io.api.autoscaling.v2beta2.HorizontalPodAutoscalerSpec")
  134. proto.RegisterType((*HorizontalPodAutoscalerStatus)(nil), "k8s.io.api.autoscaling.v2beta2.HorizontalPodAutoscalerStatus")
  135. proto.RegisterType((*MetricIdentifier)(nil), "k8s.io.api.autoscaling.v2beta2.MetricIdentifier")
  136. proto.RegisterType((*MetricSpec)(nil), "k8s.io.api.autoscaling.v2beta2.MetricSpec")
  137. proto.RegisterType((*MetricStatus)(nil), "k8s.io.api.autoscaling.v2beta2.MetricStatus")
  138. proto.RegisterType((*MetricTarget)(nil), "k8s.io.api.autoscaling.v2beta2.MetricTarget")
  139. proto.RegisterType((*MetricValueStatus)(nil), "k8s.io.api.autoscaling.v2beta2.MetricValueStatus")
  140. proto.RegisterType((*ObjectMetricSource)(nil), "k8s.io.api.autoscaling.v2beta2.ObjectMetricSource")
  141. proto.RegisterType((*ObjectMetricStatus)(nil), "k8s.io.api.autoscaling.v2beta2.ObjectMetricStatus")
  142. proto.RegisterType((*PodsMetricSource)(nil), "k8s.io.api.autoscaling.v2beta2.PodsMetricSource")
  143. proto.RegisterType((*PodsMetricStatus)(nil), "k8s.io.api.autoscaling.v2beta2.PodsMetricStatus")
  144. proto.RegisterType((*ResourceMetricSource)(nil), "k8s.io.api.autoscaling.v2beta2.ResourceMetricSource")
  145. proto.RegisterType((*ResourceMetricStatus)(nil), "k8s.io.api.autoscaling.v2beta2.ResourceMetricStatus")
  146. }
  147. func (m *CrossVersionObjectReference) Marshal() (dAtA []byte, err error) {
  148. size := m.Size()
  149. dAtA = make([]byte, size)
  150. n, err := m.MarshalTo(dAtA)
  151. if err != nil {
  152. return nil, err
  153. }
  154. return dAtA[:n], nil
  155. }
  156. func (m *CrossVersionObjectReference) MarshalTo(dAtA []byte) (int, error) {
  157. var i int
  158. _ = i
  159. var l int
  160. _ = l
  161. dAtA[i] = 0xa
  162. i++
  163. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind)))
  164. i += copy(dAtA[i:], m.Kind)
  165. dAtA[i] = 0x12
  166. i++
  167. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name)))
  168. i += copy(dAtA[i:], m.Name)
  169. dAtA[i] = 0x1a
  170. i++
  171. i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIVersion)))
  172. i += copy(dAtA[i:], m.APIVersion)
  173. return i, nil
  174. }
  175. func (m *ExternalMetricSource) Marshal() (dAtA []byte, err error) {
  176. size := m.Size()
  177. dAtA = make([]byte, size)
  178. n, err := m.MarshalTo(dAtA)
  179. if err != nil {
  180. return nil, err
  181. }
  182. return dAtA[:n], nil
  183. }
  184. func (m *ExternalMetricSource) MarshalTo(dAtA []byte) (int, error) {
  185. var i int
  186. _ = i
  187. var l int
  188. _ = l
  189. dAtA[i] = 0xa
  190. i++
  191. i = encodeVarintGenerated(dAtA, i, uint64(m.Metric.Size()))
  192. n1, err := m.Metric.MarshalTo(dAtA[i:])
  193. if err != nil {
  194. return 0, err
  195. }
  196. i += n1
  197. dAtA[i] = 0x12
  198. i++
  199. i = encodeVarintGenerated(dAtA, i, uint64(m.Target.Size()))
  200. n2, err := m.Target.MarshalTo(dAtA[i:])
  201. if err != nil {
  202. return 0, err
  203. }
  204. i += n2
  205. return i, nil
  206. }
  207. func (m *ExternalMetricStatus) Marshal() (dAtA []byte, err error) {
  208. size := m.Size()
  209. dAtA = make([]byte, size)
  210. n, err := m.MarshalTo(dAtA)
  211. if err != nil {
  212. return nil, err
  213. }
  214. return dAtA[:n], nil
  215. }
  216. func (m *ExternalMetricStatus) MarshalTo(dAtA []byte) (int, error) {
  217. var i int
  218. _ = i
  219. var l int
  220. _ = l
  221. dAtA[i] = 0xa
  222. i++
  223. i = encodeVarintGenerated(dAtA, i, uint64(m.Metric.Size()))
  224. n3, err := m.Metric.MarshalTo(dAtA[i:])
  225. if err != nil {
  226. return 0, err
  227. }
  228. i += n3
  229. dAtA[i] = 0x12
  230. i++
  231. i = encodeVarintGenerated(dAtA, i, uint64(m.Current.Size()))
  232. n4, err := m.Current.MarshalTo(dAtA[i:])
  233. if err != nil {
  234. return 0, err
  235. }
  236. i += n4
  237. return i, nil
  238. }
  239. func (m *HorizontalPodAutoscaler) Marshal() (dAtA []byte, err error) {
  240. size := m.Size()
  241. dAtA = make([]byte, size)
  242. n, err := m.MarshalTo(dAtA)
  243. if err != nil {
  244. return nil, err
  245. }
  246. return dAtA[:n], nil
  247. }
  248. func (m *HorizontalPodAutoscaler) MarshalTo(dAtA []byte) (int, error) {
  249. var i int
  250. _ = i
  251. var l int
  252. _ = l
  253. dAtA[i] = 0xa
  254. i++
  255. i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size()))
  256. n5, err := m.ObjectMeta.MarshalTo(dAtA[i:])
  257. if err != nil {
  258. return 0, err
  259. }
  260. i += n5
  261. dAtA[i] = 0x12
  262. i++
  263. i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size()))
  264. n6, err := m.Spec.MarshalTo(dAtA[i:])
  265. if err != nil {
  266. return 0, err
  267. }
  268. i += n6
  269. dAtA[i] = 0x1a
  270. i++
  271. i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size()))
  272. n7, err := m.Status.MarshalTo(dAtA[i:])
  273. if err != nil {
  274. return 0, err
  275. }
  276. i += n7
  277. return i, nil
  278. }
  279. func (m *HorizontalPodAutoscalerCondition) Marshal() (dAtA []byte, err error) {
  280. size := m.Size()
  281. dAtA = make([]byte, size)
  282. n, err := m.MarshalTo(dAtA)
  283. if err != nil {
  284. return nil, err
  285. }
  286. return dAtA[:n], nil
  287. }
  288. func (m *HorizontalPodAutoscalerCondition) MarshalTo(dAtA []byte) (int, error) {
  289. var i int
  290. _ = i
  291. var l int
  292. _ = l
  293. dAtA[i] = 0xa
  294. i++
  295. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type)))
  296. i += copy(dAtA[i:], m.Type)
  297. dAtA[i] = 0x12
  298. i++
  299. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status)))
  300. i += copy(dAtA[i:], m.Status)
  301. dAtA[i] = 0x1a
  302. i++
  303. i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size()))
  304. n8, err := m.LastTransitionTime.MarshalTo(dAtA[i:])
  305. if err != nil {
  306. return 0, err
  307. }
  308. i += n8
  309. dAtA[i] = 0x22
  310. i++
  311. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason)))
  312. i += copy(dAtA[i:], m.Reason)
  313. dAtA[i] = 0x2a
  314. i++
  315. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message)))
  316. i += copy(dAtA[i:], m.Message)
  317. return i, nil
  318. }
  319. func (m *HorizontalPodAutoscalerList) Marshal() (dAtA []byte, err error) {
  320. size := m.Size()
  321. dAtA = make([]byte, size)
  322. n, err := m.MarshalTo(dAtA)
  323. if err != nil {
  324. return nil, err
  325. }
  326. return dAtA[:n], nil
  327. }
  328. func (m *HorizontalPodAutoscalerList) MarshalTo(dAtA []byte) (int, error) {
  329. var i int
  330. _ = i
  331. var l int
  332. _ = l
  333. dAtA[i] = 0xa
  334. i++
  335. i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size()))
  336. n9, err := m.ListMeta.MarshalTo(dAtA[i:])
  337. if err != nil {
  338. return 0, err
  339. }
  340. i += n9
  341. if len(m.Items) > 0 {
  342. for _, msg := range m.Items {
  343. dAtA[i] = 0x12
  344. i++
  345. i = encodeVarintGenerated(dAtA, i, uint64(msg.Size()))
  346. n, err := msg.MarshalTo(dAtA[i:])
  347. if err != nil {
  348. return 0, err
  349. }
  350. i += n
  351. }
  352. }
  353. return i, nil
  354. }
  355. func (m *HorizontalPodAutoscalerSpec) Marshal() (dAtA []byte, err error) {
  356. size := m.Size()
  357. dAtA = make([]byte, size)
  358. n, err := m.MarshalTo(dAtA)
  359. if err != nil {
  360. return nil, err
  361. }
  362. return dAtA[:n], nil
  363. }
  364. func (m *HorizontalPodAutoscalerSpec) MarshalTo(dAtA []byte) (int, error) {
  365. var i int
  366. _ = i
  367. var l int
  368. _ = l
  369. dAtA[i] = 0xa
  370. i++
  371. i = encodeVarintGenerated(dAtA, i, uint64(m.ScaleTargetRef.Size()))
  372. n10, err := m.ScaleTargetRef.MarshalTo(dAtA[i:])
  373. if err != nil {
  374. return 0, err
  375. }
  376. i += n10
  377. if m.MinReplicas != nil {
  378. dAtA[i] = 0x10
  379. i++
  380. i = encodeVarintGenerated(dAtA, i, uint64(*m.MinReplicas))
  381. }
  382. dAtA[i] = 0x18
  383. i++
  384. i = encodeVarintGenerated(dAtA, i, uint64(m.MaxReplicas))
  385. if len(m.Metrics) > 0 {
  386. for _, msg := range m.Metrics {
  387. dAtA[i] = 0x22
  388. i++
  389. i = encodeVarintGenerated(dAtA, i, uint64(msg.Size()))
  390. n, err := msg.MarshalTo(dAtA[i:])
  391. if err != nil {
  392. return 0, err
  393. }
  394. i += n
  395. }
  396. }
  397. return i, nil
  398. }
  399. func (m *HorizontalPodAutoscalerStatus) Marshal() (dAtA []byte, err error) {
  400. size := m.Size()
  401. dAtA = make([]byte, size)
  402. n, err := m.MarshalTo(dAtA)
  403. if err != nil {
  404. return nil, err
  405. }
  406. return dAtA[:n], nil
  407. }
  408. func (m *HorizontalPodAutoscalerStatus) MarshalTo(dAtA []byte) (int, error) {
  409. var i int
  410. _ = i
  411. var l int
  412. _ = l
  413. if m.ObservedGeneration != nil {
  414. dAtA[i] = 0x8
  415. i++
  416. i = encodeVarintGenerated(dAtA, i, uint64(*m.ObservedGeneration))
  417. }
  418. if m.LastScaleTime != nil {
  419. dAtA[i] = 0x12
  420. i++
  421. i = encodeVarintGenerated(dAtA, i, uint64(m.LastScaleTime.Size()))
  422. n11, err := m.LastScaleTime.MarshalTo(dAtA[i:])
  423. if err != nil {
  424. return 0, err
  425. }
  426. i += n11
  427. }
  428. dAtA[i] = 0x18
  429. i++
  430. i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentReplicas))
  431. dAtA[i] = 0x20
  432. i++
  433. i = encodeVarintGenerated(dAtA, i, uint64(m.DesiredReplicas))
  434. if len(m.CurrentMetrics) > 0 {
  435. for _, msg := range m.CurrentMetrics {
  436. dAtA[i] = 0x2a
  437. i++
  438. i = encodeVarintGenerated(dAtA, i, uint64(msg.Size()))
  439. n, err := msg.MarshalTo(dAtA[i:])
  440. if err != nil {
  441. return 0, err
  442. }
  443. i += n
  444. }
  445. }
  446. if len(m.Conditions) > 0 {
  447. for _, msg := range m.Conditions {
  448. dAtA[i] = 0x32
  449. i++
  450. i = encodeVarintGenerated(dAtA, i, uint64(msg.Size()))
  451. n, err := msg.MarshalTo(dAtA[i:])
  452. if err != nil {
  453. return 0, err
  454. }
  455. i += n
  456. }
  457. }
  458. return i, nil
  459. }
  460. func (m *MetricIdentifier) Marshal() (dAtA []byte, err error) {
  461. size := m.Size()
  462. dAtA = make([]byte, size)
  463. n, err := m.MarshalTo(dAtA)
  464. if err != nil {
  465. return nil, err
  466. }
  467. return dAtA[:n], nil
  468. }
  469. func (m *MetricIdentifier) MarshalTo(dAtA []byte) (int, error) {
  470. var i int
  471. _ = i
  472. var l int
  473. _ = l
  474. dAtA[i] = 0xa
  475. i++
  476. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name)))
  477. i += copy(dAtA[i:], m.Name)
  478. if m.Selector != nil {
  479. dAtA[i] = 0x12
  480. i++
  481. i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size()))
  482. n12, err := m.Selector.MarshalTo(dAtA[i:])
  483. if err != nil {
  484. return 0, err
  485. }
  486. i += n12
  487. }
  488. return i, nil
  489. }
  490. func (m *MetricSpec) Marshal() (dAtA []byte, err error) {
  491. size := m.Size()
  492. dAtA = make([]byte, size)
  493. n, err := m.MarshalTo(dAtA)
  494. if err != nil {
  495. return nil, err
  496. }
  497. return dAtA[:n], nil
  498. }
  499. func (m *MetricSpec) MarshalTo(dAtA []byte) (int, error) {
  500. var i int
  501. _ = i
  502. var l int
  503. _ = l
  504. dAtA[i] = 0xa
  505. i++
  506. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type)))
  507. i += copy(dAtA[i:], m.Type)
  508. if m.Object != nil {
  509. dAtA[i] = 0x12
  510. i++
  511. i = encodeVarintGenerated(dAtA, i, uint64(m.Object.Size()))
  512. n13, err := m.Object.MarshalTo(dAtA[i:])
  513. if err != nil {
  514. return 0, err
  515. }
  516. i += n13
  517. }
  518. if m.Pods != nil {
  519. dAtA[i] = 0x1a
  520. i++
  521. i = encodeVarintGenerated(dAtA, i, uint64(m.Pods.Size()))
  522. n14, err := m.Pods.MarshalTo(dAtA[i:])
  523. if err != nil {
  524. return 0, err
  525. }
  526. i += n14
  527. }
  528. if m.Resource != nil {
  529. dAtA[i] = 0x22
  530. i++
  531. i = encodeVarintGenerated(dAtA, i, uint64(m.Resource.Size()))
  532. n15, err := m.Resource.MarshalTo(dAtA[i:])
  533. if err != nil {
  534. return 0, err
  535. }
  536. i += n15
  537. }
  538. if m.External != nil {
  539. dAtA[i] = 0x2a
  540. i++
  541. i = encodeVarintGenerated(dAtA, i, uint64(m.External.Size()))
  542. n16, err := m.External.MarshalTo(dAtA[i:])
  543. if err != nil {
  544. return 0, err
  545. }
  546. i += n16
  547. }
  548. return i, nil
  549. }
  550. func (m *MetricStatus) Marshal() (dAtA []byte, err error) {
  551. size := m.Size()
  552. dAtA = make([]byte, size)
  553. n, err := m.MarshalTo(dAtA)
  554. if err != nil {
  555. return nil, err
  556. }
  557. return dAtA[:n], nil
  558. }
  559. func (m *MetricStatus) MarshalTo(dAtA []byte) (int, error) {
  560. var i int
  561. _ = i
  562. var l int
  563. _ = l
  564. dAtA[i] = 0xa
  565. i++
  566. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type)))
  567. i += copy(dAtA[i:], m.Type)
  568. if m.Object != nil {
  569. dAtA[i] = 0x12
  570. i++
  571. i = encodeVarintGenerated(dAtA, i, uint64(m.Object.Size()))
  572. n17, err := m.Object.MarshalTo(dAtA[i:])
  573. if err != nil {
  574. return 0, err
  575. }
  576. i += n17
  577. }
  578. if m.Pods != nil {
  579. dAtA[i] = 0x1a
  580. i++
  581. i = encodeVarintGenerated(dAtA, i, uint64(m.Pods.Size()))
  582. n18, err := m.Pods.MarshalTo(dAtA[i:])
  583. if err != nil {
  584. return 0, err
  585. }
  586. i += n18
  587. }
  588. if m.Resource != nil {
  589. dAtA[i] = 0x22
  590. i++
  591. i = encodeVarintGenerated(dAtA, i, uint64(m.Resource.Size()))
  592. n19, err := m.Resource.MarshalTo(dAtA[i:])
  593. if err != nil {
  594. return 0, err
  595. }
  596. i += n19
  597. }
  598. if m.External != nil {
  599. dAtA[i] = 0x2a
  600. i++
  601. i = encodeVarintGenerated(dAtA, i, uint64(m.External.Size()))
  602. n20, err := m.External.MarshalTo(dAtA[i:])
  603. if err != nil {
  604. return 0, err
  605. }
  606. i += n20
  607. }
  608. return i, nil
  609. }
  610. func (m *MetricTarget) Marshal() (dAtA []byte, err error) {
  611. size := m.Size()
  612. dAtA = make([]byte, size)
  613. n, err := m.MarshalTo(dAtA)
  614. if err != nil {
  615. return nil, err
  616. }
  617. return dAtA[:n], nil
  618. }
  619. func (m *MetricTarget) MarshalTo(dAtA []byte) (int, error) {
  620. var i int
  621. _ = i
  622. var l int
  623. _ = l
  624. dAtA[i] = 0xa
  625. i++
  626. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type)))
  627. i += copy(dAtA[i:], m.Type)
  628. if m.Value != nil {
  629. dAtA[i] = 0x12
  630. i++
  631. i = encodeVarintGenerated(dAtA, i, uint64(m.Value.Size()))
  632. n21, err := m.Value.MarshalTo(dAtA[i:])
  633. if err != nil {
  634. return 0, err
  635. }
  636. i += n21
  637. }
  638. if m.AverageValue != nil {
  639. dAtA[i] = 0x1a
  640. i++
  641. i = encodeVarintGenerated(dAtA, i, uint64(m.AverageValue.Size()))
  642. n22, err := m.AverageValue.MarshalTo(dAtA[i:])
  643. if err != nil {
  644. return 0, err
  645. }
  646. i += n22
  647. }
  648. if m.AverageUtilization != nil {
  649. dAtA[i] = 0x20
  650. i++
  651. i = encodeVarintGenerated(dAtA, i, uint64(*m.AverageUtilization))
  652. }
  653. return i, nil
  654. }
  655. func (m *MetricValueStatus) Marshal() (dAtA []byte, err error) {
  656. size := m.Size()
  657. dAtA = make([]byte, size)
  658. n, err := m.MarshalTo(dAtA)
  659. if err != nil {
  660. return nil, err
  661. }
  662. return dAtA[:n], nil
  663. }
  664. func (m *MetricValueStatus) MarshalTo(dAtA []byte) (int, error) {
  665. var i int
  666. _ = i
  667. var l int
  668. _ = l
  669. if m.Value != nil {
  670. dAtA[i] = 0xa
  671. i++
  672. i = encodeVarintGenerated(dAtA, i, uint64(m.Value.Size()))
  673. n23, err := m.Value.MarshalTo(dAtA[i:])
  674. if err != nil {
  675. return 0, err
  676. }
  677. i += n23
  678. }
  679. if m.AverageValue != nil {
  680. dAtA[i] = 0x12
  681. i++
  682. i = encodeVarintGenerated(dAtA, i, uint64(m.AverageValue.Size()))
  683. n24, err := m.AverageValue.MarshalTo(dAtA[i:])
  684. if err != nil {
  685. return 0, err
  686. }
  687. i += n24
  688. }
  689. if m.AverageUtilization != nil {
  690. dAtA[i] = 0x18
  691. i++
  692. i = encodeVarintGenerated(dAtA, i, uint64(*m.AverageUtilization))
  693. }
  694. return i, nil
  695. }
  696. func (m *ObjectMetricSource) Marshal() (dAtA []byte, err error) {
  697. size := m.Size()
  698. dAtA = make([]byte, size)
  699. n, err := m.MarshalTo(dAtA)
  700. if err != nil {
  701. return nil, err
  702. }
  703. return dAtA[:n], nil
  704. }
  705. func (m *ObjectMetricSource) MarshalTo(dAtA []byte) (int, error) {
  706. var i int
  707. _ = i
  708. var l int
  709. _ = l
  710. dAtA[i] = 0xa
  711. i++
  712. i = encodeVarintGenerated(dAtA, i, uint64(m.DescribedObject.Size()))
  713. n25, err := m.DescribedObject.MarshalTo(dAtA[i:])
  714. if err != nil {
  715. return 0, err
  716. }
  717. i += n25
  718. dAtA[i] = 0x12
  719. i++
  720. i = encodeVarintGenerated(dAtA, i, uint64(m.Target.Size()))
  721. n26, err := m.Target.MarshalTo(dAtA[i:])
  722. if err != nil {
  723. return 0, err
  724. }
  725. i += n26
  726. dAtA[i] = 0x1a
  727. i++
  728. i = encodeVarintGenerated(dAtA, i, uint64(m.Metric.Size()))
  729. n27, err := m.Metric.MarshalTo(dAtA[i:])
  730. if err != nil {
  731. return 0, err
  732. }
  733. i += n27
  734. return i, nil
  735. }
  736. func (m *ObjectMetricStatus) Marshal() (dAtA []byte, err error) {
  737. size := m.Size()
  738. dAtA = make([]byte, size)
  739. n, err := m.MarshalTo(dAtA)
  740. if err != nil {
  741. return nil, err
  742. }
  743. return dAtA[:n], nil
  744. }
  745. func (m *ObjectMetricStatus) MarshalTo(dAtA []byte) (int, error) {
  746. var i int
  747. _ = i
  748. var l int
  749. _ = l
  750. dAtA[i] = 0xa
  751. i++
  752. i = encodeVarintGenerated(dAtA, i, uint64(m.Metric.Size()))
  753. n28, err := m.Metric.MarshalTo(dAtA[i:])
  754. if err != nil {
  755. return 0, err
  756. }
  757. i += n28
  758. dAtA[i] = 0x12
  759. i++
  760. i = encodeVarintGenerated(dAtA, i, uint64(m.Current.Size()))
  761. n29, err := m.Current.MarshalTo(dAtA[i:])
  762. if err != nil {
  763. return 0, err
  764. }
  765. i += n29
  766. dAtA[i] = 0x1a
  767. i++
  768. i = encodeVarintGenerated(dAtA, i, uint64(m.DescribedObject.Size()))
  769. n30, err := m.DescribedObject.MarshalTo(dAtA[i:])
  770. if err != nil {
  771. return 0, err
  772. }
  773. i += n30
  774. return i, nil
  775. }
  776. func (m *PodsMetricSource) Marshal() (dAtA []byte, err error) {
  777. size := m.Size()
  778. dAtA = make([]byte, size)
  779. n, err := m.MarshalTo(dAtA)
  780. if err != nil {
  781. return nil, err
  782. }
  783. return dAtA[:n], nil
  784. }
  785. func (m *PodsMetricSource) MarshalTo(dAtA []byte) (int, error) {
  786. var i int
  787. _ = i
  788. var l int
  789. _ = l
  790. dAtA[i] = 0xa
  791. i++
  792. i = encodeVarintGenerated(dAtA, i, uint64(m.Metric.Size()))
  793. n31, err := m.Metric.MarshalTo(dAtA[i:])
  794. if err != nil {
  795. return 0, err
  796. }
  797. i += n31
  798. dAtA[i] = 0x12
  799. i++
  800. i = encodeVarintGenerated(dAtA, i, uint64(m.Target.Size()))
  801. n32, err := m.Target.MarshalTo(dAtA[i:])
  802. if err != nil {
  803. return 0, err
  804. }
  805. i += n32
  806. return i, nil
  807. }
  808. func (m *PodsMetricStatus) Marshal() (dAtA []byte, err error) {
  809. size := m.Size()
  810. dAtA = make([]byte, size)
  811. n, err := m.MarshalTo(dAtA)
  812. if err != nil {
  813. return nil, err
  814. }
  815. return dAtA[:n], nil
  816. }
  817. func (m *PodsMetricStatus) MarshalTo(dAtA []byte) (int, error) {
  818. var i int
  819. _ = i
  820. var l int
  821. _ = l
  822. dAtA[i] = 0xa
  823. i++
  824. i = encodeVarintGenerated(dAtA, i, uint64(m.Metric.Size()))
  825. n33, err := m.Metric.MarshalTo(dAtA[i:])
  826. if err != nil {
  827. return 0, err
  828. }
  829. i += n33
  830. dAtA[i] = 0x12
  831. i++
  832. i = encodeVarintGenerated(dAtA, i, uint64(m.Current.Size()))
  833. n34, err := m.Current.MarshalTo(dAtA[i:])
  834. if err != nil {
  835. return 0, err
  836. }
  837. i += n34
  838. return i, nil
  839. }
  840. func (m *ResourceMetricSource) Marshal() (dAtA []byte, err error) {
  841. size := m.Size()
  842. dAtA = make([]byte, size)
  843. n, err := m.MarshalTo(dAtA)
  844. if err != nil {
  845. return nil, err
  846. }
  847. return dAtA[:n], nil
  848. }
  849. func (m *ResourceMetricSource) MarshalTo(dAtA []byte) (int, error) {
  850. var i int
  851. _ = i
  852. var l int
  853. _ = l
  854. dAtA[i] = 0xa
  855. i++
  856. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name)))
  857. i += copy(dAtA[i:], m.Name)
  858. dAtA[i] = 0x12
  859. i++
  860. i = encodeVarintGenerated(dAtA, i, uint64(m.Target.Size()))
  861. n35, err := m.Target.MarshalTo(dAtA[i:])
  862. if err != nil {
  863. return 0, err
  864. }
  865. i += n35
  866. return i, nil
  867. }
  868. func (m *ResourceMetricStatus) Marshal() (dAtA []byte, err error) {
  869. size := m.Size()
  870. dAtA = make([]byte, size)
  871. n, err := m.MarshalTo(dAtA)
  872. if err != nil {
  873. return nil, err
  874. }
  875. return dAtA[:n], nil
  876. }
  877. func (m *ResourceMetricStatus) MarshalTo(dAtA []byte) (int, error) {
  878. var i int
  879. _ = i
  880. var l int
  881. _ = l
  882. dAtA[i] = 0xa
  883. i++
  884. i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name)))
  885. i += copy(dAtA[i:], m.Name)
  886. dAtA[i] = 0x12
  887. i++
  888. i = encodeVarintGenerated(dAtA, i, uint64(m.Current.Size()))
  889. n36, err := m.Current.MarshalTo(dAtA[i:])
  890. if err != nil {
  891. return 0, err
  892. }
  893. i += n36
  894. return i, nil
  895. }
  896. func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int {
  897. for v >= 1<<7 {
  898. dAtA[offset] = uint8(v&0x7f | 0x80)
  899. v >>= 7
  900. offset++
  901. }
  902. dAtA[offset] = uint8(v)
  903. return offset + 1
  904. }
  905. func (m *CrossVersionObjectReference) Size() (n int) {
  906. var l int
  907. _ = l
  908. l = len(m.Kind)
  909. n += 1 + l + sovGenerated(uint64(l))
  910. l = len(m.Name)
  911. n += 1 + l + sovGenerated(uint64(l))
  912. l = len(m.APIVersion)
  913. n += 1 + l + sovGenerated(uint64(l))
  914. return n
  915. }
  916. func (m *ExternalMetricSource) Size() (n int) {
  917. var l int
  918. _ = l
  919. l = m.Metric.Size()
  920. n += 1 + l + sovGenerated(uint64(l))
  921. l = m.Target.Size()
  922. n += 1 + l + sovGenerated(uint64(l))
  923. return n
  924. }
  925. func (m *ExternalMetricStatus) Size() (n int) {
  926. var l int
  927. _ = l
  928. l = m.Metric.Size()
  929. n += 1 + l + sovGenerated(uint64(l))
  930. l = m.Current.Size()
  931. n += 1 + l + sovGenerated(uint64(l))
  932. return n
  933. }
  934. func (m *HorizontalPodAutoscaler) Size() (n int) {
  935. var l int
  936. _ = l
  937. l = m.ObjectMeta.Size()
  938. n += 1 + l + sovGenerated(uint64(l))
  939. l = m.Spec.Size()
  940. n += 1 + l + sovGenerated(uint64(l))
  941. l = m.Status.Size()
  942. n += 1 + l + sovGenerated(uint64(l))
  943. return n
  944. }
  945. func (m *HorizontalPodAutoscalerCondition) Size() (n int) {
  946. var l int
  947. _ = l
  948. l = len(m.Type)
  949. n += 1 + l + sovGenerated(uint64(l))
  950. l = len(m.Status)
  951. n += 1 + l + sovGenerated(uint64(l))
  952. l = m.LastTransitionTime.Size()
  953. n += 1 + l + sovGenerated(uint64(l))
  954. l = len(m.Reason)
  955. n += 1 + l + sovGenerated(uint64(l))
  956. l = len(m.Message)
  957. n += 1 + l + sovGenerated(uint64(l))
  958. return n
  959. }
  960. func (m *HorizontalPodAutoscalerList) Size() (n int) {
  961. var l int
  962. _ = l
  963. l = m.ListMeta.Size()
  964. n += 1 + l + sovGenerated(uint64(l))
  965. if len(m.Items) > 0 {
  966. for _, e := range m.Items {
  967. l = e.Size()
  968. n += 1 + l + sovGenerated(uint64(l))
  969. }
  970. }
  971. return n
  972. }
  973. func (m *HorizontalPodAutoscalerSpec) Size() (n int) {
  974. var l int
  975. _ = l
  976. l = m.ScaleTargetRef.Size()
  977. n += 1 + l + sovGenerated(uint64(l))
  978. if m.MinReplicas != nil {
  979. n += 1 + sovGenerated(uint64(*m.MinReplicas))
  980. }
  981. n += 1 + sovGenerated(uint64(m.MaxReplicas))
  982. if len(m.Metrics) > 0 {
  983. for _, e := range m.Metrics {
  984. l = e.Size()
  985. n += 1 + l + sovGenerated(uint64(l))
  986. }
  987. }
  988. return n
  989. }
  990. func (m *HorizontalPodAutoscalerStatus) Size() (n int) {
  991. var l int
  992. _ = l
  993. if m.ObservedGeneration != nil {
  994. n += 1 + sovGenerated(uint64(*m.ObservedGeneration))
  995. }
  996. if m.LastScaleTime != nil {
  997. l = m.LastScaleTime.Size()
  998. n += 1 + l + sovGenerated(uint64(l))
  999. }
  1000. n += 1 + sovGenerated(uint64(m.CurrentReplicas))
  1001. n += 1 + sovGenerated(uint64(m.DesiredReplicas))
  1002. if len(m.CurrentMetrics) > 0 {
  1003. for _, e := range m.CurrentMetrics {
  1004. l = e.Size()
  1005. n += 1 + l + sovGenerated(uint64(l))
  1006. }
  1007. }
  1008. if len(m.Conditions) > 0 {
  1009. for _, e := range m.Conditions {
  1010. l = e.Size()
  1011. n += 1 + l + sovGenerated(uint64(l))
  1012. }
  1013. }
  1014. return n
  1015. }
  1016. func (m *MetricIdentifier) Size() (n int) {
  1017. var l int
  1018. _ = l
  1019. l = len(m.Name)
  1020. n += 1 + l + sovGenerated(uint64(l))
  1021. if m.Selector != nil {
  1022. l = m.Selector.Size()
  1023. n += 1 + l + sovGenerated(uint64(l))
  1024. }
  1025. return n
  1026. }
  1027. func (m *MetricSpec) Size() (n int) {
  1028. var l int
  1029. _ = l
  1030. l = len(m.Type)
  1031. n += 1 + l + sovGenerated(uint64(l))
  1032. if m.Object != nil {
  1033. l = m.Object.Size()
  1034. n += 1 + l + sovGenerated(uint64(l))
  1035. }
  1036. if m.Pods != nil {
  1037. l = m.Pods.Size()
  1038. n += 1 + l + sovGenerated(uint64(l))
  1039. }
  1040. if m.Resource != nil {
  1041. l = m.Resource.Size()
  1042. n += 1 + l + sovGenerated(uint64(l))
  1043. }
  1044. if m.External != nil {
  1045. l = m.External.Size()
  1046. n += 1 + l + sovGenerated(uint64(l))
  1047. }
  1048. return n
  1049. }
  1050. func (m *MetricStatus) Size() (n int) {
  1051. var l int
  1052. _ = l
  1053. l = len(m.Type)
  1054. n += 1 + l + sovGenerated(uint64(l))
  1055. if m.Object != nil {
  1056. l = m.Object.Size()
  1057. n += 1 + l + sovGenerated(uint64(l))
  1058. }
  1059. if m.Pods != nil {
  1060. l = m.Pods.Size()
  1061. n += 1 + l + sovGenerated(uint64(l))
  1062. }
  1063. if m.Resource != nil {
  1064. l = m.Resource.Size()
  1065. n += 1 + l + sovGenerated(uint64(l))
  1066. }
  1067. if m.External != nil {
  1068. l = m.External.Size()
  1069. n += 1 + l + sovGenerated(uint64(l))
  1070. }
  1071. return n
  1072. }
  1073. func (m *MetricTarget) Size() (n int) {
  1074. var l int
  1075. _ = l
  1076. l = len(m.Type)
  1077. n += 1 + l + sovGenerated(uint64(l))
  1078. if m.Value != nil {
  1079. l = m.Value.Size()
  1080. n += 1 + l + sovGenerated(uint64(l))
  1081. }
  1082. if m.AverageValue != nil {
  1083. l = m.AverageValue.Size()
  1084. n += 1 + l + sovGenerated(uint64(l))
  1085. }
  1086. if m.AverageUtilization != nil {
  1087. n += 1 + sovGenerated(uint64(*m.AverageUtilization))
  1088. }
  1089. return n
  1090. }
  1091. func (m *MetricValueStatus) Size() (n int) {
  1092. var l int
  1093. _ = l
  1094. if m.Value != nil {
  1095. l = m.Value.Size()
  1096. n += 1 + l + sovGenerated(uint64(l))
  1097. }
  1098. if m.AverageValue != nil {
  1099. l = m.AverageValue.Size()
  1100. n += 1 + l + sovGenerated(uint64(l))
  1101. }
  1102. if m.AverageUtilization != nil {
  1103. n += 1 + sovGenerated(uint64(*m.AverageUtilization))
  1104. }
  1105. return n
  1106. }
  1107. func (m *ObjectMetricSource) Size() (n int) {
  1108. var l int
  1109. _ = l
  1110. l = m.DescribedObject.Size()
  1111. n += 1 + l + sovGenerated(uint64(l))
  1112. l = m.Target.Size()
  1113. n += 1 + l + sovGenerated(uint64(l))
  1114. l = m.Metric.Size()
  1115. n += 1 + l + sovGenerated(uint64(l))
  1116. return n
  1117. }
  1118. func (m *ObjectMetricStatus) Size() (n int) {
  1119. var l int
  1120. _ = l
  1121. l = m.Metric.Size()
  1122. n += 1 + l + sovGenerated(uint64(l))
  1123. l = m.Current.Size()
  1124. n += 1 + l + sovGenerated(uint64(l))
  1125. l = m.DescribedObject.Size()
  1126. n += 1 + l + sovGenerated(uint64(l))
  1127. return n
  1128. }
  1129. func (m *PodsMetricSource) Size() (n int) {
  1130. var l int
  1131. _ = l
  1132. l = m.Metric.Size()
  1133. n += 1 + l + sovGenerated(uint64(l))
  1134. l = m.Target.Size()
  1135. n += 1 + l + sovGenerated(uint64(l))
  1136. return n
  1137. }
  1138. func (m *PodsMetricStatus) Size() (n int) {
  1139. var l int
  1140. _ = l
  1141. l = m.Metric.Size()
  1142. n += 1 + l + sovGenerated(uint64(l))
  1143. l = m.Current.Size()
  1144. n += 1 + l + sovGenerated(uint64(l))
  1145. return n
  1146. }
  1147. func (m *ResourceMetricSource) Size() (n int) {
  1148. var l int
  1149. _ = l
  1150. l = len(m.Name)
  1151. n += 1 + l + sovGenerated(uint64(l))
  1152. l = m.Target.Size()
  1153. n += 1 + l + sovGenerated(uint64(l))
  1154. return n
  1155. }
  1156. func (m *ResourceMetricStatus) Size() (n int) {
  1157. var l int
  1158. _ = l
  1159. l = len(m.Name)
  1160. n += 1 + l + sovGenerated(uint64(l))
  1161. l = m.Current.Size()
  1162. n += 1 + l + sovGenerated(uint64(l))
  1163. return n
  1164. }
  1165. func sovGenerated(x uint64) (n int) {
  1166. for {
  1167. n++
  1168. x >>= 7
  1169. if x == 0 {
  1170. break
  1171. }
  1172. }
  1173. return n
  1174. }
  1175. func sozGenerated(x uint64) (n int) {
  1176. return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63))))
  1177. }
  1178. func (this *CrossVersionObjectReference) String() string {
  1179. if this == nil {
  1180. return "nil"
  1181. }
  1182. s := strings.Join([]string{`&CrossVersionObjectReference{`,
  1183. `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`,
  1184. `Name:` + fmt.Sprintf("%v", this.Name) + `,`,
  1185. `APIVersion:` + fmt.Sprintf("%v", this.APIVersion) + `,`,
  1186. `}`,
  1187. }, "")
  1188. return s
  1189. }
  1190. func (this *ExternalMetricSource) String() string {
  1191. if this == nil {
  1192. return "nil"
  1193. }
  1194. s := strings.Join([]string{`&ExternalMetricSource{`,
  1195. `Metric:` + strings.Replace(strings.Replace(this.Metric.String(), "MetricIdentifier", "MetricIdentifier", 1), `&`, ``, 1) + `,`,
  1196. `Target:` + strings.Replace(strings.Replace(this.Target.String(), "MetricTarget", "MetricTarget", 1), `&`, ``, 1) + `,`,
  1197. `}`,
  1198. }, "")
  1199. return s
  1200. }
  1201. func (this *ExternalMetricStatus) String() string {
  1202. if this == nil {
  1203. return "nil"
  1204. }
  1205. s := strings.Join([]string{`&ExternalMetricStatus{`,
  1206. `Metric:` + strings.Replace(strings.Replace(this.Metric.String(), "MetricIdentifier", "MetricIdentifier", 1), `&`, ``, 1) + `,`,
  1207. `Current:` + strings.Replace(strings.Replace(this.Current.String(), "MetricValueStatus", "MetricValueStatus", 1), `&`, ``, 1) + `,`,
  1208. `}`,
  1209. }, "")
  1210. return s
  1211. }
  1212. func (this *HorizontalPodAutoscaler) String() string {
  1213. if this == nil {
  1214. return "nil"
  1215. }
  1216. s := strings.Join([]string{`&HorizontalPodAutoscaler{`,
  1217. `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`,
  1218. `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "HorizontalPodAutoscalerSpec", "HorizontalPodAutoscalerSpec", 1), `&`, ``, 1) + `,`,
  1219. `Status:` + strings.Replace(strings.Replace(this.Status.String(), "HorizontalPodAutoscalerStatus", "HorizontalPodAutoscalerStatus", 1), `&`, ``, 1) + `,`,
  1220. `}`,
  1221. }, "")
  1222. return s
  1223. }
  1224. func (this *HorizontalPodAutoscalerCondition) String() string {
  1225. if this == nil {
  1226. return "nil"
  1227. }
  1228. s := strings.Join([]string{`&HorizontalPodAutoscalerCondition{`,
  1229. `Type:` + fmt.Sprintf("%v", this.Type) + `,`,
  1230. `Status:` + fmt.Sprintf("%v", this.Status) + `,`,
  1231. `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`,
  1232. `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`,
  1233. `Message:` + fmt.Sprintf("%v", this.Message) + `,`,
  1234. `}`,
  1235. }, "")
  1236. return s
  1237. }
  1238. func (this *HorizontalPodAutoscalerList) String() string {
  1239. if this == nil {
  1240. return "nil"
  1241. }
  1242. s := strings.Join([]string{`&HorizontalPodAutoscalerList{`,
  1243. `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`,
  1244. `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "HorizontalPodAutoscaler", "HorizontalPodAutoscaler", 1), `&`, ``, 1) + `,`,
  1245. `}`,
  1246. }, "")
  1247. return s
  1248. }
  1249. func (this *HorizontalPodAutoscalerSpec) String() string {
  1250. if this == nil {
  1251. return "nil"
  1252. }
  1253. s := strings.Join([]string{`&HorizontalPodAutoscalerSpec{`,
  1254. `ScaleTargetRef:` + strings.Replace(strings.Replace(this.ScaleTargetRef.String(), "CrossVersionObjectReference", "CrossVersionObjectReference", 1), `&`, ``, 1) + `,`,
  1255. `MinReplicas:` + valueToStringGenerated(this.MinReplicas) + `,`,
  1256. `MaxReplicas:` + fmt.Sprintf("%v", this.MaxReplicas) + `,`,
  1257. `Metrics:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Metrics), "MetricSpec", "MetricSpec", 1), `&`, ``, 1) + `,`,
  1258. `}`,
  1259. }, "")
  1260. return s
  1261. }
  1262. func (this *HorizontalPodAutoscalerStatus) String() string {
  1263. if this == nil {
  1264. return "nil"
  1265. }
  1266. s := strings.Join([]string{`&HorizontalPodAutoscalerStatus{`,
  1267. `ObservedGeneration:` + valueToStringGenerated(this.ObservedGeneration) + `,`,
  1268. `LastScaleTime:` + strings.Replace(fmt.Sprintf("%v", this.LastScaleTime), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1) + `,`,
  1269. `CurrentReplicas:` + fmt.Sprintf("%v", this.CurrentReplicas) + `,`,
  1270. `DesiredReplicas:` + fmt.Sprintf("%v", this.DesiredReplicas) + `,`,
  1271. `CurrentMetrics:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.CurrentMetrics), "MetricStatus", "MetricStatus", 1), `&`, ``, 1) + `,`,
  1272. `Conditions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Conditions), "HorizontalPodAutoscalerCondition", "HorizontalPodAutoscalerCondition", 1), `&`, ``, 1) + `,`,
  1273. `}`,
  1274. }, "")
  1275. return s
  1276. }
  1277. func (this *MetricIdentifier) String() string {
  1278. if this == nil {
  1279. return "nil"
  1280. }
  1281. s := strings.Join([]string{`&MetricIdentifier{`,
  1282. `Name:` + fmt.Sprintf("%v", this.Name) + `,`,
  1283. `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`,
  1284. `}`,
  1285. }, "")
  1286. return s
  1287. }
  1288. func (this *MetricSpec) String() string {
  1289. if this == nil {
  1290. return "nil"
  1291. }
  1292. s := strings.Join([]string{`&MetricSpec{`,
  1293. `Type:` + fmt.Sprintf("%v", this.Type) + `,`,
  1294. `Object:` + strings.Replace(fmt.Sprintf("%v", this.Object), "ObjectMetricSource", "ObjectMetricSource", 1) + `,`,
  1295. `Pods:` + strings.Replace(fmt.Sprintf("%v", this.Pods), "PodsMetricSource", "PodsMetricSource", 1) + `,`,
  1296. `Resource:` + strings.Replace(fmt.Sprintf("%v", this.Resource), "ResourceMetricSource", "ResourceMetricSource", 1) + `,`,
  1297. `External:` + strings.Replace(fmt.Sprintf("%v", this.External), "ExternalMetricSource", "ExternalMetricSource", 1) + `,`,
  1298. `}`,
  1299. }, "")
  1300. return s
  1301. }
  1302. func (this *MetricStatus) String() string {
  1303. if this == nil {
  1304. return "nil"
  1305. }
  1306. s := strings.Join([]string{`&MetricStatus{`,
  1307. `Type:` + fmt.Sprintf("%v", this.Type) + `,`,
  1308. `Object:` + strings.Replace(fmt.Sprintf("%v", this.Object), "ObjectMetricStatus", "ObjectMetricStatus", 1) + `,`,
  1309. `Pods:` + strings.Replace(fmt.Sprintf("%v", this.Pods), "PodsMetricStatus", "PodsMetricStatus", 1) + `,`,
  1310. `Resource:` + strings.Replace(fmt.Sprintf("%v", this.Resource), "ResourceMetricStatus", "ResourceMetricStatus", 1) + `,`,
  1311. `External:` + strings.Replace(fmt.Sprintf("%v", this.External), "ExternalMetricStatus", "ExternalMetricStatus", 1) + `,`,
  1312. `}`,
  1313. }, "")
  1314. return s
  1315. }
  1316. func (this *MetricTarget) String() string {
  1317. if this == nil {
  1318. return "nil"
  1319. }
  1320. s := strings.Join([]string{`&MetricTarget{`,
  1321. `Type:` + fmt.Sprintf("%v", this.Type) + `,`,
  1322. `Value:` + strings.Replace(fmt.Sprintf("%v", this.Value), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1) + `,`,
  1323. `AverageValue:` + strings.Replace(fmt.Sprintf("%v", this.AverageValue), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1) + `,`,
  1324. `AverageUtilization:` + valueToStringGenerated(this.AverageUtilization) + `,`,
  1325. `}`,
  1326. }, "")
  1327. return s
  1328. }
  1329. func (this *MetricValueStatus) String() string {
  1330. if this == nil {
  1331. return "nil"
  1332. }
  1333. s := strings.Join([]string{`&MetricValueStatus{`,
  1334. `Value:` + strings.Replace(fmt.Sprintf("%v", this.Value), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1) + `,`,
  1335. `AverageValue:` + strings.Replace(fmt.Sprintf("%v", this.AverageValue), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1) + `,`,
  1336. `AverageUtilization:` + valueToStringGenerated(this.AverageUtilization) + `,`,
  1337. `}`,
  1338. }, "")
  1339. return s
  1340. }
  1341. func (this *ObjectMetricSource) String() string {
  1342. if this == nil {
  1343. return "nil"
  1344. }
  1345. s := strings.Join([]string{`&ObjectMetricSource{`,
  1346. `DescribedObject:` + strings.Replace(strings.Replace(this.DescribedObject.String(), "CrossVersionObjectReference", "CrossVersionObjectReference", 1), `&`, ``, 1) + `,`,
  1347. `Target:` + strings.Replace(strings.Replace(this.Target.String(), "MetricTarget", "MetricTarget", 1), `&`, ``, 1) + `,`,
  1348. `Metric:` + strings.Replace(strings.Replace(this.Metric.String(), "MetricIdentifier", "MetricIdentifier", 1), `&`, ``, 1) + `,`,
  1349. `}`,
  1350. }, "")
  1351. return s
  1352. }
  1353. func (this *ObjectMetricStatus) String() string {
  1354. if this == nil {
  1355. return "nil"
  1356. }
  1357. s := strings.Join([]string{`&ObjectMetricStatus{`,
  1358. `Metric:` + strings.Replace(strings.Replace(this.Metric.String(), "MetricIdentifier", "MetricIdentifier", 1), `&`, ``, 1) + `,`,
  1359. `Current:` + strings.Replace(strings.Replace(this.Current.String(), "MetricValueStatus", "MetricValueStatus", 1), `&`, ``, 1) + `,`,
  1360. `DescribedObject:` + strings.Replace(strings.Replace(this.DescribedObject.String(), "CrossVersionObjectReference", "CrossVersionObjectReference", 1), `&`, ``, 1) + `,`,
  1361. `}`,
  1362. }, "")
  1363. return s
  1364. }
  1365. func (this *PodsMetricSource) String() string {
  1366. if this == nil {
  1367. return "nil"
  1368. }
  1369. s := strings.Join([]string{`&PodsMetricSource{`,
  1370. `Metric:` + strings.Replace(strings.Replace(this.Metric.String(), "MetricIdentifier", "MetricIdentifier", 1), `&`, ``, 1) + `,`,
  1371. `Target:` + strings.Replace(strings.Replace(this.Target.String(), "MetricTarget", "MetricTarget", 1), `&`, ``, 1) + `,`,
  1372. `}`,
  1373. }, "")
  1374. return s
  1375. }
  1376. func (this *PodsMetricStatus) String() string {
  1377. if this == nil {
  1378. return "nil"
  1379. }
  1380. s := strings.Join([]string{`&PodsMetricStatus{`,
  1381. `Metric:` + strings.Replace(strings.Replace(this.Metric.String(), "MetricIdentifier", "MetricIdentifier", 1), `&`, ``, 1) + `,`,
  1382. `Current:` + strings.Replace(strings.Replace(this.Current.String(), "MetricValueStatus", "MetricValueStatus", 1), `&`, ``, 1) + `,`,
  1383. `}`,
  1384. }, "")
  1385. return s
  1386. }
  1387. func (this *ResourceMetricSource) String() string {
  1388. if this == nil {
  1389. return "nil"
  1390. }
  1391. s := strings.Join([]string{`&ResourceMetricSource{`,
  1392. `Name:` + fmt.Sprintf("%v", this.Name) + `,`,
  1393. `Target:` + strings.Replace(strings.Replace(this.Target.String(), "MetricTarget", "MetricTarget", 1), `&`, ``, 1) + `,`,
  1394. `}`,
  1395. }, "")
  1396. return s
  1397. }
  1398. func (this *ResourceMetricStatus) String() string {
  1399. if this == nil {
  1400. return "nil"
  1401. }
  1402. s := strings.Join([]string{`&ResourceMetricStatus{`,
  1403. `Name:` + fmt.Sprintf("%v", this.Name) + `,`,
  1404. `Current:` + strings.Replace(strings.Replace(this.Current.String(), "MetricValueStatus", "MetricValueStatus", 1), `&`, ``, 1) + `,`,
  1405. `}`,
  1406. }, "")
  1407. return s
  1408. }
  1409. func valueToStringGenerated(v interface{}) string {
  1410. rv := reflect.ValueOf(v)
  1411. if rv.IsNil() {
  1412. return "nil"
  1413. }
  1414. pv := reflect.Indirect(rv).Interface()
  1415. return fmt.Sprintf("*%v", pv)
  1416. }
  1417. func (m *CrossVersionObjectReference) Unmarshal(dAtA []byte) error {
  1418. l := len(dAtA)
  1419. iNdEx := 0
  1420. for iNdEx < l {
  1421. preIndex := iNdEx
  1422. var wire uint64
  1423. for shift := uint(0); ; shift += 7 {
  1424. if shift >= 64 {
  1425. return ErrIntOverflowGenerated
  1426. }
  1427. if iNdEx >= l {
  1428. return io.ErrUnexpectedEOF
  1429. }
  1430. b := dAtA[iNdEx]
  1431. iNdEx++
  1432. wire |= (uint64(b) & 0x7F) << shift
  1433. if b < 0x80 {
  1434. break
  1435. }
  1436. }
  1437. fieldNum := int32(wire >> 3)
  1438. wireType := int(wire & 0x7)
  1439. if wireType == 4 {
  1440. return fmt.Errorf("proto: CrossVersionObjectReference: wiretype end group for non-group")
  1441. }
  1442. if fieldNum <= 0 {
  1443. return fmt.Errorf("proto: CrossVersionObjectReference: illegal tag %d (wire type %d)", fieldNum, wire)
  1444. }
  1445. switch fieldNum {
  1446. case 1:
  1447. if wireType != 2 {
  1448. return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType)
  1449. }
  1450. var stringLen uint64
  1451. for shift := uint(0); ; shift += 7 {
  1452. if shift >= 64 {
  1453. return ErrIntOverflowGenerated
  1454. }
  1455. if iNdEx >= l {
  1456. return io.ErrUnexpectedEOF
  1457. }
  1458. b := dAtA[iNdEx]
  1459. iNdEx++
  1460. stringLen |= (uint64(b) & 0x7F) << shift
  1461. if b < 0x80 {
  1462. break
  1463. }
  1464. }
  1465. intStringLen := int(stringLen)
  1466. if intStringLen < 0 {
  1467. return ErrInvalidLengthGenerated
  1468. }
  1469. postIndex := iNdEx + intStringLen
  1470. if postIndex > l {
  1471. return io.ErrUnexpectedEOF
  1472. }
  1473. m.Kind = string(dAtA[iNdEx:postIndex])
  1474. iNdEx = postIndex
  1475. case 2:
  1476. if wireType != 2 {
  1477. return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
  1478. }
  1479. var stringLen uint64
  1480. for shift := uint(0); ; shift += 7 {
  1481. if shift >= 64 {
  1482. return ErrIntOverflowGenerated
  1483. }
  1484. if iNdEx >= l {
  1485. return io.ErrUnexpectedEOF
  1486. }
  1487. b := dAtA[iNdEx]
  1488. iNdEx++
  1489. stringLen |= (uint64(b) & 0x7F) << shift
  1490. if b < 0x80 {
  1491. break
  1492. }
  1493. }
  1494. intStringLen := int(stringLen)
  1495. if intStringLen < 0 {
  1496. return ErrInvalidLengthGenerated
  1497. }
  1498. postIndex := iNdEx + intStringLen
  1499. if postIndex > l {
  1500. return io.ErrUnexpectedEOF
  1501. }
  1502. m.Name = string(dAtA[iNdEx:postIndex])
  1503. iNdEx = postIndex
  1504. case 3:
  1505. if wireType != 2 {
  1506. return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType)
  1507. }
  1508. var stringLen uint64
  1509. for shift := uint(0); ; shift += 7 {
  1510. if shift >= 64 {
  1511. return ErrIntOverflowGenerated
  1512. }
  1513. if iNdEx >= l {
  1514. return io.ErrUnexpectedEOF
  1515. }
  1516. b := dAtA[iNdEx]
  1517. iNdEx++
  1518. stringLen |= (uint64(b) & 0x7F) << shift
  1519. if b < 0x80 {
  1520. break
  1521. }
  1522. }
  1523. intStringLen := int(stringLen)
  1524. if intStringLen < 0 {
  1525. return ErrInvalidLengthGenerated
  1526. }
  1527. postIndex := iNdEx + intStringLen
  1528. if postIndex > l {
  1529. return io.ErrUnexpectedEOF
  1530. }
  1531. m.APIVersion = string(dAtA[iNdEx:postIndex])
  1532. iNdEx = postIndex
  1533. default:
  1534. iNdEx = preIndex
  1535. skippy, err := skipGenerated(dAtA[iNdEx:])
  1536. if err != nil {
  1537. return err
  1538. }
  1539. if skippy < 0 {
  1540. return ErrInvalidLengthGenerated
  1541. }
  1542. if (iNdEx + skippy) > l {
  1543. return io.ErrUnexpectedEOF
  1544. }
  1545. iNdEx += skippy
  1546. }
  1547. }
  1548. if iNdEx > l {
  1549. return io.ErrUnexpectedEOF
  1550. }
  1551. return nil
  1552. }
  1553. func (m *ExternalMetricSource) Unmarshal(dAtA []byte) error {
  1554. l := len(dAtA)
  1555. iNdEx := 0
  1556. for iNdEx < l {
  1557. preIndex := iNdEx
  1558. var wire uint64
  1559. for shift := uint(0); ; shift += 7 {
  1560. if shift >= 64 {
  1561. return ErrIntOverflowGenerated
  1562. }
  1563. if iNdEx >= l {
  1564. return io.ErrUnexpectedEOF
  1565. }
  1566. b := dAtA[iNdEx]
  1567. iNdEx++
  1568. wire |= (uint64(b) & 0x7F) << shift
  1569. if b < 0x80 {
  1570. break
  1571. }
  1572. }
  1573. fieldNum := int32(wire >> 3)
  1574. wireType := int(wire & 0x7)
  1575. if wireType == 4 {
  1576. return fmt.Errorf("proto: ExternalMetricSource: wiretype end group for non-group")
  1577. }
  1578. if fieldNum <= 0 {
  1579. return fmt.Errorf("proto: ExternalMetricSource: illegal tag %d (wire type %d)", fieldNum, wire)
  1580. }
  1581. switch fieldNum {
  1582. case 1:
  1583. if wireType != 2 {
  1584. return fmt.Errorf("proto: wrong wireType = %d for field Metric", wireType)
  1585. }
  1586. var msglen int
  1587. for shift := uint(0); ; shift += 7 {
  1588. if shift >= 64 {
  1589. return ErrIntOverflowGenerated
  1590. }
  1591. if iNdEx >= l {
  1592. return io.ErrUnexpectedEOF
  1593. }
  1594. b := dAtA[iNdEx]
  1595. iNdEx++
  1596. msglen |= (int(b) & 0x7F) << shift
  1597. if b < 0x80 {
  1598. break
  1599. }
  1600. }
  1601. if msglen < 0 {
  1602. return ErrInvalidLengthGenerated
  1603. }
  1604. postIndex := iNdEx + msglen
  1605. if postIndex > l {
  1606. return io.ErrUnexpectedEOF
  1607. }
  1608. if err := m.Metric.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1609. return err
  1610. }
  1611. iNdEx = postIndex
  1612. case 2:
  1613. if wireType != 2 {
  1614. return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType)
  1615. }
  1616. var msglen int
  1617. for shift := uint(0); ; shift += 7 {
  1618. if shift >= 64 {
  1619. return ErrIntOverflowGenerated
  1620. }
  1621. if iNdEx >= l {
  1622. return io.ErrUnexpectedEOF
  1623. }
  1624. b := dAtA[iNdEx]
  1625. iNdEx++
  1626. msglen |= (int(b) & 0x7F) << shift
  1627. if b < 0x80 {
  1628. break
  1629. }
  1630. }
  1631. if msglen < 0 {
  1632. return ErrInvalidLengthGenerated
  1633. }
  1634. postIndex := iNdEx + msglen
  1635. if postIndex > l {
  1636. return io.ErrUnexpectedEOF
  1637. }
  1638. if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1639. return err
  1640. }
  1641. iNdEx = postIndex
  1642. default:
  1643. iNdEx = preIndex
  1644. skippy, err := skipGenerated(dAtA[iNdEx:])
  1645. if err != nil {
  1646. return err
  1647. }
  1648. if skippy < 0 {
  1649. return ErrInvalidLengthGenerated
  1650. }
  1651. if (iNdEx + skippy) > l {
  1652. return io.ErrUnexpectedEOF
  1653. }
  1654. iNdEx += skippy
  1655. }
  1656. }
  1657. if iNdEx > l {
  1658. return io.ErrUnexpectedEOF
  1659. }
  1660. return nil
  1661. }
  1662. func (m *ExternalMetricStatus) Unmarshal(dAtA []byte) error {
  1663. l := len(dAtA)
  1664. iNdEx := 0
  1665. for iNdEx < l {
  1666. preIndex := iNdEx
  1667. var wire uint64
  1668. for shift := uint(0); ; shift += 7 {
  1669. if shift >= 64 {
  1670. return ErrIntOverflowGenerated
  1671. }
  1672. if iNdEx >= l {
  1673. return io.ErrUnexpectedEOF
  1674. }
  1675. b := dAtA[iNdEx]
  1676. iNdEx++
  1677. wire |= (uint64(b) & 0x7F) << shift
  1678. if b < 0x80 {
  1679. break
  1680. }
  1681. }
  1682. fieldNum := int32(wire >> 3)
  1683. wireType := int(wire & 0x7)
  1684. if wireType == 4 {
  1685. return fmt.Errorf("proto: ExternalMetricStatus: wiretype end group for non-group")
  1686. }
  1687. if fieldNum <= 0 {
  1688. return fmt.Errorf("proto: ExternalMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire)
  1689. }
  1690. switch fieldNum {
  1691. case 1:
  1692. if wireType != 2 {
  1693. return fmt.Errorf("proto: wrong wireType = %d for field Metric", wireType)
  1694. }
  1695. var msglen int
  1696. for shift := uint(0); ; shift += 7 {
  1697. if shift >= 64 {
  1698. return ErrIntOverflowGenerated
  1699. }
  1700. if iNdEx >= l {
  1701. return io.ErrUnexpectedEOF
  1702. }
  1703. b := dAtA[iNdEx]
  1704. iNdEx++
  1705. msglen |= (int(b) & 0x7F) << shift
  1706. if b < 0x80 {
  1707. break
  1708. }
  1709. }
  1710. if msglen < 0 {
  1711. return ErrInvalidLengthGenerated
  1712. }
  1713. postIndex := iNdEx + msglen
  1714. if postIndex > l {
  1715. return io.ErrUnexpectedEOF
  1716. }
  1717. if err := m.Metric.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1718. return err
  1719. }
  1720. iNdEx = postIndex
  1721. case 2:
  1722. if wireType != 2 {
  1723. return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
  1724. }
  1725. var msglen int
  1726. for shift := uint(0); ; shift += 7 {
  1727. if shift >= 64 {
  1728. return ErrIntOverflowGenerated
  1729. }
  1730. if iNdEx >= l {
  1731. return io.ErrUnexpectedEOF
  1732. }
  1733. b := dAtA[iNdEx]
  1734. iNdEx++
  1735. msglen |= (int(b) & 0x7F) << shift
  1736. if b < 0x80 {
  1737. break
  1738. }
  1739. }
  1740. if msglen < 0 {
  1741. return ErrInvalidLengthGenerated
  1742. }
  1743. postIndex := iNdEx + msglen
  1744. if postIndex > l {
  1745. return io.ErrUnexpectedEOF
  1746. }
  1747. if err := m.Current.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1748. return err
  1749. }
  1750. iNdEx = postIndex
  1751. default:
  1752. iNdEx = preIndex
  1753. skippy, err := skipGenerated(dAtA[iNdEx:])
  1754. if err != nil {
  1755. return err
  1756. }
  1757. if skippy < 0 {
  1758. return ErrInvalidLengthGenerated
  1759. }
  1760. if (iNdEx + skippy) > l {
  1761. return io.ErrUnexpectedEOF
  1762. }
  1763. iNdEx += skippy
  1764. }
  1765. }
  1766. if iNdEx > l {
  1767. return io.ErrUnexpectedEOF
  1768. }
  1769. return nil
  1770. }
  1771. func (m *HorizontalPodAutoscaler) Unmarshal(dAtA []byte) error {
  1772. l := len(dAtA)
  1773. iNdEx := 0
  1774. for iNdEx < l {
  1775. preIndex := iNdEx
  1776. var wire uint64
  1777. for shift := uint(0); ; shift += 7 {
  1778. if shift >= 64 {
  1779. return ErrIntOverflowGenerated
  1780. }
  1781. if iNdEx >= l {
  1782. return io.ErrUnexpectedEOF
  1783. }
  1784. b := dAtA[iNdEx]
  1785. iNdEx++
  1786. wire |= (uint64(b) & 0x7F) << shift
  1787. if b < 0x80 {
  1788. break
  1789. }
  1790. }
  1791. fieldNum := int32(wire >> 3)
  1792. wireType := int(wire & 0x7)
  1793. if wireType == 4 {
  1794. return fmt.Errorf("proto: HorizontalPodAutoscaler: wiretype end group for non-group")
  1795. }
  1796. if fieldNum <= 0 {
  1797. return fmt.Errorf("proto: HorizontalPodAutoscaler: illegal tag %d (wire type %d)", fieldNum, wire)
  1798. }
  1799. switch fieldNum {
  1800. case 1:
  1801. if wireType != 2 {
  1802. return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
  1803. }
  1804. var msglen int
  1805. for shift := uint(0); ; shift += 7 {
  1806. if shift >= 64 {
  1807. return ErrIntOverflowGenerated
  1808. }
  1809. if iNdEx >= l {
  1810. return io.ErrUnexpectedEOF
  1811. }
  1812. b := dAtA[iNdEx]
  1813. iNdEx++
  1814. msglen |= (int(b) & 0x7F) << shift
  1815. if b < 0x80 {
  1816. break
  1817. }
  1818. }
  1819. if msglen < 0 {
  1820. return ErrInvalidLengthGenerated
  1821. }
  1822. postIndex := iNdEx + msglen
  1823. if postIndex > l {
  1824. return io.ErrUnexpectedEOF
  1825. }
  1826. if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1827. return err
  1828. }
  1829. iNdEx = postIndex
  1830. case 2:
  1831. if wireType != 2 {
  1832. return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
  1833. }
  1834. var msglen int
  1835. for shift := uint(0); ; shift += 7 {
  1836. if shift >= 64 {
  1837. return ErrIntOverflowGenerated
  1838. }
  1839. if iNdEx >= l {
  1840. return io.ErrUnexpectedEOF
  1841. }
  1842. b := dAtA[iNdEx]
  1843. iNdEx++
  1844. msglen |= (int(b) & 0x7F) << shift
  1845. if b < 0x80 {
  1846. break
  1847. }
  1848. }
  1849. if msglen < 0 {
  1850. return ErrInvalidLengthGenerated
  1851. }
  1852. postIndex := iNdEx + msglen
  1853. if postIndex > l {
  1854. return io.ErrUnexpectedEOF
  1855. }
  1856. if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1857. return err
  1858. }
  1859. iNdEx = postIndex
  1860. case 3:
  1861. if wireType != 2 {
  1862. return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
  1863. }
  1864. var msglen int
  1865. for shift := uint(0); ; shift += 7 {
  1866. if shift >= 64 {
  1867. return ErrIntOverflowGenerated
  1868. }
  1869. if iNdEx >= l {
  1870. return io.ErrUnexpectedEOF
  1871. }
  1872. b := dAtA[iNdEx]
  1873. iNdEx++
  1874. msglen |= (int(b) & 0x7F) << shift
  1875. if b < 0x80 {
  1876. break
  1877. }
  1878. }
  1879. if msglen < 0 {
  1880. return ErrInvalidLengthGenerated
  1881. }
  1882. postIndex := iNdEx + msglen
  1883. if postIndex > l {
  1884. return io.ErrUnexpectedEOF
  1885. }
  1886. if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1887. return err
  1888. }
  1889. iNdEx = postIndex
  1890. default:
  1891. iNdEx = preIndex
  1892. skippy, err := skipGenerated(dAtA[iNdEx:])
  1893. if err != nil {
  1894. return err
  1895. }
  1896. if skippy < 0 {
  1897. return ErrInvalidLengthGenerated
  1898. }
  1899. if (iNdEx + skippy) > l {
  1900. return io.ErrUnexpectedEOF
  1901. }
  1902. iNdEx += skippy
  1903. }
  1904. }
  1905. if iNdEx > l {
  1906. return io.ErrUnexpectedEOF
  1907. }
  1908. return nil
  1909. }
  1910. func (m *HorizontalPodAutoscalerCondition) Unmarshal(dAtA []byte) error {
  1911. l := len(dAtA)
  1912. iNdEx := 0
  1913. for iNdEx < l {
  1914. preIndex := iNdEx
  1915. var wire uint64
  1916. for shift := uint(0); ; shift += 7 {
  1917. if shift >= 64 {
  1918. return ErrIntOverflowGenerated
  1919. }
  1920. if iNdEx >= l {
  1921. return io.ErrUnexpectedEOF
  1922. }
  1923. b := dAtA[iNdEx]
  1924. iNdEx++
  1925. wire |= (uint64(b) & 0x7F) << shift
  1926. if b < 0x80 {
  1927. break
  1928. }
  1929. }
  1930. fieldNum := int32(wire >> 3)
  1931. wireType := int(wire & 0x7)
  1932. if wireType == 4 {
  1933. return fmt.Errorf("proto: HorizontalPodAutoscalerCondition: wiretype end group for non-group")
  1934. }
  1935. if fieldNum <= 0 {
  1936. return fmt.Errorf("proto: HorizontalPodAutoscalerCondition: illegal tag %d (wire type %d)", fieldNum, wire)
  1937. }
  1938. switch fieldNum {
  1939. case 1:
  1940. if wireType != 2 {
  1941. return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
  1942. }
  1943. var stringLen uint64
  1944. for shift := uint(0); ; shift += 7 {
  1945. if shift >= 64 {
  1946. return ErrIntOverflowGenerated
  1947. }
  1948. if iNdEx >= l {
  1949. return io.ErrUnexpectedEOF
  1950. }
  1951. b := dAtA[iNdEx]
  1952. iNdEx++
  1953. stringLen |= (uint64(b) & 0x7F) << shift
  1954. if b < 0x80 {
  1955. break
  1956. }
  1957. }
  1958. intStringLen := int(stringLen)
  1959. if intStringLen < 0 {
  1960. return ErrInvalidLengthGenerated
  1961. }
  1962. postIndex := iNdEx + intStringLen
  1963. if postIndex > l {
  1964. return io.ErrUnexpectedEOF
  1965. }
  1966. m.Type = HorizontalPodAutoscalerConditionType(dAtA[iNdEx:postIndex])
  1967. iNdEx = postIndex
  1968. case 2:
  1969. if wireType != 2 {
  1970. return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
  1971. }
  1972. var stringLen uint64
  1973. for shift := uint(0); ; shift += 7 {
  1974. if shift >= 64 {
  1975. return ErrIntOverflowGenerated
  1976. }
  1977. if iNdEx >= l {
  1978. return io.ErrUnexpectedEOF
  1979. }
  1980. b := dAtA[iNdEx]
  1981. iNdEx++
  1982. stringLen |= (uint64(b) & 0x7F) << shift
  1983. if b < 0x80 {
  1984. break
  1985. }
  1986. }
  1987. intStringLen := int(stringLen)
  1988. if intStringLen < 0 {
  1989. return ErrInvalidLengthGenerated
  1990. }
  1991. postIndex := iNdEx + intStringLen
  1992. if postIndex > l {
  1993. return io.ErrUnexpectedEOF
  1994. }
  1995. m.Status = k8s_io_api_core_v1.ConditionStatus(dAtA[iNdEx:postIndex])
  1996. iNdEx = postIndex
  1997. case 3:
  1998. if wireType != 2 {
  1999. return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType)
  2000. }
  2001. var msglen int
  2002. for shift := uint(0); ; shift += 7 {
  2003. if shift >= 64 {
  2004. return ErrIntOverflowGenerated
  2005. }
  2006. if iNdEx >= l {
  2007. return io.ErrUnexpectedEOF
  2008. }
  2009. b := dAtA[iNdEx]
  2010. iNdEx++
  2011. msglen |= (int(b) & 0x7F) << shift
  2012. if b < 0x80 {
  2013. break
  2014. }
  2015. }
  2016. if msglen < 0 {
  2017. return ErrInvalidLengthGenerated
  2018. }
  2019. postIndex := iNdEx + msglen
  2020. if postIndex > l {
  2021. return io.ErrUnexpectedEOF
  2022. }
  2023. if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2024. return err
  2025. }
  2026. iNdEx = postIndex
  2027. case 4:
  2028. if wireType != 2 {
  2029. return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType)
  2030. }
  2031. var stringLen uint64
  2032. for shift := uint(0); ; shift += 7 {
  2033. if shift >= 64 {
  2034. return ErrIntOverflowGenerated
  2035. }
  2036. if iNdEx >= l {
  2037. return io.ErrUnexpectedEOF
  2038. }
  2039. b := dAtA[iNdEx]
  2040. iNdEx++
  2041. stringLen |= (uint64(b) & 0x7F) << shift
  2042. if b < 0x80 {
  2043. break
  2044. }
  2045. }
  2046. intStringLen := int(stringLen)
  2047. if intStringLen < 0 {
  2048. return ErrInvalidLengthGenerated
  2049. }
  2050. postIndex := iNdEx + intStringLen
  2051. if postIndex > l {
  2052. return io.ErrUnexpectedEOF
  2053. }
  2054. m.Reason = string(dAtA[iNdEx:postIndex])
  2055. iNdEx = postIndex
  2056. case 5:
  2057. if wireType != 2 {
  2058. return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
  2059. }
  2060. var stringLen uint64
  2061. for shift := uint(0); ; shift += 7 {
  2062. if shift >= 64 {
  2063. return ErrIntOverflowGenerated
  2064. }
  2065. if iNdEx >= l {
  2066. return io.ErrUnexpectedEOF
  2067. }
  2068. b := dAtA[iNdEx]
  2069. iNdEx++
  2070. stringLen |= (uint64(b) & 0x7F) << shift
  2071. if b < 0x80 {
  2072. break
  2073. }
  2074. }
  2075. intStringLen := int(stringLen)
  2076. if intStringLen < 0 {
  2077. return ErrInvalidLengthGenerated
  2078. }
  2079. postIndex := iNdEx + intStringLen
  2080. if postIndex > l {
  2081. return io.ErrUnexpectedEOF
  2082. }
  2083. m.Message = string(dAtA[iNdEx:postIndex])
  2084. iNdEx = postIndex
  2085. default:
  2086. iNdEx = preIndex
  2087. skippy, err := skipGenerated(dAtA[iNdEx:])
  2088. if err != nil {
  2089. return err
  2090. }
  2091. if skippy < 0 {
  2092. return ErrInvalidLengthGenerated
  2093. }
  2094. if (iNdEx + skippy) > l {
  2095. return io.ErrUnexpectedEOF
  2096. }
  2097. iNdEx += skippy
  2098. }
  2099. }
  2100. if iNdEx > l {
  2101. return io.ErrUnexpectedEOF
  2102. }
  2103. return nil
  2104. }
  2105. func (m *HorizontalPodAutoscalerList) Unmarshal(dAtA []byte) error {
  2106. l := len(dAtA)
  2107. iNdEx := 0
  2108. for iNdEx < l {
  2109. preIndex := iNdEx
  2110. var wire uint64
  2111. for shift := uint(0); ; shift += 7 {
  2112. if shift >= 64 {
  2113. return ErrIntOverflowGenerated
  2114. }
  2115. if iNdEx >= l {
  2116. return io.ErrUnexpectedEOF
  2117. }
  2118. b := dAtA[iNdEx]
  2119. iNdEx++
  2120. wire |= (uint64(b) & 0x7F) << shift
  2121. if b < 0x80 {
  2122. break
  2123. }
  2124. }
  2125. fieldNum := int32(wire >> 3)
  2126. wireType := int(wire & 0x7)
  2127. if wireType == 4 {
  2128. return fmt.Errorf("proto: HorizontalPodAutoscalerList: wiretype end group for non-group")
  2129. }
  2130. if fieldNum <= 0 {
  2131. return fmt.Errorf("proto: HorizontalPodAutoscalerList: illegal tag %d (wire type %d)", fieldNum, wire)
  2132. }
  2133. switch fieldNum {
  2134. case 1:
  2135. if wireType != 2 {
  2136. return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
  2137. }
  2138. var msglen int
  2139. for shift := uint(0); ; shift += 7 {
  2140. if shift >= 64 {
  2141. return ErrIntOverflowGenerated
  2142. }
  2143. if iNdEx >= l {
  2144. return io.ErrUnexpectedEOF
  2145. }
  2146. b := dAtA[iNdEx]
  2147. iNdEx++
  2148. msglen |= (int(b) & 0x7F) << shift
  2149. if b < 0x80 {
  2150. break
  2151. }
  2152. }
  2153. if msglen < 0 {
  2154. return ErrInvalidLengthGenerated
  2155. }
  2156. postIndex := iNdEx + msglen
  2157. if postIndex > l {
  2158. return io.ErrUnexpectedEOF
  2159. }
  2160. if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2161. return err
  2162. }
  2163. iNdEx = postIndex
  2164. case 2:
  2165. if wireType != 2 {
  2166. return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
  2167. }
  2168. var msglen int
  2169. for shift := uint(0); ; shift += 7 {
  2170. if shift >= 64 {
  2171. return ErrIntOverflowGenerated
  2172. }
  2173. if iNdEx >= l {
  2174. return io.ErrUnexpectedEOF
  2175. }
  2176. b := dAtA[iNdEx]
  2177. iNdEx++
  2178. msglen |= (int(b) & 0x7F) << shift
  2179. if b < 0x80 {
  2180. break
  2181. }
  2182. }
  2183. if msglen < 0 {
  2184. return ErrInvalidLengthGenerated
  2185. }
  2186. postIndex := iNdEx + msglen
  2187. if postIndex > l {
  2188. return io.ErrUnexpectedEOF
  2189. }
  2190. m.Items = append(m.Items, HorizontalPodAutoscaler{})
  2191. if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2192. return err
  2193. }
  2194. iNdEx = postIndex
  2195. default:
  2196. iNdEx = preIndex
  2197. skippy, err := skipGenerated(dAtA[iNdEx:])
  2198. if err != nil {
  2199. return err
  2200. }
  2201. if skippy < 0 {
  2202. return ErrInvalidLengthGenerated
  2203. }
  2204. if (iNdEx + skippy) > l {
  2205. return io.ErrUnexpectedEOF
  2206. }
  2207. iNdEx += skippy
  2208. }
  2209. }
  2210. if iNdEx > l {
  2211. return io.ErrUnexpectedEOF
  2212. }
  2213. return nil
  2214. }
  2215. func (m *HorizontalPodAutoscalerSpec) Unmarshal(dAtA []byte) error {
  2216. l := len(dAtA)
  2217. iNdEx := 0
  2218. for iNdEx < l {
  2219. preIndex := iNdEx
  2220. var wire uint64
  2221. for shift := uint(0); ; shift += 7 {
  2222. if shift >= 64 {
  2223. return ErrIntOverflowGenerated
  2224. }
  2225. if iNdEx >= l {
  2226. return io.ErrUnexpectedEOF
  2227. }
  2228. b := dAtA[iNdEx]
  2229. iNdEx++
  2230. wire |= (uint64(b) & 0x7F) << shift
  2231. if b < 0x80 {
  2232. break
  2233. }
  2234. }
  2235. fieldNum := int32(wire >> 3)
  2236. wireType := int(wire & 0x7)
  2237. if wireType == 4 {
  2238. return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: wiretype end group for non-group")
  2239. }
  2240. if fieldNum <= 0 {
  2241. return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: illegal tag %d (wire type %d)", fieldNum, wire)
  2242. }
  2243. switch fieldNum {
  2244. case 1:
  2245. if wireType != 2 {
  2246. return fmt.Errorf("proto: wrong wireType = %d for field ScaleTargetRef", wireType)
  2247. }
  2248. var msglen int
  2249. for shift := uint(0); ; shift += 7 {
  2250. if shift >= 64 {
  2251. return ErrIntOverflowGenerated
  2252. }
  2253. if iNdEx >= l {
  2254. return io.ErrUnexpectedEOF
  2255. }
  2256. b := dAtA[iNdEx]
  2257. iNdEx++
  2258. msglen |= (int(b) & 0x7F) << shift
  2259. if b < 0x80 {
  2260. break
  2261. }
  2262. }
  2263. if msglen < 0 {
  2264. return ErrInvalidLengthGenerated
  2265. }
  2266. postIndex := iNdEx + msglen
  2267. if postIndex > l {
  2268. return io.ErrUnexpectedEOF
  2269. }
  2270. if err := m.ScaleTargetRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2271. return err
  2272. }
  2273. iNdEx = postIndex
  2274. case 2:
  2275. if wireType != 0 {
  2276. return fmt.Errorf("proto: wrong wireType = %d for field MinReplicas", wireType)
  2277. }
  2278. var v int32
  2279. for shift := uint(0); ; shift += 7 {
  2280. if shift >= 64 {
  2281. return ErrIntOverflowGenerated
  2282. }
  2283. if iNdEx >= l {
  2284. return io.ErrUnexpectedEOF
  2285. }
  2286. b := dAtA[iNdEx]
  2287. iNdEx++
  2288. v |= (int32(b) & 0x7F) << shift
  2289. if b < 0x80 {
  2290. break
  2291. }
  2292. }
  2293. m.MinReplicas = &v
  2294. case 3:
  2295. if wireType != 0 {
  2296. return fmt.Errorf("proto: wrong wireType = %d for field MaxReplicas", wireType)
  2297. }
  2298. m.MaxReplicas = 0
  2299. for shift := uint(0); ; shift += 7 {
  2300. if shift >= 64 {
  2301. return ErrIntOverflowGenerated
  2302. }
  2303. if iNdEx >= l {
  2304. return io.ErrUnexpectedEOF
  2305. }
  2306. b := dAtA[iNdEx]
  2307. iNdEx++
  2308. m.MaxReplicas |= (int32(b) & 0x7F) << shift
  2309. if b < 0x80 {
  2310. break
  2311. }
  2312. }
  2313. case 4:
  2314. if wireType != 2 {
  2315. return fmt.Errorf("proto: wrong wireType = %d for field Metrics", wireType)
  2316. }
  2317. var msglen int
  2318. for shift := uint(0); ; shift += 7 {
  2319. if shift >= 64 {
  2320. return ErrIntOverflowGenerated
  2321. }
  2322. if iNdEx >= l {
  2323. return io.ErrUnexpectedEOF
  2324. }
  2325. b := dAtA[iNdEx]
  2326. iNdEx++
  2327. msglen |= (int(b) & 0x7F) << shift
  2328. if b < 0x80 {
  2329. break
  2330. }
  2331. }
  2332. if msglen < 0 {
  2333. return ErrInvalidLengthGenerated
  2334. }
  2335. postIndex := iNdEx + msglen
  2336. if postIndex > l {
  2337. return io.ErrUnexpectedEOF
  2338. }
  2339. m.Metrics = append(m.Metrics, MetricSpec{})
  2340. if err := m.Metrics[len(m.Metrics)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2341. return err
  2342. }
  2343. iNdEx = postIndex
  2344. default:
  2345. iNdEx = preIndex
  2346. skippy, err := skipGenerated(dAtA[iNdEx:])
  2347. if err != nil {
  2348. return err
  2349. }
  2350. if skippy < 0 {
  2351. return ErrInvalidLengthGenerated
  2352. }
  2353. if (iNdEx + skippy) > l {
  2354. return io.ErrUnexpectedEOF
  2355. }
  2356. iNdEx += skippy
  2357. }
  2358. }
  2359. if iNdEx > l {
  2360. return io.ErrUnexpectedEOF
  2361. }
  2362. return nil
  2363. }
  2364. func (m *HorizontalPodAutoscalerStatus) Unmarshal(dAtA []byte) error {
  2365. l := len(dAtA)
  2366. iNdEx := 0
  2367. for iNdEx < l {
  2368. preIndex := iNdEx
  2369. var wire uint64
  2370. for shift := uint(0); ; shift += 7 {
  2371. if shift >= 64 {
  2372. return ErrIntOverflowGenerated
  2373. }
  2374. if iNdEx >= l {
  2375. return io.ErrUnexpectedEOF
  2376. }
  2377. b := dAtA[iNdEx]
  2378. iNdEx++
  2379. wire |= (uint64(b) & 0x7F) << shift
  2380. if b < 0x80 {
  2381. break
  2382. }
  2383. }
  2384. fieldNum := int32(wire >> 3)
  2385. wireType := int(wire & 0x7)
  2386. if wireType == 4 {
  2387. return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: wiretype end group for non-group")
  2388. }
  2389. if fieldNum <= 0 {
  2390. return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: illegal tag %d (wire type %d)", fieldNum, wire)
  2391. }
  2392. switch fieldNum {
  2393. case 1:
  2394. if wireType != 0 {
  2395. return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType)
  2396. }
  2397. var v int64
  2398. for shift := uint(0); ; shift += 7 {
  2399. if shift >= 64 {
  2400. return ErrIntOverflowGenerated
  2401. }
  2402. if iNdEx >= l {
  2403. return io.ErrUnexpectedEOF
  2404. }
  2405. b := dAtA[iNdEx]
  2406. iNdEx++
  2407. v |= (int64(b) & 0x7F) << shift
  2408. if b < 0x80 {
  2409. break
  2410. }
  2411. }
  2412. m.ObservedGeneration = &v
  2413. case 2:
  2414. if wireType != 2 {
  2415. return fmt.Errorf("proto: wrong wireType = %d for field LastScaleTime", wireType)
  2416. }
  2417. var msglen int
  2418. for shift := uint(0); ; shift += 7 {
  2419. if shift >= 64 {
  2420. return ErrIntOverflowGenerated
  2421. }
  2422. if iNdEx >= l {
  2423. return io.ErrUnexpectedEOF
  2424. }
  2425. b := dAtA[iNdEx]
  2426. iNdEx++
  2427. msglen |= (int(b) & 0x7F) << shift
  2428. if b < 0x80 {
  2429. break
  2430. }
  2431. }
  2432. if msglen < 0 {
  2433. return ErrInvalidLengthGenerated
  2434. }
  2435. postIndex := iNdEx + msglen
  2436. if postIndex > l {
  2437. return io.ErrUnexpectedEOF
  2438. }
  2439. if m.LastScaleTime == nil {
  2440. m.LastScaleTime = &k8s_io_apimachinery_pkg_apis_meta_v1.Time{}
  2441. }
  2442. if err := m.LastScaleTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2443. return err
  2444. }
  2445. iNdEx = postIndex
  2446. case 3:
  2447. if wireType != 0 {
  2448. return fmt.Errorf("proto: wrong wireType = %d for field CurrentReplicas", wireType)
  2449. }
  2450. m.CurrentReplicas = 0
  2451. for shift := uint(0); ; shift += 7 {
  2452. if shift >= 64 {
  2453. return ErrIntOverflowGenerated
  2454. }
  2455. if iNdEx >= l {
  2456. return io.ErrUnexpectedEOF
  2457. }
  2458. b := dAtA[iNdEx]
  2459. iNdEx++
  2460. m.CurrentReplicas |= (int32(b) & 0x7F) << shift
  2461. if b < 0x80 {
  2462. break
  2463. }
  2464. }
  2465. case 4:
  2466. if wireType != 0 {
  2467. return fmt.Errorf("proto: wrong wireType = %d for field DesiredReplicas", wireType)
  2468. }
  2469. m.DesiredReplicas = 0
  2470. for shift := uint(0); ; shift += 7 {
  2471. if shift >= 64 {
  2472. return ErrIntOverflowGenerated
  2473. }
  2474. if iNdEx >= l {
  2475. return io.ErrUnexpectedEOF
  2476. }
  2477. b := dAtA[iNdEx]
  2478. iNdEx++
  2479. m.DesiredReplicas |= (int32(b) & 0x7F) << shift
  2480. if b < 0x80 {
  2481. break
  2482. }
  2483. }
  2484. case 5:
  2485. if wireType != 2 {
  2486. return fmt.Errorf("proto: wrong wireType = %d for field CurrentMetrics", wireType)
  2487. }
  2488. var msglen int
  2489. for shift := uint(0); ; shift += 7 {
  2490. if shift >= 64 {
  2491. return ErrIntOverflowGenerated
  2492. }
  2493. if iNdEx >= l {
  2494. return io.ErrUnexpectedEOF
  2495. }
  2496. b := dAtA[iNdEx]
  2497. iNdEx++
  2498. msglen |= (int(b) & 0x7F) << shift
  2499. if b < 0x80 {
  2500. break
  2501. }
  2502. }
  2503. if msglen < 0 {
  2504. return ErrInvalidLengthGenerated
  2505. }
  2506. postIndex := iNdEx + msglen
  2507. if postIndex > l {
  2508. return io.ErrUnexpectedEOF
  2509. }
  2510. m.CurrentMetrics = append(m.CurrentMetrics, MetricStatus{})
  2511. if err := m.CurrentMetrics[len(m.CurrentMetrics)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2512. return err
  2513. }
  2514. iNdEx = postIndex
  2515. case 6:
  2516. if wireType != 2 {
  2517. return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType)
  2518. }
  2519. var msglen int
  2520. for shift := uint(0); ; shift += 7 {
  2521. if shift >= 64 {
  2522. return ErrIntOverflowGenerated
  2523. }
  2524. if iNdEx >= l {
  2525. return io.ErrUnexpectedEOF
  2526. }
  2527. b := dAtA[iNdEx]
  2528. iNdEx++
  2529. msglen |= (int(b) & 0x7F) << shift
  2530. if b < 0x80 {
  2531. break
  2532. }
  2533. }
  2534. if msglen < 0 {
  2535. return ErrInvalidLengthGenerated
  2536. }
  2537. postIndex := iNdEx + msglen
  2538. if postIndex > l {
  2539. return io.ErrUnexpectedEOF
  2540. }
  2541. m.Conditions = append(m.Conditions, HorizontalPodAutoscalerCondition{})
  2542. if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2543. return err
  2544. }
  2545. iNdEx = postIndex
  2546. default:
  2547. iNdEx = preIndex
  2548. skippy, err := skipGenerated(dAtA[iNdEx:])
  2549. if err != nil {
  2550. return err
  2551. }
  2552. if skippy < 0 {
  2553. return ErrInvalidLengthGenerated
  2554. }
  2555. if (iNdEx + skippy) > l {
  2556. return io.ErrUnexpectedEOF
  2557. }
  2558. iNdEx += skippy
  2559. }
  2560. }
  2561. if iNdEx > l {
  2562. return io.ErrUnexpectedEOF
  2563. }
  2564. return nil
  2565. }
  2566. func (m *MetricIdentifier) Unmarshal(dAtA []byte) error {
  2567. l := len(dAtA)
  2568. iNdEx := 0
  2569. for iNdEx < l {
  2570. preIndex := iNdEx
  2571. var wire uint64
  2572. for shift := uint(0); ; shift += 7 {
  2573. if shift >= 64 {
  2574. return ErrIntOverflowGenerated
  2575. }
  2576. if iNdEx >= l {
  2577. return io.ErrUnexpectedEOF
  2578. }
  2579. b := dAtA[iNdEx]
  2580. iNdEx++
  2581. wire |= (uint64(b) & 0x7F) << shift
  2582. if b < 0x80 {
  2583. break
  2584. }
  2585. }
  2586. fieldNum := int32(wire >> 3)
  2587. wireType := int(wire & 0x7)
  2588. if wireType == 4 {
  2589. return fmt.Errorf("proto: MetricIdentifier: wiretype end group for non-group")
  2590. }
  2591. if fieldNum <= 0 {
  2592. return fmt.Errorf("proto: MetricIdentifier: illegal tag %d (wire type %d)", fieldNum, wire)
  2593. }
  2594. switch fieldNum {
  2595. case 1:
  2596. if wireType != 2 {
  2597. return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
  2598. }
  2599. var stringLen uint64
  2600. for shift := uint(0); ; shift += 7 {
  2601. if shift >= 64 {
  2602. return ErrIntOverflowGenerated
  2603. }
  2604. if iNdEx >= l {
  2605. return io.ErrUnexpectedEOF
  2606. }
  2607. b := dAtA[iNdEx]
  2608. iNdEx++
  2609. stringLen |= (uint64(b) & 0x7F) << shift
  2610. if b < 0x80 {
  2611. break
  2612. }
  2613. }
  2614. intStringLen := int(stringLen)
  2615. if intStringLen < 0 {
  2616. return ErrInvalidLengthGenerated
  2617. }
  2618. postIndex := iNdEx + intStringLen
  2619. if postIndex > l {
  2620. return io.ErrUnexpectedEOF
  2621. }
  2622. m.Name = string(dAtA[iNdEx:postIndex])
  2623. iNdEx = postIndex
  2624. case 2:
  2625. if wireType != 2 {
  2626. return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType)
  2627. }
  2628. var msglen int
  2629. for shift := uint(0); ; shift += 7 {
  2630. if shift >= 64 {
  2631. return ErrIntOverflowGenerated
  2632. }
  2633. if iNdEx >= l {
  2634. return io.ErrUnexpectedEOF
  2635. }
  2636. b := dAtA[iNdEx]
  2637. iNdEx++
  2638. msglen |= (int(b) & 0x7F) << shift
  2639. if b < 0x80 {
  2640. break
  2641. }
  2642. }
  2643. if msglen < 0 {
  2644. return ErrInvalidLengthGenerated
  2645. }
  2646. postIndex := iNdEx + msglen
  2647. if postIndex > l {
  2648. return io.ErrUnexpectedEOF
  2649. }
  2650. if m.Selector == nil {
  2651. m.Selector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{}
  2652. }
  2653. if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2654. return err
  2655. }
  2656. iNdEx = postIndex
  2657. default:
  2658. iNdEx = preIndex
  2659. skippy, err := skipGenerated(dAtA[iNdEx:])
  2660. if err != nil {
  2661. return err
  2662. }
  2663. if skippy < 0 {
  2664. return ErrInvalidLengthGenerated
  2665. }
  2666. if (iNdEx + skippy) > l {
  2667. return io.ErrUnexpectedEOF
  2668. }
  2669. iNdEx += skippy
  2670. }
  2671. }
  2672. if iNdEx > l {
  2673. return io.ErrUnexpectedEOF
  2674. }
  2675. return nil
  2676. }
  2677. func (m *MetricSpec) Unmarshal(dAtA []byte) error {
  2678. l := len(dAtA)
  2679. iNdEx := 0
  2680. for iNdEx < l {
  2681. preIndex := iNdEx
  2682. var wire uint64
  2683. for shift := uint(0); ; shift += 7 {
  2684. if shift >= 64 {
  2685. return ErrIntOverflowGenerated
  2686. }
  2687. if iNdEx >= l {
  2688. return io.ErrUnexpectedEOF
  2689. }
  2690. b := dAtA[iNdEx]
  2691. iNdEx++
  2692. wire |= (uint64(b) & 0x7F) << shift
  2693. if b < 0x80 {
  2694. break
  2695. }
  2696. }
  2697. fieldNum := int32(wire >> 3)
  2698. wireType := int(wire & 0x7)
  2699. if wireType == 4 {
  2700. return fmt.Errorf("proto: MetricSpec: wiretype end group for non-group")
  2701. }
  2702. if fieldNum <= 0 {
  2703. return fmt.Errorf("proto: MetricSpec: illegal tag %d (wire type %d)", fieldNum, wire)
  2704. }
  2705. switch fieldNum {
  2706. case 1:
  2707. if wireType != 2 {
  2708. return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
  2709. }
  2710. var stringLen uint64
  2711. for shift := uint(0); ; shift += 7 {
  2712. if shift >= 64 {
  2713. return ErrIntOverflowGenerated
  2714. }
  2715. if iNdEx >= l {
  2716. return io.ErrUnexpectedEOF
  2717. }
  2718. b := dAtA[iNdEx]
  2719. iNdEx++
  2720. stringLen |= (uint64(b) & 0x7F) << shift
  2721. if b < 0x80 {
  2722. break
  2723. }
  2724. }
  2725. intStringLen := int(stringLen)
  2726. if intStringLen < 0 {
  2727. return ErrInvalidLengthGenerated
  2728. }
  2729. postIndex := iNdEx + intStringLen
  2730. if postIndex > l {
  2731. return io.ErrUnexpectedEOF
  2732. }
  2733. m.Type = MetricSourceType(dAtA[iNdEx:postIndex])
  2734. iNdEx = postIndex
  2735. case 2:
  2736. if wireType != 2 {
  2737. return fmt.Errorf("proto: wrong wireType = %d for field Object", wireType)
  2738. }
  2739. var msglen int
  2740. for shift := uint(0); ; shift += 7 {
  2741. if shift >= 64 {
  2742. return ErrIntOverflowGenerated
  2743. }
  2744. if iNdEx >= l {
  2745. return io.ErrUnexpectedEOF
  2746. }
  2747. b := dAtA[iNdEx]
  2748. iNdEx++
  2749. msglen |= (int(b) & 0x7F) << shift
  2750. if b < 0x80 {
  2751. break
  2752. }
  2753. }
  2754. if msglen < 0 {
  2755. return ErrInvalidLengthGenerated
  2756. }
  2757. postIndex := iNdEx + msglen
  2758. if postIndex > l {
  2759. return io.ErrUnexpectedEOF
  2760. }
  2761. if m.Object == nil {
  2762. m.Object = &ObjectMetricSource{}
  2763. }
  2764. if err := m.Object.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2765. return err
  2766. }
  2767. iNdEx = postIndex
  2768. case 3:
  2769. if wireType != 2 {
  2770. return fmt.Errorf("proto: wrong wireType = %d for field Pods", wireType)
  2771. }
  2772. var msglen int
  2773. for shift := uint(0); ; shift += 7 {
  2774. if shift >= 64 {
  2775. return ErrIntOverflowGenerated
  2776. }
  2777. if iNdEx >= l {
  2778. return io.ErrUnexpectedEOF
  2779. }
  2780. b := dAtA[iNdEx]
  2781. iNdEx++
  2782. msglen |= (int(b) & 0x7F) << shift
  2783. if b < 0x80 {
  2784. break
  2785. }
  2786. }
  2787. if msglen < 0 {
  2788. return ErrInvalidLengthGenerated
  2789. }
  2790. postIndex := iNdEx + msglen
  2791. if postIndex > l {
  2792. return io.ErrUnexpectedEOF
  2793. }
  2794. if m.Pods == nil {
  2795. m.Pods = &PodsMetricSource{}
  2796. }
  2797. if err := m.Pods.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2798. return err
  2799. }
  2800. iNdEx = postIndex
  2801. case 4:
  2802. if wireType != 2 {
  2803. return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType)
  2804. }
  2805. var msglen int
  2806. for shift := uint(0); ; shift += 7 {
  2807. if shift >= 64 {
  2808. return ErrIntOverflowGenerated
  2809. }
  2810. if iNdEx >= l {
  2811. return io.ErrUnexpectedEOF
  2812. }
  2813. b := dAtA[iNdEx]
  2814. iNdEx++
  2815. msglen |= (int(b) & 0x7F) << shift
  2816. if b < 0x80 {
  2817. break
  2818. }
  2819. }
  2820. if msglen < 0 {
  2821. return ErrInvalidLengthGenerated
  2822. }
  2823. postIndex := iNdEx + msglen
  2824. if postIndex > l {
  2825. return io.ErrUnexpectedEOF
  2826. }
  2827. if m.Resource == nil {
  2828. m.Resource = &ResourceMetricSource{}
  2829. }
  2830. if err := m.Resource.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2831. return err
  2832. }
  2833. iNdEx = postIndex
  2834. case 5:
  2835. if wireType != 2 {
  2836. return fmt.Errorf("proto: wrong wireType = %d for field External", wireType)
  2837. }
  2838. var msglen int
  2839. for shift := uint(0); ; shift += 7 {
  2840. if shift >= 64 {
  2841. return ErrIntOverflowGenerated
  2842. }
  2843. if iNdEx >= l {
  2844. return io.ErrUnexpectedEOF
  2845. }
  2846. b := dAtA[iNdEx]
  2847. iNdEx++
  2848. msglen |= (int(b) & 0x7F) << shift
  2849. if b < 0x80 {
  2850. break
  2851. }
  2852. }
  2853. if msglen < 0 {
  2854. return ErrInvalidLengthGenerated
  2855. }
  2856. postIndex := iNdEx + msglen
  2857. if postIndex > l {
  2858. return io.ErrUnexpectedEOF
  2859. }
  2860. if m.External == nil {
  2861. m.External = &ExternalMetricSource{}
  2862. }
  2863. if err := m.External.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2864. return err
  2865. }
  2866. iNdEx = postIndex
  2867. default:
  2868. iNdEx = preIndex
  2869. skippy, err := skipGenerated(dAtA[iNdEx:])
  2870. if err != nil {
  2871. return err
  2872. }
  2873. if skippy < 0 {
  2874. return ErrInvalidLengthGenerated
  2875. }
  2876. if (iNdEx + skippy) > l {
  2877. return io.ErrUnexpectedEOF
  2878. }
  2879. iNdEx += skippy
  2880. }
  2881. }
  2882. if iNdEx > l {
  2883. return io.ErrUnexpectedEOF
  2884. }
  2885. return nil
  2886. }
  2887. func (m *MetricStatus) Unmarshal(dAtA []byte) error {
  2888. l := len(dAtA)
  2889. iNdEx := 0
  2890. for iNdEx < l {
  2891. preIndex := iNdEx
  2892. var wire uint64
  2893. for shift := uint(0); ; shift += 7 {
  2894. if shift >= 64 {
  2895. return ErrIntOverflowGenerated
  2896. }
  2897. if iNdEx >= l {
  2898. return io.ErrUnexpectedEOF
  2899. }
  2900. b := dAtA[iNdEx]
  2901. iNdEx++
  2902. wire |= (uint64(b) & 0x7F) << shift
  2903. if b < 0x80 {
  2904. break
  2905. }
  2906. }
  2907. fieldNum := int32(wire >> 3)
  2908. wireType := int(wire & 0x7)
  2909. if wireType == 4 {
  2910. return fmt.Errorf("proto: MetricStatus: wiretype end group for non-group")
  2911. }
  2912. if fieldNum <= 0 {
  2913. return fmt.Errorf("proto: MetricStatus: illegal tag %d (wire type %d)", fieldNum, wire)
  2914. }
  2915. switch fieldNum {
  2916. case 1:
  2917. if wireType != 2 {
  2918. return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
  2919. }
  2920. var stringLen uint64
  2921. for shift := uint(0); ; shift += 7 {
  2922. if shift >= 64 {
  2923. return ErrIntOverflowGenerated
  2924. }
  2925. if iNdEx >= l {
  2926. return io.ErrUnexpectedEOF
  2927. }
  2928. b := dAtA[iNdEx]
  2929. iNdEx++
  2930. stringLen |= (uint64(b) & 0x7F) << shift
  2931. if b < 0x80 {
  2932. break
  2933. }
  2934. }
  2935. intStringLen := int(stringLen)
  2936. if intStringLen < 0 {
  2937. return ErrInvalidLengthGenerated
  2938. }
  2939. postIndex := iNdEx + intStringLen
  2940. if postIndex > l {
  2941. return io.ErrUnexpectedEOF
  2942. }
  2943. m.Type = MetricSourceType(dAtA[iNdEx:postIndex])
  2944. iNdEx = postIndex
  2945. case 2:
  2946. if wireType != 2 {
  2947. return fmt.Errorf("proto: wrong wireType = %d for field Object", wireType)
  2948. }
  2949. var msglen int
  2950. for shift := uint(0); ; shift += 7 {
  2951. if shift >= 64 {
  2952. return ErrIntOverflowGenerated
  2953. }
  2954. if iNdEx >= l {
  2955. return io.ErrUnexpectedEOF
  2956. }
  2957. b := dAtA[iNdEx]
  2958. iNdEx++
  2959. msglen |= (int(b) & 0x7F) << shift
  2960. if b < 0x80 {
  2961. break
  2962. }
  2963. }
  2964. if msglen < 0 {
  2965. return ErrInvalidLengthGenerated
  2966. }
  2967. postIndex := iNdEx + msglen
  2968. if postIndex > l {
  2969. return io.ErrUnexpectedEOF
  2970. }
  2971. if m.Object == nil {
  2972. m.Object = &ObjectMetricStatus{}
  2973. }
  2974. if err := m.Object.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2975. return err
  2976. }
  2977. iNdEx = postIndex
  2978. case 3:
  2979. if wireType != 2 {
  2980. return fmt.Errorf("proto: wrong wireType = %d for field Pods", wireType)
  2981. }
  2982. var msglen int
  2983. for shift := uint(0); ; shift += 7 {
  2984. if shift >= 64 {
  2985. return ErrIntOverflowGenerated
  2986. }
  2987. if iNdEx >= l {
  2988. return io.ErrUnexpectedEOF
  2989. }
  2990. b := dAtA[iNdEx]
  2991. iNdEx++
  2992. msglen |= (int(b) & 0x7F) << shift
  2993. if b < 0x80 {
  2994. break
  2995. }
  2996. }
  2997. if msglen < 0 {
  2998. return ErrInvalidLengthGenerated
  2999. }
  3000. postIndex := iNdEx + msglen
  3001. if postIndex > l {
  3002. return io.ErrUnexpectedEOF
  3003. }
  3004. if m.Pods == nil {
  3005. m.Pods = &PodsMetricStatus{}
  3006. }
  3007. if err := m.Pods.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3008. return err
  3009. }
  3010. iNdEx = postIndex
  3011. case 4:
  3012. if wireType != 2 {
  3013. return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType)
  3014. }
  3015. var msglen int
  3016. for shift := uint(0); ; shift += 7 {
  3017. if shift >= 64 {
  3018. return ErrIntOverflowGenerated
  3019. }
  3020. if iNdEx >= l {
  3021. return io.ErrUnexpectedEOF
  3022. }
  3023. b := dAtA[iNdEx]
  3024. iNdEx++
  3025. msglen |= (int(b) & 0x7F) << shift
  3026. if b < 0x80 {
  3027. break
  3028. }
  3029. }
  3030. if msglen < 0 {
  3031. return ErrInvalidLengthGenerated
  3032. }
  3033. postIndex := iNdEx + msglen
  3034. if postIndex > l {
  3035. return io.ErrUnexpectedEOF
  3036. }
  3037. if m.Resource == nil {
  3038. m.Resource = &ResourceMetricStatus{}
  3039. }
  3040. if err := m.Resource.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3041. return err
  3042. }
  3043. iNdEx = postIndex
  3044. case 5:
  3045. if wireType != 2 {
  3046. return fmt.Errorf("proto: wrong wireType = %d for field External", wireType)
  3047. }
  3048. var msglen int
  3049. for shift := uint(0); ; shift += 7 {
  3050. if shift >= 64 {
  3051. return ErrIntOverflowGenerated
  3052. }
  3053. if iNdEx >= l {
  3054. return io.ErrUnexpectedEOF
  3055. }
  3056. b := dAtA[iNdEx]
  3057. iNdEx++
  3058. msglen |= (int(b) & 0x7F) << shift
  3059. if b < 0x80 {
  3060. break
  3061. }
  3062. }
  3063. if msglen < 0 {
  3064. return ErrInvalidLengthGenerated
  3065. }
  3066. postIndex := iNdEx + msglen
  3067. if postIndex > l {
  3068. return io.ErrUnexpectedEOF
  3069. }
  3070. if m.External == nil {
  3071. m.External = &ExternalMetricStatus{}
  3072. }
  3073. if err := m.External.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3074. return err
  3075. }
  3076. iNdEx = postIndex
  3077. default:
  3078. iNdEx = preIndex
  3079. skippy, err := skipGenerated(dAtA[iNdEx:])
  3080. if err != nil {
  3081. return err
  3082. }
  3083. if skippy < 0 {
  3084. return ErrInvalidLengthGenerated
  3085. }
  3086. if (iNdEx + skippy) > l {
  3087. return io.ErrUnexpectedEOF
  3088. }
  3089. iNdEx += skippy
  3090. }
  3091. }
  3092. if iNdEx > l {
  3093. return io.ErrUnexpectedEOF
  3094. }
  3095. return nil
  3096. }
  3097. func (m *MetricTarget) Unmarshal(dAtA []byte) error {
  3098. l := len(dAtA)
  3099. iNdEx := 0
  3100. for iNdEx < l {
  3101. preIndex := iNdEx
  3102. var wire uint64
  3103. for shift := uint(0); ; shift += 7 {
  3104. if shift >= 64 {
  3105. return ErrIntOverflowGenerated
  3106. }
  3107. if iNdEx >= l {
  3108. return io.ErrUnexpectedEOF
  3109. }
  3110. b := dAtA[iNdEx]
  3111. iNdEx++
  3112. wire |= (uint64(b) & 0x7F) << shift
  3113. if b < 0x80 {
  3114. break
  3115. }
  3116. }
  3117. fieldNum := int32(wire >> 3)
  3118. wireType := int(wire & 0x7)
  3119. if wireType == 4 {
  3120. return fmt.Errorf("proto: MetricTarget: wiretype end group for non-group")
  3121. }
  3122. if fieldNum <= 0 {
  3123. return fmt.Errorf("proto: MetricTarget: illegal tag %d (wire type %d)", fieldNum, wire)
  3124. }
  3125. switch fieldNum {
  3126. case 1:
  3127. if wireType != 2 {
  3128. return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
  3129. }
  3130. var stringLen uint64
  3131. for shift := uint(0); ; shift += 7 {
  3132. if shift >= 64 {
  3133. return ErrIntOverflowGenerated
  3134. }
  3135. if iNdEx >= l {
  3136. return io.ErrUnexpectedEOF
  3137. }
  3138. b := dAtA[iNdEx]
  3139. iNdEx++
  3140. stringLen |= (uint64(b) & 0x7F) << shift
  3141. if b < 0x80 {
  3142. break
  3143. }
  3144. }
  3145. intStringLen := int(stringLen)
  3146. if intStringLen < 0 {
  3147. return ErrInvalidLengthGenerated
  3148. }
  3149. postIndex := iNdEx + intStringLen
  3150. if postIndex > l {
  3151. return io.ErrUnexpectedEOF
  3152. }
  3153. m.Type = MetricTargetType(dAtA[iNdEx:postIndex])
  3154. iNdEx = postIndex
  3155. case 2:
  3156. if wireType != 2 {
  3157. return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
  3158. }
  3159. var msglen int
  3160. for shift := uint(0); ; shift += 7 {
  3161. if shift >= 64 {
  3162. return ErrIntOverflowGenerated
  3163. }
  3164. if iNdEx >= l {
  3165. return io.ErrUnexpectedEOF
  3166. }
  3167. b := dAtA[iNdEx]
  3168. iNdEx++
  3169. msglen |= (int(b) & 0x7F) << shift
  3170. if b < 0x80 {
  3171. break
  3172. }
  3173. }
  3174. if msglen < 0 {
  3175. return ErrInvalidLengthGenerated
  3176. }
  3177. postIndex := iNdEx + msglen
  3178. if postIndex > l {
  3179. return io.ErrUnexpectedEOF
  3180. }
  3181. if m.Value == nil {
  3182. m.Value = &k8s_io_apimachinery_pkg_api_resource.Quantity{}
  3183. }
  3184. if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3185. return err
  3186. }
  3187. iNdEx = postIndex
  3188. case 3:
  3189. if wireType != 2 {
  3190. return fmt.Errorf("proto: wrong wireType = %d for field AverageValue", wireType)
  3191. }
  3192. var msglen int
  3193. for shift := uint(0); ; shift += 7 {
  3194. if shift >= 64 {
  3195. return ErrIntOverflowGenerated
  3196. }
  3197. if iNdEx >= l {
  3198. return io.ErrUnexpectedEOF
  3199. }
  3200. b := dAtA[iNdEx]
  3201. iNdEx++
  3202. msglen |= (int(b) & 0x7F) << shift
  3203. if b < 0x80 {
  3204. break
  3205. }
  3206. }
  3207. if msglen < 0 {
  3208. return ErrInvalidLengthGenerated
  3209. }
  3210. postIndex := iNdEx + msglen
  3211. if postIndex > l {
  3212. return io.ErrUnexpectedEOF
  3213. }
  3214. if m.AverageValue == nil {
  3215. m.AverageValue = &k8s_io_apimachinery_pkg_api_resource.Quantity{}
  3216. }
  3217. if err := m.AverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3218. return err
  3219. }
  3220. iNdEx = postIndex
  3221. case 4:
  3222. if wireType != 0 {
  3223. return fmt.Errorf("proto: wrong wireType = %d for field AverageUtilization", wireType)
  3224. }
  3225. var v int32
  3226. for shift := uint(0); ; shift += 7 {
  3227. if shift >= 64 {
  3228. return ErrIntOverflowGenerated
  3229. }
  3230. if iNdEx >= l {
  3231. return io.ErrUnexpectedEOF
  3232. }
  3233. b := dAtA[iNdEx]
  3234. iNdEx++
  3235. v |= (int32(b) & 0x7F) << shift
  3236. if b < 0x80 {
  3237. break
  3238. }
  3239. }
  3240. m.AverageUtilization = &v
  3241. default:
  3242. iNdEx = preIndex
  3243. skippy, err := skipGenerated(dAtA[iNdEx:])
  3244. if err != nil {
  3245. return err
  3246. }
  3247. if skippy < 0 {
  3248. return ErrInvalidLengthGenerated
  3249. }
  3250. if (iNdEx + skippy) > l {
  3251. return io.ErrUnexpectedEOF
  3252. }
  3253. iNdEx += skippy
  3254. }
  3255. }
  3256. if iNdEx > l {
  3257. return io.ErrUnexpectedEOF
  3258. }
  3259. return nil
  3260. }
  3261. func (m *MetricValueStatus) Unmarshal(dAtA []byte) error {
  3262. l := len(dAtA)
  3263. iNdEx := 0
  3264. for iNdEx < l {
  3265. preIndex := iNdEx
  3266. var wire uint64
  3267. for shift := uint(0); ; shift += 7 {
  3268. if shift >= 64 {
  3269. return ErrIntOverflowGenerated
  3270. }
  3271. if iNdEx >= l {
  3272. return io.ErrUnexpectedEOF
  3273. }
  3274. b := dAtA[iNdEx]
  3275. iNdEx++
  3276. wire |= (uint64(b) & 0x7F) << shift
  3277. if b < 0x80 {
  3278. break
  3279. }
  3280. }
  3281. fieldNum := int32(wire >> 3)
  3282. wireType := int(wire & 0x7)
  3283. if wireType == 4 {
  3284. return fmt.Errorf("proto: MetricValueStatus: wiretype end group for non-group")
  3285. }
  3286. if fieldNum <= 0 {
  3287. return fmt.Errorf("proto: MetricValueStatus: illegal tag %d (wire type %d)", fieldNum, wire)
  3288. }
  3289. switch fieldNum {
  3290. case 1:
  3291. if wireType != 2 {
  3292. return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
  3293. }
  3294. var msglen int
  3295. for shift := uint(0); ; shift += 7 {
  3296. if shift >= 64 {
  3297. return ErrIntOverflowGenerated
  3298. }
  3299. if iNdEx >= l {
  3300. return io.ErrUnexpectedEOF
  3301. }
  3302. b := dAtA[iNdEx]
  3303. iNdEx++
  3304. msglen |= (int(b) & 0x7F) << shift
  3305. if b < 0x80 {
  3306. break
  3307. }
  3308. }
  3309. if msglen < 0 {
  3310. return ErrInvalidLengthGenerated
  3311. }
  3312. postIndex := iNdEx + msglen
  3313. if postIndex > l {
  3314. return io.ErrUnexpectedEOF
  3315. }
  3316. if m.Value == nil {
  3317. m.Value = &k8s_io_apimachinery_pkg_api_resource.Quantity{}
  3318. }
  3319. if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3320. return err
  3321. }
  3322. iNdEx = postIndex
  3323. case 2:
  3324. if wireType != 2 {
  3325. return fmt.Errorf("proto: wrong wireType = %d for field AverageValue", wireType)
  3326. }
  3327. var msglen int
  3328. for shift := uint(0); ; shift += 7 {
  3329. if shift >= 64 {
  3330. return ErrIntOverflowGenerated
  3331. }
  3332. if iNdEx >= l {
  3333. return io.ErrUnexpectedEOF
  3334. }
  3335. b := dAtA[iNdEx]
  3336. iNdEx++
  3337. msglen |= (int(b) & 0x7F) << shift
  3338. if b < 0x80 {
  3339. break
  3340. }
  3341. }
  3342. if msglen < 0 {
  3343. return ErrInvalidLengthGenerated
  3344. }
  3345. postIndex := iNdEx + msglen
  3346. if postIndex > l {
  3347. return io.ErrUnexpectedEOF
  3348. }
  3349. if m.AverageValue == nil {
  3350. m.AverageValue = &k8s_io_apimachinery_pkg_api_resource.Quantity{}
  3351. }
  3352. if err := m.AverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3353. return err
  3354. }
  3355. iNdEx = postIndex
  3356. case 3:
  3357. if wireType != 0 {
  3358. return fmt.Errorf("proto: wrong wireType = %d for field AverageUtilization", wireType)
  3359. }
  3360. var v int32
  3361. for shift := uint(0); ; shift += 7 {
  3362. if shift >= 64 {
  3363. return ErrIntOverflowGenerated
  3364. }
  3365. if iNdEx >= l {
  3366. return io.ErrUnexpectedEOF
  3367. }
  3368. b := dAtA[iNdEx]
  3369. iNdEx++
  3370. v |= (int32(b) & 0x7F) << shift
  3371. if b < 0x80 {
  3372. break
  3373. }
  3374. }
  3375. m.AverageUtilization = &v
  3376. default:
  3377. iNdEx = preIndex
  3378. skippy, err := skipGenerated(dAtA[iNdEx:])
  3379. if err != nil {
  3380. return err
  3381. }
  3382. if skippy < 0 {
  3383. return ErrInvalidLengthGenerated
  3384. }
  3385. if (iNdEx + skippy) > l {
  3386. return io.ErrUnexpectedEOF
  3387. }
  3388. iNdEx += skippy
  3389. }
  3390. }
  3391. if iNdEx > l {
  3392. return io.ErrUnexpectedEOF
  3393. }
  3394. return nil
  3395. }
  3396. func (m *ObjectMetricSource) Unmarshal(dAtA []byte) error {
  3397. l := len(dAtA)
  3398. iNdEx := 0
  3399. for iNdEx < l {
  3400. preIndex := iNdEx
  3401. var wire uint64
  3402. for shift := uint(0); ; shift += 7 {
  3403. if shift >= 64 {
  3404. return ErrIntOverflowGenerated
  3405. }
  3406. if iNdEx >= l {
  3407. return io.ErrUnexpectedEOF
  3408. }
  3409. b := dAtA[iNdEx]
  3410. iNdEx++
  3411. wire |= (uint64(b) & 0x7F) << shift
  3412. if b < 0x80 {
  3413. break
  3414. }
  3415. }
  3416. fieldNum := int32(wire >> 3)
  3417. wireType := int(wire & 0x7)
  3418. if wireType == 4 {
  3419. return fmt.Errorf("proto: ObjectMetricSource: wiretype end group for non-group")
  3420. }
  3421. if fieldNum <= 0 {
  3422. return fmt.Errorf("proto: ObjectMetricSource: illegal tag %d (wire type %d)", fieldNum, wire)
  3423. }
  3424. switch fieldNum {
  3425. case 1:
  3426. if wireType != 2 {
  3427. return fmt.Errorf("proto: wrong wireType = %d for field DescribedObject", wireType)
  3428. }
  3429. var msglen int
  3430. for shift := uint(0); ; shift += 7 {
  3431. if shift >= 64 {
  3432. return ErrIntOverflowGenerated
  3433. }
  3434. if iNdEx >= l {
  3435. return io.ErrUnexpectedEOF
  3436. }
  3437. b := dAtA[iNdEx]
  3438. iNdEx++
  3439. msglen |= (int(b) & 0x7F) << shift
  3440. if b < 0x80 {
  3441. break
  3442. }
  3443. }
  3444. if msglen < 0 {
  3445. return ErrInvalidLengthGenerated
  3446. }
  3447. postIndex := iNdEx + msglen
  3448. if postIndex > l {
  3449. return io.ErrUnexpectedEOF
  3450. }
  3451. if err := m.DescribedObject.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3452. return err
  3453. }
  3454. iNdEx = postIndex
  3455. case 2:
  3456. if wireType != 2 {
  3457. return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType)
  3458. }
  3459. var msglen int
  3460. for shift := uint(0); ; shift += 7 {
  3461. if shift >= 64 {
  3462. return ErrIntOverflowGenerated
  3463. }
  3464. if iNdEx >= l {
  3465. return io.ErrUnexpectedEOF
  3466. }
  3467. b := dAtA[iNdEx]
  3468. iNdEx++
  3469. msglen |= (int(b) & 0x7F) << shift
  3470. if b < 0x80 {
  3471. break
  3472. }
  3473. }
  3474. if msglen < 0 {
  3475. return ErrInvalidLengthGenerated
  3476. }
  3477. postIndex := iNdEx + msglen
  3478. if postIndex > l {
  3479. return io.ErrUnexpectedEOF
  3480. }
  3481. if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3482. return err
  3483. }
  3484. iNdEx = postIndex
  3485. case 3:
  3486. if wireType != 2 {
  3487. return fmt.Errorf("proto: wrong wireType = %d for field Metric", wireType)
  3488. }
  3489. var msglen int
  3490. for shift := uint(0); ; shift += 7 {
  3491. if shift >= 64 {
  3492. return ErrIntOverflowGenerated
  3493. }
  3494. if iNdEx >= l {
  3495. return io.ErrUnexpectedEOF
  3496. }
  3497. b := dAtA[iNdEx]
  3498. iNdEx++
  3499. msglen |= (int(b) & 0x7F) << shift
  3500. if b < 0x80 {
  3501. break
  3502. }
  3503. }
  3504. if msglen < 0 {
  3505. return ErrInvalidLengthGenerated
  3506. }
  3507. postIndex := iNdEx + msglen
  3508. if postIndex > l {
  3509. return io.ErrUnexpectedEOF
  3510. }
  3511. if err := m.Metric.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3512. return err
  3513. }
  3514. iNdEx = postIndex
  3515. default:
  3516. iNdEx = preIndex
  3517. skippy, err := skipGenerated(dAtA[iNdEx:])
  3518. if err != nil {
  3519. return err
  3520. }
  3521. if skippy < 0 {
  3522. return ErrInvalidLengthGenerated
  3523. }
  3524. if (iNdEx + skippy) > l {
  3525. return io.ErrUnexpectedEOF
  3526. }
  3527. iNdEx += skippy
  3528. }
  3529. }
  3530. if iNdEx > l {
  3531. return io.ErrUnexpectedEOF
  3532. }
  3533. return nil
  3534. }
  3535. func (m *ObjectMetricStatus) Unmarshal(dAtA []byte) error {
  3536. l := len(dAtA)
  3537. iNdEx := 0
  3538. for iNdEx < l {
  3539. preIndex := iNdEx
  3540. var wire uint64
  3541. for shift := uint(0); ; shift += 7 {
  3542. if shift >= 64 {
  3543. return ErrIntOverflowGenerated
  3544. }
  3545. if iNdEx >= l {
  3546. return io.ErrUnexpectedEOF
  3547. }
  3548. b := dAtA[iNdEx]
  3549. iNdEx++
  3550. wire |= (uint64(b) & 0x7F) << shift
  3551. if b < 0x80 {
  3552. break
  3553. }
  3554. }
  3555. fieldNum := int32(wire >> 3)
  3556. wireType := int(wire & 0x7)
  3557. if wireType == 4 {
  3558. return fmt.Errorf("proto: ObjectMetricStatus: wiretype end group for non-group")
  3559. }
  3560. if fieldNum <= 0 {
  3561. return fmt.Errorf("proto: ObjectMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire)
  3562. }
  3563. switch fieldNum {
  3564. case 1:
  3565. if wireType != 2 {
  3566. return fmt.Errorf("proto: wrong wireType = %d for field Metric", wireType)
  3567. }
  3568. var msglen int
  3569. for shift := uint(0); ; shift += 7 {
  3570. if shift >= 64 {
  3571. return ErrIntOverflowGenerated
  3572. }
  3573. if iNdEx >= l {
  3574. return io.ErrUnexpectedEOF
  3575. }
  3576. b := dAtA[iNdEx]
  3577. iNdEx++
  3578. msglen |= (int(b) & 0x7F) << shift
  3579. if b < 0x80 {
  3580. break
  3581. }
  3582. }
  3583. if msglen < 0 {
  3584. return ErrInvalidLengthGenerated
  3585. }
  3586. postIndex := iNdEx + msglen
  3587. if postIndex > l {
  3588. return io.ErrUnexpectedEOF
  3589. }
  3590. if err := m.Metric.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3591. return err
  3592. }
  3593. iNdEx = postIndex
  3594. case 2:
  3595. if wireType != 2 {
  3596. return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
  3597. }
  3598. var msglen int
  3599. for shift := uint(0); ; shift += 7 {
  3600. if shift >= 64 {
  3601. return ErrIntOverflowGenerated
  3602. }
  3603. if iNdEx >= l {
  3604. return io.ErrUnexpectedEOF
  3605. }
  3606. b := dAtA[iNdEx]
  3607. iNdEx++
  3608. msglen |= (int(b) & 0x7F) << shift
  3609. if b < 0x80 {
  3610. break
  3611. }
  3612. }
  3613. if msglen < 0 {
  3614. return ErrInvalidLengthGenerated
  3615. }
  3616. postIndex := iNdEx + msglen
  3617. if postIndex > l {
  3618. return io.ErrUnexpectedEOF
  3619. }
  3620. if err := m.Current.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3621. return err
  3622. }
  3623. iNdEx = postIndex
  3624. case 3:
  3625. if wireType != 2 {
  3626. return fmt.Errorf("proto: wrong wireType = %d for field DescribedObject", wireType)
  3627. }
  3628. var msglen int
  3629. for shift := uint(0); ; shift += 7 {
  3630. if shift >= 64 {
  3631. return ErrIntOverflowGenerated
  3632. }
  3633. if iNdEx >= l {
  3634. return io.ErrUnexpectedEOF
  3635. }
  3636. b := dAtA[iNdEx]
  3637. iNdEx++
  3638. msglen |= (int(b) & 0x7F) << shift
  3639. if b < 0x80 {
  3640. break
  3641. }
  3642. }
  3643. if msglen < 0 {
  3644. return ErrInvalidLengthGenerated
  3645. }
  3646. postIndex := iNdEx + msglen
  3647. if postIndex > l {
  3648. return io.ErrUnexpectedEOF
  3649. }
  3650. if err := m.DescribedObject.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3651. return err
  3652. }
  3653. iNdEx = postIndex
  3654. default:
  3655. iNdEx = preIndex
  3656. skippy, err := skipGenerated(dAtA[iNdEx:])
  3657. if err != nil {
  3658. return err
  3659. }
  3660. if skippy < 0 {
  3661. return ErrInvalidLengthGenerated
  3662. }
  3663. if (iNdEx + skippy) > l {
  3664. return io.ErrUnexpectedEOF
  3665. }
  3666. iNdEx += skippy
  3667. }
  3668. }
  3669. if iNdEx > l {
  3670. return io.ErrUnexpectedEOF
  3671. }
  3672. return nil
  3673. }
  3674. func (m *PodsMetricSource) Unmarshal(dAtA []byte) error {
  3675. l := len(dAtA)
  3676. iNdEx := 0
  3677. for iNdEx < l {
  3678. preIndex := iNdEx
  3679. var wire uint64
  3680. for shift := uint(0); ; shift += 7 {
  3681. if shift >= 64 {
  3682. return ErrIntOverflowGenerated
  3683. }
  3684. if iNdEx >= l {
  3685. return io.ErrUnexpectedEOF
  3686. }
  3687. b := dAtA[iNdEx]
  3688. iNdEx++
  3689. wire |= (uint64(b) & 0x7F) << shift
  3690. if b < 0x80 {
  3691. break
  3692. }
  3693. }
  3694. fieldNum := int32(wire >> 3)
  3695. wireType := int(wire & 0x7)
  3696. if wireType == 4 {
  3697. return fmt.Errorf("proto: PodsMetricSource: wiretype end group for non-group")
  3698. }
  3699. if fieldNum <= 0 {
  3700. return fmt.Errorf("proto: PodsMetricSource: illegal tag %d (wire type %d)", fieldNum, wire)
  3701. }
  3702. switch fieldNum {
  3703. case 1:
  3704. if wireType != 2 {
  3705. return fmt.Errorf("proto: wrong wireType = %d for field Metric", wireType)
  3706. }
  3707. var msglen int
  3708. for shift := uint(0); ; shift += 7 {
  3709. if shift >= 64 {
  3710. return ErrIntOverflowGenerated
  3711. }
  3712. if iNdEx >= l {
  3713. return io.ErrUnexpectedEOF
  3714. }
  3715. b := dAtA[iNdEx]
  3716. iNdEx++
  3717. msglen |= (int(b) & 0x7F) << shift
  3718. if b < 0x80 {
  3719. break
  3720. }
  3721. }
  3722. if msglen < 0 {
  3723. return ErrInvalidLengthGenerated
  3724. }
  3725. postIndex := iNdEx + msglen
  3726. if postIndex > l {
  3727. return io.ErrUnexpectedEOF
  3728. }
  3729. if err := m.Metric.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3730. return err
  3731. }
  3732. iNdEx = postIndex
  3733. case 2:
  3734. if wireType != 2 {
  3735. return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType)
  3736. }
  3737. var msglen int
  3738. for shift := uint(0); ; shift += 7 {
  3739. if shift >= 64 {
  3740. return ErrIntOverflowGenerated
  3741. }
  3742. if iNdEx >= l {
  3743. return io.ErrUnexpectedEOF
  3744. }
  3745. b := dAtA[iNdEx]
  3746. iNdEx++
  3747. msglen |= (int(b) & 0x7F) << shift
  3748. if b < 0x80 {
  3749. break
  3750. }
  3751. }
  3752. if msglen < 0 {
  3753. return ErrInvalidLengthGenerated
  3754. }
  3755. postIndex := iNdEx + msglen
  3756. if postIndex > l {
  3757. return io.ErrUnexpectedEOF
  3758. }
  3759. if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3760. return err
  3761. }
  3762. iNdEx = postIndex
  3763. default:
  3764. iNdEx = preIndex
  3765. skippy, err := skipGenerated(dAtA[iNdEx:])
  3766. if err != nil {
  3767. return err
  3768. }
  3769. if skippy < 0 {
  3770. return ErrInvalidLengthGenerated
  3771. }
  3772. if (iNdEx + skippy) > l {
  3773. return io.ErrUnexpectedEOF
  3774. }
  3775. iNdEx += skippy
  3776. }
  3777. }
  3778. if iNdEx > l {
  3779. return io.ErrUnexpectedEOF
  3780. }
  3781. return nil
  3782. }
  3783. func (m *PodsMetricStatus) Unmarshal(dAtA []byte) error {
  3784. l := len(dAtA)
  3785. iNdEx := 0
  3786. for iNdEx < l {
  3787. preIndex := iNdEx
  3788. var wire uint64
  3789. for shift := uint(0); ; shift += 7 {
  3790. if shift >= 64 {
  3791. return ErrIntOverflowGenerated
  3792. }
  3793. if iNdEx >= l {
  3794. return io.ErrUnexpectedEOF
  3795. }
  3796. b := dAtA[iNdEx]
  3797. iNdEx++
  3798. wire |= (uint64(b) & 0x7F) << shift
  3799. if b < 0x80 {
  3800. break
  3801. }
  3802. }
  3803. fieldNum := int32(wire >> 3)
  3804. wireType := int(wire & 0x7)
  3805. if wireType == 4 {
  3806. return fmt.Errorf("proto: PodsMetricStatus: wiretype end group for non-group")
  3807. }
  3808. if fieldNum <= 0 {
  3809. return fmt.Errorf("proto: PodsMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire)
  3810. }
  3811. switch fieldNum {
  3812. case 1:
  3813. if wireType != 2 {
  3814. return fmt.Errorf("proto: wrong wireType = %d for field Metric", wireType)
  3815. }
  3816. var msglen int
  3817. for shift := uint(0); ; shift += 7 {
  3818. if shift >= 64 {
  3819. return ErrIntOverflowGenerated
  3820. }
  3821. if iNdEx >= l {
  3822. return io.ErrUnexpectedEOF
  3823. }
  3824. b := dAtA[iNdEx]
  3825. iNdEx++
  3826. msglen |= (int(b) & 0x7F) << shift
  3827. if b < 0x80 {
  3828. break
  3829. }
  3830. }
  3831. if msglen < 0 {
  3832. return ErrInvalidLengthGenerated
  3833. }
  3834. postIndex := iNdEx + msglen
  3835. if postIndex > l {
  3836. return io.ErrUnexpectedEOF
  3837. }
  3838. if err := m.Metric.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3839. return err
  3840. }
  3841. iNdEx = postIndex
  3842. case 2:
  3843. if wireType != 2 {
  3844. return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
  3845. }
  3846. var msglen int
  3847. for shift := uint(0); ; shift += 7 {
  3848. if shift >= 64 {
  3849. return ErrIntOverflowGenerated
  3850. }
  3851. if iNdEx >= l {
  3852. return io.ErrUnexpectedEOF
  3853. }
  3854. b := dAtA[iNdEx]
  3855. iNdEx++
  3856. msglen |= (int(b) & 0x7F) << shift
  3857. if b < 0x80 {
  3858. break
  3859. }
  3860. }
  3861. if msglen < 0 {
  3862. return ErrInvalidLengthGenerated
  3863. }
  3864. postIndex := iNdEx + msglen
  3865. if postIndex > l {
  3866. return io.ErrUnexpectedEOF
  3867. }
  3868. if err := m.Current.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3869. return err
  3870. }
  3871. iNdEx = postIndex
  3872. default:
  3873. iNdEx = preIndex
  3874. skippy, err := skipGenerated(dAtA[iNdEx:])
  3875. if err != nil {
  3876. return err
  3877. }
  3878. if skippy < 0 {
  3879. return ErrInvalidLengthGenerated
  3880. }
  3881. if (iNdEx + skippy) > l {
  3882. return io.ErrUnexpectedEOF
  3883. }
  3884. iNdEx += skippy
  3885. }
  3886. }
  3887. if iNdEx > l {
  3888. return io.ErrUnexpectedEOF
  3889. }
  3890. return nil
  3891. }
  3892. func (m *ResourceMetricSource) Unmarshal(dAtA []byte) error {
  3893. l := len(dAtA)
  3894. iNdEx := 0
  3895. for iNdEx < l {
  3896. preIndex := iNdEx
  3897. var wire uint64
  3898. for shift := uint(0); ; shift += 7 {
  3899. if shift >= 64 {
  3900. return ErrIntOverflowGenerated
  3901. }
  3902. if iNdEx >= l {
  3903. return io.ErrUnexpectedEOF
  3904. }
  3905. b := dAtA[iNdEx]
  3906. iNdEx++
  3907. wire |= (uint64(b) & 0x7F) << shift
  3908. if b < 0x80 {
  3909. break
  3910. }
  3911. }
  3912. fieldNum := int32(wire >> 3)
  3913. wireType := int(wire & 0x7)
  3914. if wireType == 4 {
  3915. return fmt.Errorf("proto: ResourceMetricSource: wiretype end group for non-group")
  3916. }
  3917. if fieldNum <= 0 {
  3918. return fmt.Errorf("proto: ResourceMetricSource: illegal tag %d (wire type %d)", fieldNum, wire)
  3919. }
  3920. switch fieldNum {
  3921. case 1:
  3922. if wireType != 2 {
  3923. return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
  3924. }
  3925. var stringLen uint64
  3926. for shift := uint(0); ; shift += 7 {
  3927. if shift >= 64 {
  3928. return ErrIntOverflowGenerated
  3929. }
  3930. if iNdEx >= l {
  3931. return io.ErrUnexpectedEOF
  3932. }
  3933. b := dAtA[iNdEx]
  3934. iNdEx++
  3935. stringLen |= (uint64(b) & 0x7F) << shift
  3936. if b < 0x80 {
  3937. break
  3938. }
  3939. }
  3940. intStringLen := int(stringLen)
  3941. if intStringLen < 0 {
  3942. return ErrInvalidLengthGenerated
  3943. }
  3944. postIndex := iNdEx + intStringLen
  3945. if postIndex > l {
  3946. return io.ErrUnexpectedEOF
  3947. }
  3948. m.Name = k8s_io_api_core_v1.ResourceName(dAtA[iNdEx:postIndex])
  3949. iNdEx = postIndex
  3950. case 2:
  3951. if wireType != 2 {
  3952. return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType)
  3953. }
  3954. var msglen int
  3955. for shift := uint(0); ; shift += 7 {
  3956. if shift >= 64 {
  3957. return ErrIntOverflowGenerated
  3958. }
  3959. if iNdEx >= l {
  3960. return io.ErrUnexpectedEOF
  3961. }
  3962. b := dAtA[iNdEx]
  3963. iNdEx++
  3964. msglen |= (int(b) & 0x7F) << shift
  3965. if b < 0x80 {
  3966. break
  3967. }
  3968. }
  3969. if msglen < 0 {
  3970. return ErrInvalidLengthGenerated
  3971. }
  3972. postIndex := iNdEx + msglen
  3973. if postIndex > l {
  3974. return io.ErrUnexpectedEOF
  3975. }
  3976. if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  3977. return err
  3978. }
  3979. iNdEx = postIndex
  3980. default:
  3981. iNdEx = preIndex
  3982. skippy, err := skipGenerated(dAtA[iNdEx:])
  3983. if err != nil {
  3984. return err
  3985. }
  3986. if skippy < 0 {
  3987. return ErrInvalidLengthGenerated
  3988. }
  3989. if (iNdEx + skippy) > l {
  3990. return io.ErrUnexpectedEOF
  3991. }
  3992. iNdEx += skippy
  3993. }
  3994. }
  3995. if iNdEx > l {
  3996. return io.ErrUnexpectedEOF
  3997. }
  3998. return nil
  3999. }
  4000. func (m *ResourceMetricStatus) Unmarshal(dAtA []byte) error {
  4001. l := len(dAtA)
  4002. iNdEx := 0
  4003. for iNdEx < l {
  4004. preIndex := iNdEx
  4005. var wire uint64
  4006. for shift := uint(0); ; shift += 7 {
  4007. if shift >= 64 {
  4008. return ErrIntOverflowGenerated
  4009. }
  4010. if iNdEx >= l {
  4011. return io.ErrUnexpectedEOF
  4012. }
  4013. b := dAtA[iNdEx]
  4014. iNdEx++
  4015. wire |= (uint64(b) & 0x7F) << shift
  4016. if b < 0x80 {
  4017. break
  4018. }
  4019. }
  4020. fieldNum := int32(wire >> 3)
  4021. wireType := int(wire & 0x7)
  4022. if wireType == 4 {
  4023. return fmt.Errorf("proto: ResourceMetricStatus: wiretype end group for non-group")
  4024. }
  4025. if fieldNum <= 0 {
  4026. return fmt.Errorf("proto: ResourceMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire)
  4027. }
  4028. switch fieldNum {
  4029. case 1:
  4030. if wireType != 2 {
  4031. return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
  4032. }
  4033. var stringLen uint64
  4034. for shift := uint(0); ; shift += 7 {
  4035. if shift >= 64 {
  4036. return ErrIntOverflowGenerated
  4037. }
  4038. if iNdEx >= l {
  4039. return io.ErrUnexpectedEOF
  4040. }
  4041. b := dAtA[iNdEx]
  4042. iNdEx++
  4043. stringLen |= (uint64(b) & 0x7F) << shift
  4044. if b < 0x80 {
  4045. break
  4046. }
  4047. }
  4048. intStringLen := int(stringLen)
  4049. if intStringLen < 0 {
  4050. return ErrInvalidLengthGenerated
  4051. }
  4052. postIndex := iNdEx + intStringLen
  4053. if postIndex > l {
  4054. return io.ErrUnexpectedEOF
  4055. }
  4056. m.Name = k8s_io_api_core_v1.ResourceName(dAtA[iNdEx:postIndex])
  4057. iNdEx = postIndex
  4058. case 2:
  4059. if wireType != 2 {
  4060. return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
  4061. }
  4062. var msglen int
  4063. for shift := uint(0); ; shift += 7 {
  4064. if shift >= 64 {
  4065. return ErrIntOverflowGenerated
  4066. }
  4067. if iNdEx >= l {
  4068. return io.ErrUnexpectedEOF
  4069. }
  4070. b := dAtA[iNdEx]
  4071. iNdEx++
  4072. msglen |= (int(b) & 0x7F) << shift
  4073. if b < 0x80 {
  4074. break
  4075. }
  4076. }
  4077. if msglen < 0 {
  4078. return ErrInvalidLengthGenerated
  4079. }
  4080. postIndex := iNdEx + msglen
  4081. if postIndex > l {
  4082. return io.ErrUnexpectedEOF
  4083. }
  4084. if err := m.Current.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  4085. return err
  4086. }
  4087. iNdEx = postIndex
  4088. default:
  4089. iNdEx = preIndex
  4090. skippy, err := skipGenerated(dAtA[iNdEx:])
  4091. if err != nil {
  4092. return err
  4093. }
  4094. if skippy < 0 {
  4095. return ErrInvalidLengthGenerated
  4096. }
  4097. if (iNdEx + skippy) > l {
  4098. return io.ErrUnexpectedEOF
  4099. }
  4100. iNdEx += skippy
  4101. }
  4102. }
  4103. if iNdEx > l {
  4104. return io.ErrUnexpectedEOF
  4105. }
  4106. return nil
  4107. }
  4108. func skipGenerated(dAtA []byte) (n int, err error) {
  4109. l := len(dAtA)
  4110. iNdEx := 0
  4111. for iNdEx < l {
  4112. var wire uint64
  4113. for shift := uint(0); ; shift += 7 {
  4114. if shift >= 64 {
  4115. return 0, ErrIntOverflowGenerated
  4116. }
  4117. if iNdEx >= l {
  4118. return 0, io.ErrUnexpectedEOF
  4119. }
  4120. b := dAtA[iNdEx]
  4121. iNdEx++
  4122. wire |= (uint64(b) & 0x7F) << shift
  4123. if b < 0x80 {
  4124. break
  4125. }
  4126. }
  4127. wireType := int(wire & 0x7)
  4128. switch wireType {
  4129. case 0:
  4130. for shift := uint(0); ; shift += 7 {
  4131. if shift >= 64 {
  4132. return 0, ErrIntOverflowGenerated
  4133. }
  4134. if iNdEx >= l {
  4135. return 0, io.ErrUnexpectedEOF
  4136. }
  4137. iNdEx++
  4138. if dAtA[iNdEx-1] < 0x80 {
  4139. break
  4140. }
  4141. }
  4142. return iNdEx, nil
  4143. case 1:
  4144. iNdEx += 8
  4145. return iNdEx, nil
  4146. case 2:
  4147. var length int
  4148. for shift := uint(0); ; shift += 7 {
  4149. if shift >= 64 {
  4150. return 0, ErrIntOverflowGenerated
  4151. }
  4152. if iNdEx >= l {
  4153. return 0, io.ErrUnexpectedEOF
  4154. }
  4155. b := dAtA[iNdEx]
  4156. iNdEx++
  4157. length |= (int(b) & 0x7F) << shift
  4158. if b < 0x80 {
  4159. break
  4160. }
  4161. }
  4162. iNdEx += length
  4163. if length < 0 {
  4164. return 0, ErrInvalidLengthGenerated
  4165. }
  4166. return iNdEx, nil
  4167. case 3:
  4168. for {
  4169. var innerWire uint64
  4170. var start int = iNdEx
  4171. for shift := uint(0); ; shift += 7 {
  4172. if shift >= 64 {
  4173. return 0, ErrIntOverflowGenerated
  4174. }
  4175. if iNdEx >= l {
  4176. return 0, io.ErrUnexpectedEOF
  4177. }
  4178. b := dAtA[iNdEx]
  4179. iNdEx++
  4180. innerWire |= (uint64(b) & 0x7F) << shift
  4181. if b < 0x80 {
  4182. break
  4183. }
  4184. }
  4185. innerWireType := int(innerWire & 0x7)
  4186. if innerWireType == 4 {
  4187. break
  4188. }
  4189. next, err := skipGenerated(dAtA[start:])
  4190. if err != nil {
  4191. return 0, err
  4192. }
  4193. iNdEx = start + next
  4194. }
  4195. return iNdEx, nil
  4196. case 4:
  4197. return iNdEx, nil
  4198. case 5:
  4199. iNdEx += 4
  4200. return iNdEx, nil
  4201. default:
  4202. return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
  4203. }
  4204. }
  4205. panic("unreachable")
  4206. }
  4207. var (
  4208. ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling")
  4209. ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow")
  4210. )
  4211. func init() {
  4212. proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/api/autoscaling/v2beta2/generated.proto", fileDescriptorGenerated)
  4213. }
  4214. var fileDescriptorGenerated = []byte{
  4215. // 1425 bytes of a gzipped FileDescriptorProto
  4216. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x58, 0xdd, 0x6f, 0x1b, 0xc5,
  4217. 0x16, 0xcf, 0xda, 0x8e, 0x93, 0x8e, 0xd3, 0x24, 0x9d, 0x5b, 0xb5, 0x56, 0xaa, 0x6b, 0x47, 0xab,
  4218. 0xab, 0xab, 0x52, 0xd1, 0x35, 0x31, 0xe1, 0x43, 0x42, 0x48, 0xc4, 0x01, 0xda, 0x8a, 0xa4, 0x2d,
  4219. 0x93, 0xb4, 0x42, 0xa8, 0x45, 0x8c, 0x77, 0x4f, 0xdc, 0x21, 0xde, 0x5d, 0x6b, 0x76, 0x6c, 0x35,
  4220. 0x45, 0x42, 0xbc, 0xf0, 0x8e, 0x40, 0xfc, 0x13, 0x88, 0x17, 0x5e, 0x90, 0x78, 0xe4, 0x43, 0xa8,
  4221. 0x42, 0x08, 0xf5, 0xb1, 0x08, 0xc9, 0xa2, 0xe6, 0xbf, 0xe8, 0x13, 0xda, 0x99, 0xd9, 0xf5, 0xae,
  4222. 0xed, 0xc4, 0x4e, 0x95, 0x14, 0xf5, 0xcd, 0x33, 0xe7, 0x9c, 0xdf, 0xf9, 0x9c, 0x73, 0xce, 0x1a,
  4223. 0x5d, 0xda, 0x7d, 0x35, 0xb0, 0x98, 0x5f, 0xd9, 0x6d, 0xd7, 0x81, 0x7b, 0x20, 0x20, 0xa8, 0x74,
  4224. 0xc0, 0x73, 0x7c, 0x5e, 0xd1, 0x04, 0xda, 0x62, 0x15, 0xda, 0x16, 0x7e, 0x60, 0xd3, 0x26, 0xf3,
  4225. 0x1a, 0x95, 0x4e, 0xb5, 0x0e, 0x82, 0x56, 0x2b, 0x0d, 0xf0, 0x80, 0x53, 0x01, 0x8e, 0xd5, 0xe2,
  4226. 0xbe, 0xf0, 0x71, 0x49, 0xf1, 0x5b, 0xb4, 0xc5, 0xac, 0x04, 0xbf, 0xa5, 0xf9, 0x97, 0x2e, 0x36,
  4227. 0x98, 0xb8, 0xd3, 0xae, 0x5b, 0xb6, 0xef, 0x56, 0x1a, 0x7e, 0xc3, 0xaf, 0x48, 0xb1, 0x7a, 0x7b,
  4228. 0x47, 0x9e, 0xe4, 0x41, 0xfe, 0x52, 0x70, 0x4b, 0x66, 0x42, 0xbd, 0xed, 0x73, 0xa8, 0x74, 0x56,
  4229. 0x06, 0x55, 0x2e, 0xad, 0xf6, 0x79, 0x5c, 0x6a, 0xdf, 0x61, 0x1e, 0xf0, 0xbd, 0x4a, 0x6b, 0xb7,
  4230. 0x21, 0x85, 0x38, 0x04, 0x7e, 0x9b, 0xdb, 0x70, 0x28, 0xa9, 0xa0, 0xe2, 0x82, 0xa0, 0xa3, 0x74,
  4231. 0x55, 0xf6, 0x93, 0xe2, 0x6d, 0x4f, 0x30, 0x77, 0x58, 0xcd, 0xcb, 0xe3, 0x04, 0x02, 0xfb, 0x0e,
  4232. 0xb8, 0x74, 0x50, 0xce, 0xfc, 0xca, 0x40, 0xe7, 0xd6, 0xb9, 0x1f, 0x04, 0x37, 0x81, 0x07, 0xcc,
  4233. 0xf7, 0xae, 0xd5, 0x3f, 0x02, 0x5b, 0x10, 0xd8, 0x01, 0x0e, 0x9e, 0x0d, 0x78, 0x19, 0xe5, 0x76,
  4234. 0x99, 0xe7, 0x14, 0x8d, 0x65, 0xe3, 0xfc, 0x89, 0xda, 0xdc, 0xfd, 0x6e, 0x79, 0xaa, 0xd7, 0x2d,
  4235. 0xe7, 0xde, 0x61, 0x9e, 0x43, 0x24, 0x25, 0xe4, 0xf0, 0xa8, 0x0b, 0xc5, 0x4c, 0x9a, 0xe3, 0x2a,
  4236. 0x75, 0x81, 0x48, 0x0a, 0xae, 0x22, 0x44, 0x5b, 0x4c, 0x2b, 0x28, 0x66, 0x25, 0x1f, 0xd6, 0x7c,
  4237. 0x68, 0xed, 0xfa, 0x15, 0x4d, 0x21, 0x09, 0x2e, 0xf3, 0x17, 0x03, 0x9d, 0x7e, 0xeb, 0xae, 0x00,
  4238. 0xee, 0xd1, 0xe6, 0x26, 0x08, 0xce, 0xec, 0x2d, 0x19, 0x5f, 0xfc, 0x1e, 0xca, 0xbb, 0xf2, 0x2c,
  4239. 0x4d, 0x2a, 0x54, 0x5f, 0xb0, 0x0e, 0xae, 0x04, 0x4b, 0x49, 0x5f, 0x71, 0xc0, 0x13, 0x6c, 0x87,
  4240. 0x01, 0xaf, 0xcd, 0x6b, 0xd5, 0x79, 0x45, 0x21, 0x1a, 0x0f, 0x6f, 0xa3, 0xbc, 0xa0, 0xbc, 0x01,
  4241. 0x42, 0xba, 0x52, 0xa8, 0x3e, 0x3f, 0x19, 0xf2, 0xb6, 0x94, 0xe9, 0xa3, 0xaa, 0x33, 0xd1, 0x58,
  4242. 0xe6, 0xef, 0xc3, 0x8e, 0x08, 0x2a, 0xda, 0xc1, 0x31, 0x3a, 0x72, 0x0b, 0xcd, 0xd8, 0x6d, 0xce,
  4243. 0xc1, 0x8b, 0x3c, 0x59, 0x99, 0x0c, 0xfa, 0x26, 0x6d, 0xb6, 0x41, 0x59, 0x57, 0x5b, 0xd0, 0xd8,
  4244. 0x33, 0xeb, 0x0a, 0x89, 0x44, 0x90, 0xe6, 0x0f, 0x19, 0x74, 0xf6, 0xb2, 0xcf, 0xd9, 0x3d, 0xdf,
  4245. 0x13, 0xb4, 0x79, 0xdd, 0x77, 0xd6, 0x34, 0x20, 0x70, 0xfc, 0x21, 0x9a, 0x0d, 0x2b, 0xda, 0xa1,
  4246. 0x82, 0x8e, 0xf0, 0x2a, 0x2e, 0x4c, 0xab, 0xb5, 0xdb, 0x08, 0x2f, 0x02, 0x2b, 0xe4, 0xb6, 0x3a,
  4247. 0x2b, 0x96, 0x2a, 0xbb, 0x4d, 0x10, 0xb4, 0x5f, 0x19, 0xfd, 0x3b, 0x12, 0xa3, 0xe2, 0xdb, 0x28,
  4248. 0x17, 0xb4, 0xc0, 0xd6, 0x8e, 0xbd, 0x36, 0xce, 0xb1, 0x7d, 0x0c, 0xdd, 0x6a, 0x81, 0xdd, 0x2f,
  4249. 0xd5, 0xf0, 0x44, 0x24, 0x2c, 0x06, 0x94, 0x0f, 0x64, 0x00, 0x64, 0x99, 0x16, 0xaa, 0xaf, 0x3f,
  4250. 0xa9, 0x02, 0x15, 0xc5, 0x38, 0x43, 0xea, 0x4c, 0x34, 0xb8, 0xf9, 0x59, 0x16, 0x2d, 0xef, 0x23,
  4251. 0xb9, 0xee, 0x7b, 0x0e, 0x13, 0xcc, 0xf7, 0xf0, 0x65, 0x94, 0x13, 0x7b, 0x2d, 0xd0, 0x4f, 0x6f,
  4252. 0x35, 0xb2, 0x76, 0x7b, 0xaf, 0x05, 0x8f, 0xbb, 0xe5, 0xff, 0x8d, 0x93, 0x0f, 0xf9, 0x88, 0x44,
  4253. 0xc0, 0x1b, 0xb1, 0x57, 0x99, 0x14, 0x96, 0x36, 0xeb, 0x71, 0xb7, 0x3c, 0xa2, 0xff, 0x59, 0x31,
  4254. 0x52, 0xda, 0x78, 0xdc, 0x41, 0xb8, 0x49, 0x03, 0xb1, 0xcd, 0xa9, 0x17, 0x28, 0x4d, 0xcc, 0x05,
  4255. 0x1d, 0xaf, 0x0b, 0x93, 0xa5, 0x3b, 0x94, 0xa8, 0x2d, 0x69, 0x2b, 0xf0, 0xc6, 0x10, 0x1a, 0x19,
  4256. 0xa1, 0x01, 0xff, 0x1f, 0xe5, 0x39, 0xd0, 0xc0, 0xf7, 0x8a, 0x39, 0xe9, 0x45, 0x1c, 0x5c, 0x22,
  4257. 0x6f, 0x89, 0xa6, 0xe2, 0xe7, 0xd0, 0x8c, 0x0b, 0x41, 0x40, 0x1b, 0x50, 0x9c, 0x96, 0x8c, 0x71,
  4258. 0x2d, 0x6f, 0xaa, 0x6b, 0x12, 0xd1, 0xcd, 0x3f, 0x0c, 0x74, 0x6e, 0x9f, 0x38, 0x6e, 0xb0, 0x40,
  4259. 0xe0, 0x5b, 0x43, 0xf5, 0x6c, 0x4d, 0xe6, 0x60, 0x28, 0x2d, 0xab, 0x79, 0x51, 0xeb, 0x9e, 0x8d,
  4260. 0x6e, 0x12, 0xb5, 0x7c, 0x0b, 0x4d, 0x33, 0x01, 0x6e, 0x98, 0x95, 0xec, 0xf9, 0x42, 0xf5, 0x95,
  4261. 0x27, 0xac, 0xb5, 0xda, 0x49, 0xad, 0x63, 0xfa, 0x4a, 0x88, 0x46, 0x14, 0xa8, 0xf9, 0x67, 0x66,
  4262. 0x5f, 0xdf, 0xc2, 0x82, 0xc7, 0x1f, 0xa3, 0x79, 0x79, 0xd2, 0xfd, 0x0a, 0x76, 0xb4, 0x87, 0x63,
  4263. 0xdf, 0xd4, 0x01, 0xe3, 0xa2, 0x76, 0x46, 0x9b, 0x32, 0xbf, 0x95, 0x82, 0x26, 0x03, 0xaa, 0xf0,
  4264. 0x0a, 0x2a, 0xb8, 0xcc, 0x23, 0xd0, 0x6a, 0x32, 0x9b, 0xaa, 0xb2, 0x9c, 0xae, 0x2d, 0xf4, 0xba,
  4265. 0xe5, 0xc2, 0x66, 0xff, 0x9a, 0x24, 0x79, 0xf0, 0x4b, 0xa8, 0xe0, 0xd2, 0xbb, 0xb1, 0x48, 0x56,
  4266. 0x8a, 0xfc, 0x47, 0xeb, 0x2b, 0x6c, 0xf6, 0x49, 0x24, 0xc9, 0x87, 0x6f, 0x84, 0xd5, 0x10, 0x76,
  4267. 0xb7, 0xa0, 0x98, 0x93, 0x61, 0xbe, 0x30, 0x59, 0x33, 0x94, 0x2d, 0x22, 0x51, 0x39, 0x12, 0x82,
  4268. 0x44, 0x58, 0xe6, 0x77, 0x39, 0xf4, 0xdf, 0x03, 0xdf, 0x3e, 0x7e, 0x1b, 0x61, 0xbf, 0x1e, 0x00,
  4269. 0xef, 0x80, 0x73, 0x49, 0x0d, 0xdd, 0x70, 0xfa, 0x85, 0x31, 0xce, 0xd6, 0xce, 0x84, 0x65, 0x7f,
  4270. 0x6d, 0x88, 0x4a, 0x46, 0x48, 0x60, 0x1b, 0x9d, 0x0c, 0x1f, 0x83, 0x0a, 0x28, 0xd3, 0x83, 0xf6,
  4271. 0x70, 0x2f, 0xed, 0x54, 0xaf, 0x5b, 0x3e, 0xb9, 0x91, 0x04, 0x21, 0x69, 0x4c, 0xbc, 0x86, 0x16,
  4272. 0x74, 0x7f, 0x1f, 0x08, 0xf0, 0x59, 0x1d, 0x81, 0x85, 0xf5, 0x34, 0x99, 0x0c, 0xf2, 0x87, 0x10,
  4273. 0x0e, 0x04, 0x8c, 0x83, 0x13, 0x43, 0xe4, 0xd2, 0x10, 0x6f, 0xa6, 0xc9, 0x64, 0x90, 0x1f, 0x37,
  4274. 0xd1, 0xbc, 0x46, 0xd5, 0xf1, 0x2e, 0x4e, 0xcb, 0x94, 0x4d, 0x38, 0x89, 0x75, 0xd3, 0x8d, 0x6b,
  4275. 0x70, 0x3d, 0x85, 0x45, 0x06, 0xb0, 0xb1, 0x40, 0xc8, 0x8e, 0x5a, 0x5c, 0x50, 0xcc, 0x4b, 0x4d,
  4276. 0x6f, 0x3c, 0xe1, 0x1b, 0x8c, 0x7b, 0x65, 0x7f, 0x7c, 0xc5, 0x57, 0x01, 0x49, 0xe8, 0x31, 0xbf,
  4277. 0x34, 0xd0, 0xe2, 0xe0, 0x24, 0x8f, 0x77, 0x28, 0x63, 0xdf, 0x1d, 0xea, 0x36, 0x9a, 0x0d, 0xa0,
  4278. 0x09, 0xb6, 0xf0, 0xb9, 0x2e, 0x80, 0x17, 0x27, 0xec, 0x44, 0xb4, 0x0e, 0xcd, 0x2d, 0x2d, 0x5a,
  4279. 0x9b, 0x0b, 0x5b, 0x51, 0x74, 0x22, 0x31, 0xa4, 0xf9, 0x75, 0x16, 0xa1, 0x7e, 0xdd, 0xe3, 0xd5,
  4280. 0xd4, 0xe8, 0x59, 0x1e, 0x18, 0x3d, 0x8b, 0xc9, 0x85, 0x2c, 0x31, 0x66, 0x6e, 0xa2, 0xbc, 0x2f,
  4281. 0xfb, 0x81, 0xb6, 0xb0, 0x3a, 0x2e, 0x98, 0xf1, 0x84, 0x8f, 0xd1, 0x6a, 0x28, 0x6c, 0xe8, 0xba,
  4282. 0xab, 0x68, 0x34, 0x7c, 0x15, 0xe5, 0x5a, 0xbe, 0x13, 0x8d, 0xe4, 0xb1, 0x7b, 0xd2, 0x75, 0xdf,
  4283. 0x09, 0x52, 0x98, 0xb3, 0xa1, 0xed, 0xe1, 0x2d, 0x91, 0x38, 0xf8, 0x03, 0x34, 0x1b, 0xad, 0xeb,
  4284. 0xb2, 0x44, 0x0b, 0xd5, 0xd5, 0x71, 0x98, 0x44, 0xf3, 0xa7, 0x70, 0x65, 0x30, 0x23, 0x0a, 0x89,
  4285. 0x31, 0x43, 0x7c, 0xd0, 0x1b, 0x9f, 0x9c, 0x40, 0x13, 0xe0, 0x8f, 0x5a, 0x75, 0x15, 0x7e, 0x44,
  4286. 0x21, 0x31, 0xa6, 0xf9, 0x4d, 0x16, 0xcd, 0xa5, 0x56, 0xc9, 0x7f, 0x23, 0x5d, 0xea, 0xad, 0x1d,
  4287. 0x6d, 0xba, 0x14, 0xe6, 0xd1, 0xa7, 0x4b, 0xe1, 0x1e, 0x5f, 0xba, 0x12, 0xf8, 0x23, 0xd2, 0xf5,
  4288. 0x53, 0x26, 0x4a, 0x97, 0x9a, 0x7f, 0x93, 0xa5, 0x4b, 0xf1, 0x26, 0xd2, 0x75, 0x0d, 0x4d, 0x77,
  4289. 0xc2, 0x05, 0x5d, 0x67, 0xeb, 0xc0, 0x45, 0xc4, 0x8a, 0x9c, 0xb3, 0xde, 0x6d, 0x53, 0x4f, 0x30,
  4290. 0xb1, 0x57, 0x3b, 0x11, 0x2e, 0x08, 0x72, 0xc3, 0x27, 0x0a, 0x07, 0x3b, 0x68, 0x8e, 0x76, 0x80,
  4291. 0xd3, 0x06, 0xc8, 0x6b, 0x9d, 0xaf, 0xc3, 0xe2, 0x2e, 0xf6, 0xba, 0xe5, 0xb9, 0xb5, 0x04, 0x0e,
  4292. 0x49, 0xa1, 0x86, 0x63, 0x50, 0x9f, 0x6f, 0x08, 0xd6, 0x64, 0xf7, 0xd4, 0x18, 0x54, 0x93, 0x41,
  4293. 0x8e, 0xc1, 0xb5, 0x21, 0x2a, 0x19, 0x21, 0x61, 0x7e, 0x91, 0x41, 0xa7, 0x86, 0x3e, 0x53, 0xfa,
  4294. 0x41, 0x31, 0x8e, 0x29, 0x28, 0x99, 0xa7, 0x18, 0x94, 0xec, 0xa1, 0x83, 0xf2, 0x73, 0x06, 0xe1,
  4295. 0xe1, 0x26, 0x8a, 0x3f, 0x91, 0xa3, 0xd8, 0xe6, 0xac, 0x0e, 0x8e, 0x22, 0x1f, 0xc5, 0x6e, 0x97,
  4296. 0x9c, 0xe3, 0x49, 0x6c, 0x32, 0xa8, 0xec, 0x78, 0xbe, 0xa4, 0x13, 0x1f, 0xcc, 0xd9, 0xa3, 0xfd,
  4297. 0x60, 0x36, 0x7f, 0x1b, 0x0c, 0xe3, 0x33, 0xfd, 0x85, 0x3e, 0x2a, 0xfd, 0xd9, 0xa7, 0x98, 0x7e,
  4298. 0xf3, 0x47, 0x03, 0x2d, 0x0e, 0x0e, 0xe1, 0x67, 0xee, 0x7f, 0x9b, 0x5f, 0xd3, 0x4e, 0x3c, 0xdb,
  4299. 0xff, 0xd9, 0x7c, 0x6b, 0xa0, 0xd3, 0xa3, 0x56, 0x18, 0xbc, 0x9e, 0x5a, 0x3c, 0x2b, 0xc9, 0xc5,
  4300. 0xf3, 0x71, 0xb7, 0x5c, 0x1e, 0xf1, 0xaf, 0x40, 0x04, 0x93, 0xd8, 0x4d, 0x8f, 0x27, 0x01, 0xdf,
  4301. 0x0f, 0xdb, 0xac, 0x92, 0x70, 0x24, 0x36, 0x1f, 0x6b, 0xbc, 0x6b, 0x17, 0xef, 0x3f, 0x2a, 0x4d,
  4302. 0x3d, 0x78, 0x54, 0x9a, 0x7a, 0xf8, 0xa8, 0x34, 0xf5, 0x69, 0xaf, 0x64, 0xdc, 0xef, 0x95, 0x8c,
  4303. 0x07, 0xbd, 0x92, 0xf1, 0xb0, 0x57, 0x32, 0xfe, 0xea, 0x95, 0x8c, 0xcf, 0xff, 0x2e, 0x4d, 0xbd,
  4304. 0x3f, 0xa3, 0xa1, 0xff, 0x09, 0x00, 0x00, 0xff, 0xff, 0x7e, 0xa0, 0xce, 0xf5, 0x16, 0x17, 0x00,
  4305. 0x00,
  4306. }