UNPKG

@devgrid/netron

Version:
15 lines 395 B
import { MAX_UID_VALUE } from './common'; export class Uid { constructor(initialValue = 0) { this.value = 0 >>> 0; this.reset(initialValue); } next() { this.value = this.value === MAX_UID_VALUE ? 1 : this.value + 1; return this.value; } reset(initialValue = 0) { this.value = initialValue >>> 0; } } //# sourceMappingURL=uid.js.map