@shumoku/core · 0.4.0 · function
isPortLinked
APIの説明は英語のcanonical sourceを表示しています。
Whether the given port already appears as an endpoint of any link. A physical port models one cable termination, so it can host at most one link at a time. Callers use this to reject attempts to wire a second link onto an already-connected port — `linkExists` only catches exact-duplicate links, which isn't enough for the "1 port = 1 link" invariant.
isPortLinked(links: Link[], nodeId: string, portId: string): boolean パラメーター
| 名前 | 型 | 説明 | 既定値 |
|---|---|---|---|
links | Link[] | 追加説明はありません。 | — |
nodeId | string | 追加説明はありません。 | — |
portId | string | 追加説明はありません。 | — |
戻り値
boolean