UNPKG

@nodecfdi/cfdi-cleaner

Version:

Librería para limpiar comprobantes fiscales digitales v3.3 y v4.0

29 lines (28 loc) 731 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); class ExcludeList { _classNames; constructor(...classNames) { this._classNames = classNames; } isEmpty() { return this._classNames.length === 0; } matchClass(object) { for (const className of this._classNames) { if (object instanceof className) { return true; } } return false; } filterObjects(...objects) { return objects.filter((objectEntry) => { return !this.matchClass(objectEntry); }); } [Symbol.iterator]() { return this._classNames[Symbol.iterator](); } } exports.default = ExcludeList;