"use strict";
// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.
// See LICENSE in the project root for license information.
Object.defineProperty(exports, "__esModule", { value: true });
exports.VersionMismatchFinderProject = void 0;
const VersionMismatchFinderEntity_1 = require("./VersionMismatchFinderEntity");
class VersionMismatchFinderProject extends VersionMismatchFinderEntity_1.VersionMismatchFinderEntity {
    constructor(project) {
        super({
            friendlyName: project.packageName,
            cyclicDependencyProjects: project.cyclicDependencyProjects,
            skipRushCheck: project.skipRushCheck
        });
        this._fileManager = project.packageJsonEditor;
        this.packageName = project.packageName;
    }
    get filePath() {
        return this._fileManager.filePath;
    }
    get allDependencies() {
        return [...this._fileManager.dependencyList, ...this._fileManager.devDependencyList];
    }
    tryGetDependency(packageName) {
        return this._fileManager.tryGetDependency(packageName);
    }
    tryGetDevDependency(packageName) {
        return this._fileManager.tryGetDevDependency(packageName);
    }
    addOrUpdateDependency(packageName, newVersion, dependencyType) {
        return this._fileManager.addOrUpdateDependency(packageName, newVersion, dependencyType);
    }
    saveIfModified() {
        return this._fileManager.saveIfModified();
    }
}
exports.VersionMismatchFinderProject = VersionMismatchFinderProject;
//# sourceMappingURL=VersionMismatchFinderProject.js.map