/* 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'; import { ElementsUserMini, ElementsUserMiniFromJSON, ElementsUserMiniFromJSONTyped, ElementsUserMiniToJSON, WorkstationMini, WorkstationMiniFromJSON, WorkstationMiniFromJSONTyped, WorkstationMiniToJSON, } from './'; /** * * @export * @interface ClientSession */ export interface ClientSession { /** * * @type {number} * @memberof ClientSession */ id: number; /** * * @type {ElementsUserMini} * @memberof ClientSession */ user: ElementsUserMini; /** * * @type {string} * @memberof ClientSession */ readonly mountedWorkspaces: string; /** * * @type {Date} * @memberof ClientSession */ readonly started: Date; /** * * @type {Date} * @memberof ClientSession */ readonly lastUpdated: Date; /** * * @type {WorkstationMini} * @memberof ClientSession */ workstation: WorkstationMini; } export function ClientSessionFromJSON(json: any): ClientSession { return ClientSessionFromJSONTyped(json, false); } export function ClientSessionFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientSession { if ((json === undefined) || (json === null)) { return json; } return { 'id': json['id'], 'user': ElementsUserMiniFromJSON(json['user']), 'mountedWorkspaces': json['mounted_workspaces'], 'started': (new Date(json['started'])), 'lastUpdated': (new Date(json['last_updated'])), 'workstation': WorkstationMiniFromJSON(json['workstation']), }; } export function ClientSessionToJSON(value?: ClientSession | null): any { if (value === undefined) { return undefined; } if (value === null) { return null; } return { 'id': value.id, 'user': ElementsUserMiniToJSON(value.user), 'workstation': WorkstationMiniToJSON(value.workstation), }; }