| 39 | } |
| 40 | |
| 41 | addEndIndex(endIndex) { |
| 42 | const lastChild = this.child[this.child.length - 1]; |
| 43 | // endIndex is write-once: when updateTag drops a node, the last child is a |
| 44 | // previously completed sibling whose endIndex must not be overwritten |
| 45 | if (lastChild !== undefined && lastChild[METADATA_SYMBOL] !== undefined |
| 46 | && lastChild[METADATA_SYMBOL].endIndex === undefined) { |
| 47 | lastChild[METADATA_SYMBOL].endIndex = endIndex; |
| 48 | } |
| 49 | } |
| 50 | /** symbol used for metadata */ |
| 51 | static getMetaDataSymbol() { |
| 52 | return METADATA_SYMBOL; |