UNPKG

@codingame/kubevirt-api

Version:

kubevirt OpenAPI automation for TypeScript

56 lines 2.28 kB
/* 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 { IoK8sApiResourceV1beta2DeviceSelectorFromJSON, IoK8sApiResourceV1beta2DeviceSelectorToJSON, IoK8sApiResourceV1beta2DeviceTolerationFromJSON, IoK8sApiResourceV1beta2DeviceTolerationToJSON, } from './'; export function IoK8sApiResourceV1beta2DeviceSubRequestFromJSON(json) { return IoK8sApiResourceV1beta2DeviceSubRequestFromJSONTyped(json, false); } export function IoK8sApiResourceV1beta2DeviceSubRequestFromJSONTyped(json, _ignoreDiscriminator) { if (json === undefined || json === null) { return json; } return { allocationMode: !exists(json, 'allocationMode') ? undefined : json['allocationMode'], count: !exists(json, 'count') ? undefined : json['count'], deviceClassName: json['deviceClassName'], name: json['name'], selectors: !exists(json, 'selectors') ? undefined : json['selectors'].map(IoK8sApiResourceV1beta2DeviceSelectorFromJSON), tolerations: !exists(json, 'tolerations') ? undefined : json['tolerations'].map(IoK8sApiResourceV1beta2DeviceTolerationFromJSON), }; } export function IoK8sApiResourceV1beta2DeviceSubRequestToJSON(value) { if (value === undefined) { return undefined; } if (value === null) { return null; } return { allocationMode: value.allocationMode, count: value.count, deviceClassName: value.deviceClassName, name: value.name, selectors: value.selectors === undefined ? undefined : value.selectors.map(IoK8sApiResourceV1beta2DeviceSelectorToJSON), tolerations: value.tolerations === undefined ? undefined : value.tolerations.map(IoK8sApiResourceV1beta2DeviceTolerationToJSON), }; } //# sourceMappingURL=IoK8sApiResourceV1beta2DeviceSubRequest.js.map