* Returns object structure. * @param {keyof T} key key * @returns {ObjectStructure<T>} object structure
(key)
| 41 | * @returns {ObjectStructure<T>} object structure |
| 42 | */ |
| 43 | key(key) { |
| 44 | if (this.children === undefined) this.children = new Map(); |
| 45 | const child = this.children.get(key); |
| 46 | if (child !== undefined) return child; |
| 47 | const newChild = new ObjectStructure(); |
| 48 | this.children.set(key, newChild); |
| 49 | return newChild; |
| 50 | } |
| 51 | } |
| 52 | |
| 53 | /** |
no test coverage detected