* Finds the internal links connected to the given input slot inside the subgraph, and resolves the nodes / slots. * @param slot The slot index * @returns The resolved connections, or undefined if no input node is found. * @remarks This is used to resolve the input links when dragging a link
(slot: number)
| 289 | * @remarks This is used to resolve the input links when dragging a link from a subgraph input slot. |
| 290 | */ |
| 291 | resolveSubgraphInputLinks(slot: number): ResolvedConnection[] { |
| 292 | const inputSlot = this.subgraph.inputNode.slots[slot] |
| 293 | const innerLinks = inputSlot.getLinks() |
| 294 | if (innerLinks.length === 0) { |
| 295 | console.debug(`[SubgraphNode.resolveSubgraphInputLinks] No inner links found for input slot [${slot}] ${inputSlot.name}`, this) |
| 296 | return [] |
| 297 | } |
| 298 | return innerLinks.map(link => link.resolve(this.subgraph)) |
| 299 | } |
| 300 | |
| 301 | /** |
| 302 | * Finds the internal link connected to the given output slot inside the subgraph, and resolves the nodes / slots. |
no test coverage detected