* All parent scopes of this construct. * * @returns a list of parent scopes. The last element in the list will always * be the current construct and the first element will be the root of the * tree.
()
| 328 | * tree. |
| 329 | */ |
| 330 | public get scopes(): IConstruct[] { |
| 331 | const ret = new Array<IConstruct>(); |
| 332 | |
| 333 | let curr: IConstruct | undefined = this.host; |
| 334 | while (curr) { |
| 335 | ret.unshift(curr); |
| 336 | curr = curr.node.scope; |
| 337 | } |
| 338 | |
| 339 | return ret; |
| 340 | } |
| 341 | |
| 342 | /** |
| 343 | * Returns the root of the construct tree. |
nothing calls this directly
no outgoing calls
no test coverage detected