/* tslint:disable */ /* eslint-disable */ /** * ELEMENTS API * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 2 * * * 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, mapValues } from '../runtime'; /** * * @export * @interface License */ export interface License { /** * * @type {string} * @memberof License */ name: string; /** * * @type {string} * @memberof License */ product: string; /** * * @type {string} * @memberof License */ serial: string | null; /** * * @type {string} * @memberof License */ partner: string | null; /** * * @type {string} * @memberof License */ hardware?: string; /** * * @type {string} * @memberof License */ hardwareKey?: string; /** * * @type {Date} * @memberof License */ expiry: Date | null; /** * * @type {{ [key: string]: boolean | undefined; }} * @memberof License */ components: { [key: string]: boolean | undefined; }; /** * * @type {{ [key: string]: Date | undefined; }} * @memberof License */ componentsExpiry: { [key: string]: Date | undefined; }; /** * * @type {{ [key: string]: boolean | undefined; }} * @memberof License */ componentsEnabled: { [key: string]: boolean | undefined; }; /** * * @type {number} * @memberof License */ rdcSlots: number; /** * * @type {number} * @memberof License */ users: number; /** * * @type {number} * @memberof License */ thirdPartyCapacity: number | null; } export function LicenseFromJSON(json: any): License { return LicenseFromJSONTyped(json, false); } export function LicenseFromJSONTyped(json: any, ignoreDiscriminator: boolean): License { if ((json === undefined) || (json === null)) { return json; } return { 'name': json['name'], 'product': json['product'], 'serial': json['serial'], 'partner': json['partner'], 'hardware': !exists(json, 'hardware') ? undefined : json['hardware'], 'hardwareKey': !exists(json, 'hardware_key') ? undefined : json['hardware_key'], 'expiry': (json['expiry'] === null ? null : new Date(json['expiry'])), 'components': json['components'], 'componentsExpiry': json['components_expiry'], 'componentsEnabled': json['components_enabled'], 'rdcSlots': json['rdc_slots'], 'users': json['users'], 'thirdPartyCapacity': json['third_party_capacity'], }; } export function LicenseToJSON(value?: License | null): any { if (value === undefined) { return undefined; } if (value === null) { return null; } return { 'name': value.name, 'product': value.product, 'serial': value.serial, 'partner': value.partner, 'hardware': value.hardware, 'hardware_key': value.hardwareKey, 'expiry': (value.expiry === null ? null : value.expiry.toISOString()), 'components': value.components, 'components_expiry': value.componentsExpiry, 'components_enabled': value.componentsEnabled, 'rdc_slots': value.rdcSlots, 'users': value.users, 'third_party_capacity': value.thirdPartyCapacity, }; }