"use strict";
/* tslint:disable */
/* eslint-disable */
/**
 * authentik
 * Making authentication simple.
 *
 * The version of the OpenAPI document: 2026.2.2-rc1
 * Contact: hello@goauthentik.io
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.instanceOfDevice = instanceOfDevice;
exports.DeviceFromJSON = DeviceFromJSON;
exports.DeviceFromJSONTyped = DeviceFromJSONTyped;
exports.DeviceToJSON = DeviceToJSON;
exports.DeviceToJSONTyped = DeviceToJSONTyped;
/**
 * Check if a given object implements the Device interface.
 */
function instanceOfDevice(value) {
    if (!('verboseName' in value) || value['verboseName'] === undefined)
        return false;
    if (!('verboseNamePlural' in value) || value['verboseNamePlural'] === undefined)
        return false;
    if (!('metaModelName' in value) || value['metaModelName'] === undefined)
        return false;
    if (!('pk' in value) || value['pk'] === undefined)
        return false;
    if (!('name' in value) || value['name'] === undefined)
        return false;
    if (!('type' in value) || value['type'] === undefined)
        return false;
    if (!('confirmed' in value) || value['confirmed'] === undefined)
        return false;
    if (!('created' in value) || value['created'] === undefined)
        return false;
    if (!('lastUpdated' in value) || value['lastUpdated'] === undefined)
        return false;
    if (!('lastUsed' in value) || value['lastUsed'] === undefined)
        return false;
    if (!('extraDescription' in value) || value['extraDescription'] === undefined)
        return false;
    if (!('externalId' in value) || value['externalId'] === undefined)
        return false;
    return true;
}
function DeviceFromJSON(json) {
    return DeviceFromJSONTyped(json, false);
}
function DeviceFromJSONTyped(json, ignoreDiscriminator) {
    if (json == null) {
        return json;
    }
    return {
        'verboseName': json['verbose_name'],
        'verboseNamePlural': json['verbose_name_plural'],
        'metaModelName': json['meta_model_name'],
        'pk': json['pk'],
        'name': json['name'],
        'type': json['type'],
        'confirmed': json['confirmed'],
        'created': (new Date(json['created'])),
        'lastUpdated': (new Date(json['last_updated'])),
        'lastUsed': (json['last_used'] == null ? null : new Date(json['last_used'])),
        'extraDescription': json['extra_description'],
        'externalId': json['external_id'],
    };
}
function DeviceToJSON(json) {
    return DeviceToJSONTyped(json, false);
}
function DeviceToJSONTyped(value, ignoreDiscriminator = false) {
    if (value == null) {
        return value;
    }
    return {
        'pk': value['pk'],
        'name': value['name'],
        'confirmed': value['confirmed'],
    };
}
//# sourceMappingURL=Device.js.map