import{formats}from"@kubernetes-models/validate";export const validate=function validate22(data,{instancePath="",parentData,parentDataProperty,rootData=data}={}){let vErrors=null,errors=0;if(data&&"object"==typeof data&&!Array.isArray(data)){if(void 0===data.currentReplicas){let err0={instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty:"currentReplicas"}};null===vErrors?vErrors=[err0]:vErrors.push(err0),errors++}if(void 0===data.desiredReplicas){let err1={instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty:"desiredReplicas"}};null===vErrors?vErrors=[err1]:vErrors.push(err1),errors++}void 0===data.currentCPUUtilizationPercentage||validate23(data.currentCPUUtilizationPercentage,{instancePath:instancePath+"/currentCPUUtilizationPercentage",parentData:data,parentDataProperty:"currentCPUUtilizationPercentage",rootData})||(errors=(vErrors=null===vErrors?validate23.errors:vErrors.concat(validate23.errors)).length),void 0===data.currentReplicas||validate21(data.currentReplicas,{instancePath:instancePath+"/currentReplicas",parentData:data,parentDataProperty:"currentReplicas",rootData})||(errors=(vErrors=null===vErrors?validate21.errors:vErrors.concat(validate21.errors)).length),void 0===data.desiredReplicas||validate21(data.desiredReplicas,{instancePath:instancePath+"/desiredReplicas",parentData:data,parentDataProperty:"desiredReplicas",rootData})||(errors=(vErrors=null===vErrors?validate21.errors:vErrors.concat(validate21.errors)).length),void 0===data.lastScaleTime||validate27(data.lastScaleTime,{instancePath:instancePath+"/lastScaleTime",parentData:data,parentDataProperty:"lastScaleTime",rootData})||(errors=(vErrors=null===vErrors?validate27.errors:vErrors.concat(validate27.errors)).length),void 0===data.observedGeneration||validate31(data.observedGeneration,{instancePath:instancePath+"/observedGeneration",parentData:data,parentDataProperty:"observedGeneration",rootData})||(errors=(vErrors=null===vErrors?validate31.errors:vErrors.concat(validate31.errors)).length)}else{let err2={instancePath,schemaPath:"#/type",keyword:"type",params:{type:"object"}};null===vErrors?vErrors=[err2]:vErrors.push(err2),errors++}return validate22.errors=vErrors,0===errors};let formats0=formats.int32;function validate23(data,{instancePath="",parentData,parentDataProperty,rootData=data}={}){let vErrors=null,errors=0;if(!("number"==typeof data&&!(data%1)&&!isNaN(data)&&isFinite(data))&&null!==data){let err0={instancePath,schemaPath:"#/type",keyword:"type",params:{type:"integer"}};null===vErrors?vErrors=[err0]:vErrors.push(err0),errors++}if("number"==typeof data&&isFinite(data)&&!formats0.validate(data)){let err1={instancePath,schemaPath:"#/format",keyword:"format",params:{format:"int32"}};null===vErrors?vErrors=[err1]:vErrors.push(err1),errors++}return validate23.errors=vErrors,0===errors}function validate21(data,{instancePath="",parentData,parentDataProperty,rootData=data}={}){let vErrors=null,errors=0;if(!("number"==typeof data&&!(data%1)&&!isNaN(data)&&isFinite(data))){let err0={instancePath,schemaPath:"#/type",keyword:"type",params:{type:"integer"}};null===vErrors?vErrors=[err0]:vErrors.push(err0),errors++}if("number"==typeof data&&isFinite(data)&&!formats0.validate(data)){let err1={instancePath,schemaPath:"#/format",keyword:"format",params:{format:"int32"}};null===vErrors?vErrors=[err1]:vErrors.push(err1),errors++}return validate21.errors=vErrors,0===errors}import{validate as validate28}from"@kubernetes-models/apimachinery/_schemas/IoK8sApimachineryPkgApisMetaV1Time";function validate27(data,{instancePath="",parentData,parentDataProperty,rootData=data}={}){let vErrors=null,errors=0;return null===data||validate28(data,{instancePath,parentData,parentDataProperty,rootData})||(errors=(vErrors=null===vErrors?validate28.errors:vErrors.concat(validate28.errors)).length),validate27.errors=vErrors,0===errors}let formats4=formats.int64;function validate31(data,{instancePath="",parentData,parentDataProperty,rootData=data}={}){let vErrors=null,errors=0;if(!("number"==typeof data&&!(data%1)&&!isNaN(data)&&isFinite(data))&&null!==data){let err0={instancePath,schemaPath:"#/type",keyword:"type",params:{type:"integer"}};null===vErrors?vErrors=[err0]:vErrors.push(err0),errors++}if("number"==typeof data&&isFinite(data)&&!formats4.validate(data)){let err1={instancePath,schemaPath:"#/format",keyword:"format",params:{format:"int64"}};null===vErrors?vErrors=[err1]:vErrors.push(err1),errors++}return validate31.errors=vErrors,0===errors}