"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
/* eslint-disable frontApplet/enforce-jsdoc */
const errorHelper_1 = require("./errorHelper");
class SosError extends Error {
    code;
    suggestion;
    pathToDocs;
    constructor({ message, code, suggestion, pathToDocs, type }) {
        super(message);
        this.name = type ? type : 'SosError';
        this.code = code;
        this.suggestion = suggestion;
        this.pathToDocs = pathToDocs;
        this.stack = (0, errorHelper_1.getEnrichedStack)({
            type: this.name,
            message,
            code,
            stackTrace: this.stack,
            suggestion,
            pathToDocs,
        });
    }
}
exports.default = SosError;
//# sourceMappingURL=SosError.js.map