"use strict";
/* tslint:disable */
/* eslint-disable */
/**
 * authentik
 * Making authentication simple.
 *
 * The version of the OpenAPI document: 2025.10.0-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.instanceOfSchedule = instanceOfSchedule;
exports.ScheduleFromJSON = ScheduleFromJSON;
exports.ScheduleFromJSONTyped = ScheduleFromJSONTyped;
exports.ScheduleToJSON = ScheduleToJSON;
exports.ScheduleToJSONTyped = ScheduleToJSONTyped;
const LastTaskStatusEnum_1 = require("./LastTaskStatusEnum");
/**
 * Check if a given object implements the Schedule interface.
 */
function instanceOfSchedule(value) {
    if (!('id' in value) || value['id'] === undefined)
        return false;
    if (!('identifier' in value) || value['identifier'] === undefined)
        return false;
    if (!('uid' in value) || value['uid'] === undefined)
        return false;
    if (!('actorName' in value) || value['actorName'] === undefined)
        return false;
    if (!('relObjAppLabel' in value) || value['relObjAppLabel'] === undefined)
        return false;
    if (!('relObjModel' in value) || value['relObjModel'] === undefined)
        return false;
    if (!('crontab' in value) || value['crontab'] === undefined)
        return false;
    if (!('nextRun' in value) || value['nextRun'] === undefined)
        return false;
    if (!('description' in value) || value['description'] === undefined)
        return false;
    if (!('lastTaskStatus' in value) || value['lastTaskStatus'] === undefined)
        return false;
    return true;
}
function ScheduleFromJSON(json) {
    return ScheduleFromJSONTyped(json, false);
}
function ScheduleFromJSONTyped(json, ignoreDiscriminator) {
    if (json == null) {
        return json;
    }
    return {
        'id': json['id'],
        'identifier': json['identifier'],
        'uid': json['uid'],
        'actorName': json['actor_name'],
        'relObjAppLabel': json['rel_obj_app_label'],
        'relObjModel': json['rel_obj_model'],
        'relObjId': json['rel_obj_id'] == null ? undefined : json['rel_obj_id'],
        'crontab': json['crontab'],
        'paused': json['paused'] == null ? undefined : json['paused'],
        'nextRun': (new Date(json['next_run'])),
        'description': json['description'],
        'lastTaskStatus': (0, LastTaskStatusEnum_1.LastTaskStatusEnumFromJSON)(json['last_task_status']),
    };
}
function ScheduleToJSON(json) {
    return ScheduleToJSONTyped(json, false);
}
function ScheduleToJSONTyped(value, ignoreDiscriminator = false) {
    if (value == null) {
        return value;
    }
    return {
        'rel_obj_id': value['relObjId'],
        'crontab': value['crontab'],
        'paused': value['paused'],
    };
}
//# sourceMappingURL=Schedule.js.map