(s)
| 52850 | constructor({ length: s = 6 } = {}) { |
| 52851 | ;((this.uuid = new Kw({ length: s })), (this.identityMap = new WeakMap())) |
| 52852 | } |
| 52853 | identify(s) { |
| 52854 | if (!Cu(s)) |
| 52855 | throw new Gw( |
| 52856 | 'Cannot not identify the element. `element` is neither structurally compatible nor a subclass of an Element class.', |
| 52857 | { value: s } |
| 52858 | ) |
| 52859 | if (s.meta.hasKey('id') && ju(s.meta.get('id')) && !s.meta.get('id').equals('')) |
| 52860 | return s.id |
| 52861 | if (this.identityMap.has(s)) return this.identityMap.get(s) |
| 52862 | const o = new Su.Om(this.generateId()) |
| 52863 | return (this.identityMap.set(s, o), o) |
| 52864 | } |
| 52865 | forget(s) { |
| 52866 | return !!this.identityMap.has(s) && (this.identityMap.delete(s), !0) |
no test coverage detected