"use strict";
/**
 * This file has been generated
 * DO NOT EDIT, IT MAY BE OVERWRITTEN
 */
var __extends = (this && this.__extends) || (function () {
    var extendStatics = Object.setPrototypeOf ||
        ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
        function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
    return function (d, b) {
        extendStatics(d, b);
        function __() { this.constructor = d; }
        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
})();
Object.defineProperty(exports, "__esModule", { value: true });
var abstract_service_1 = require("../abstract-service");
var DeviceService = /** @class */ (function (_super) {
    __extends(DeviceService, _super);
    function DeviceService(client, apiConfig) {
        var _this = _super.call(this, client, apiConfig) || this;
        _this.resources = {
            'factoryReset': {
                path: "/device/factory-reset",
                methodType: "post"
            },
            'getAvailablePowerSource': {
                path: "/device/available-power-source",
                methodType: "get",
                returnTypeConverter: "AvailablePowerSource"
            },
            'getCurrentTime': {
                path: "/device/current-time",
                methodType: "get",
                returnTypeConverter: "string"
            },
            'getFirmwareVersion': {
                path: "/device/firmware-version",
                methodType: "get",
                returnTypeConverter: "string"
            },
            'getLastErrorCode': {
                path: "/device/last-error-code",
                methodType: "get",
                returnTypeConverter: "integer_uint32"
            },
            'getManufacturer': {
                path: "/device/manufacturer",
                methodType: "get",
                returnTypeConverter: "string"
            },
            'getMemoryFree': {
                path: "/device/memory-free",
                methodType: "get",
                returnTypeConverter: "integer_uint32"
            },
            'getModelName': {
                path: "/device/model-name",
                methodType: "get",
                returnTypeConverter: "string"
            },
            'getPowerSourceVoltage': {
                path: "/device/power-source-voltage",
                methodType: "get",
                returnTypeConverter: "integer_uint32"
            },
            'getSerialNumber': {
                path: "/device/serial-number",
                methodType: "get",
                returnTypeConverter: "string"
            },
            'postLastErrorCode': {
                path: "/device/last-error-code",
                methodType: "post"
            },
            'putCurrentTime': {
                path: "/device/current-time",
                methodType: "put"
            },
            'reboot': {
                path: "/device/reboot",
                methodType: "post"
            },
            'resetLastErrorCode': {
                path: "/device/reset-last-error-code",
                methodType: "post"
            },
        };
        return _this;
    }
    /**
    * Factory reset
    *
    * LWM2M path: /3//5
    * @return void api call
    */
    DeviceService.prototype.factoryReset = function () {
        var callOptions = this.resources.factoryReset;
        return this._call(callOptions);
    };
    /**
    * Get available power sources
    *
    * LWM2M path: /3//6
    * @return AvailablePowerSource api call
    */
    DeviceService.prototype.getAvailablePowerSource = function () {
        var callOptions = this.resources.getAvailablePowerSource;
        return this._call(callOptions);
    };
    /**
    * Get device current time
    *
    * LWM2M path: /3//13
    * @return string api call
    */
    DeviceService.prototype.getCurrentTime = function () {
        var callOptions = this.resources.getCurrentTime;
        return this._call(callOptions);
    };
    /**
    * Get device firmware version
    *
    * LWM2M path: /3//3
    * @return string api call
    */
    DeviceService.prototype.getFirmwareVersion = function () {
        var callOptions = this.resources.getFirmwareVersion;
        return this._call(callOptions);
    };
    /**
    * Get device last error code
    *
    * LWM2M path: /3//11
    * @return number api call
    */
    DeviceService.prototype.getLastErrorCode = function () {
        var callOptions = this.resources.getLastErrorCode;
        return this._call(callOptions);
    };
    /**
    * Get manufacturer name
    *
    * LWM2M path: /3//0
    * @return string api call
    */
    DeviceService.prototype.getManufacturer = function () {
        var callOptions = this.resources.getManufacturer;
        return this._call(callOptions);
    };
    /**
    * Get device memory free
    * In bytes
    * LWM2M path: /3//10
    * @return number api call
    */
    DeviceService.prototype.getMemoryFree = function () {
        var callOptions = this.resources.getMemoryFree;
        return this._call(callOptions);
    };
    /**
    * Get device model name
    *
    * LWM2M path: /3//1
    * @return string api call
    */
    DeviceService.prototype.getModelName = function () {
        var callOptions = this.resources.getModelName;
        return this._call(callOptions);
    };
    /**
    * Get power source voltage
    *
    * LWM2M path: /3//7
    * @return number api call
    */
    DeviceService.prototype.getPowerSourceVoltage = function () {
        var callOptions = this.resources.getPowerSourceVoltage;
        return this._call(callOptions);
    };
    /**
    * Get device serial number
    *
    * LWM2M path: /3//2
    * @return string api call
    */
    DeviceService.prototype.getSerialNumber = function () {
        var callOptions = this.resources.getSerialNumber;
        return this._call(callOptions);
    };
    /**
    * ???
    *
    * LWM2M path: /3//11
    * @return void api call
    */
    DeviceService.prototype.postLastErrorCode = function () {
        var callOptions = this.resources.postLastErrorCode;
        return this._call(callOptions);
    };
    /**
    * Set device current time
    *
    * LWM2M path: /3//13
    * @return void api call
    */
    DeviceService.prototype.putCurrentTime = function () {
        var callOptions = this.resources.putCurrentTime;
        return this._call(callOptions);
    };
    /**
    * Reboot device
    *
    * LWM2M path: /3//4
    * @return void api call
    */
    DeviceService.prototype.reboot = function () {
        var callOptions = this.resources.reboot;
        return this._call(callOptions);
    };
    /**
    * Reset device last error code
    *
    * LWM2M path: /3//12
    * @return void api call
    */
    DeviceService.prototype.resetLastErrorCode = function () {
        var callOptions = this.resources.resetLastErrorCode;
        return this._call(callOptions);
    };
    return DeviceService;
}(abstract_service_1.AbstractService));
exports.DeviceService = DeviceService;
