()
| 17949 | } |
| 17950 | class ExtendibleParticle extends AbstractExtendibleParticle { |
| 17951 | get idToParticleMap() { |
| 17952 | if (!this.isRoot()) return this.root.idToParticleMap |
| 17953 | if (!this._particleMapCache) { |
| 17954 | this._particleMapCache = {} |
| 17955 | this.forEach(subparticle => { |
| 17956 | this._particleMapCache[subparticle.id] = subparticle |
| 17957 | }) |
| 17958 | } |
| 17959 | return this._particleMapCache |
| 17960 | } |
| 17961 | get id() { |
| 17962 | return this.getAtom(0) |
| 17963 | } |