UNPKG

@zfunction/genetics-js

Version:

Genetic and evolutionary algorithms framework for the web

19 lines 702 B
"use strict"; /* * @license * Copyright (c) 2019 Cristian Abrante. All rights reserved. * Licensed under the MIT License. See LICENSE in the project root for license information. */ Object.defineProperty(exports, "__esModule", { value: true }); var MaxGenerations = /** @class */ (function () { function MaxGenerations(maxGenerations) { this.maxGenerations = 0; this.maxGenerations = maxGenerations; } MaxGenerations.prototype.isSatisfied = function (population, generations) { return generations >= this.maxGenerations; }; return MaxGenerations; }()); exports.MaxGenerations = MaxGenerations; //# sourceMappingURL=MaxGenerations.js.map