/* tslint:disable */ /* eslint-disable */ /** * Kubernetes * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: unversioned * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { exists } from '../runtime'; import { IoK8sApiFlowcontrolV1QueuingConfiguration, IoK8sApiFlowcontrolV1QueuingConfigurationFromJSON, IoK8sApiFlowcontrolV1QueuingConfigurationToJSON, } from './'; /** * LimitResponse defines how to handle requests that can not be executed right now. * @export * @interface IoK8sApiFlowcontrolV1LimitResponse */ export interface IoK8sApiFlowcontrolV1LimitResponse { /** * * @type {IoK8sApiFlowcontrolV1QueuingConfiguration} * @memberof IoK8sApiFlowcontrolV1LimitResponse */ queuing?: IoK8sApiFlowcontrolV1QueuingConfiguration; /** * `type` is "Queue" or "Reject". "Queue" means that requests that can not be executed upon arrival are held in a queue until they can be executed or a queuing limit is reached. "Reject" means that requests that can not be executed upon arrival are rejected. Required. * @type {string} * @memberof IoK8sApiFlowcontrolV1LimitResponse */ type: string; } export function IoK8sApiFlowcontrolV1LimitResponseFromJSON( json: any, ): IoK8sApiFlowcontrolV1LimitResponse { return IoK8sApiFlowcontrolV1LimitResponseFromJSONTyped(json, false); } export function IoK8sApiFlowcontrolV1LimitResponseFromJSONTyped( json: any, _ignoreDiscriminator: boolean, ): IoK8sApiFlowcontrolV1LimitResponse { if (json === undefined || json === null) { return json; } return { queuing: !exists(json, 'queuing') ? undefined : IoK8sApiFlowcontrolV1QueuingConfigurationFromJSON(json['queuing']), type: json['type'], }; } export function IoK8sApiFlowcontrolV1LimitResponseToJSON( value?: IoK8sApiFlowcontrolV1LimitResponse | null, ): any { if (value === undefined) { return undefined; } if (value === null) { return null; } return { queuing: IoK8sApiFlowcontrolV1QueuingConfigurationToJSON(value.queuing), type: value.type, }; }