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

Function implement

src/dependency.ts:76–81  ·  view source on GitHub ↗

* Turn any object into an IDependable.

(instance: IDependable, trait: Dependable)

Source from the content-addressed store, hash-verified

74 * Turn any object into an IDependable.
75 */
76 public static implement(instance: IDependable, trait: Dependable) {
77 // I would also like to reference classes (to cut down on the list of objects
78 // we need to manage), but we can't do that either since jsii doesn't have the
79 // concept of a class reference.
80 (instance as any)[DEPENDABLE_SYMBOL] = trait;
81 }
82
83 /**
84 * Return the matching Dependable for the given class instance.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected