MCPcopy Create free account
hub / github.com/aws/constructs / getAllContext

Method getAllContext

src/construct.ts:289–295  ·  view source on GitHub ↗

* Retrieves the all context of a node from tree context. * * Context is usually initialized at the root, but can be overridden at any point in the tree. * * @param defaults Any keys to override the retrieved context * @returns The context object or an empty object if there is discover

(defaults?: object)

Source from the content-addressed store, hash-verified

287 * @returns The context object or an empty object if there is discovered context
288 */
289 public getAllContext(defaults?: object): any {
290 const ret = { ...defaults };
291 for (const scope of this._scopes) {
292 Object.assign(ret, scope.node._context);
293 }
294 return ret;
295 }
296
297 /**
298 * Retrieves a value from tree context.

Callers 1

construct.test.tsFile · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected