(
id: ElementId,
options?: { throwIfNotFound?: boolean },
)
| 452 | options?: { throwIfNotFound?: false }, |
| 453 | ): Edge<TSchema, TEdgeLabel> | undefined; |
| 454 | public getEdgeById<TEdgeLabel extends EdgeLabel<TSchema>>( |
| 455 | id: ElementId, |
| 456 | options?: { throwIfNotFound?: boolean }, |
| 457 | ): Edge<TSchema, TEdgeLabel> | undefined { |
| 458 | const data = this.#config.storage.getEdgeById(id); |
| 459 | if (data === undefined) { |
| 460 | if (options?.throwIfNotFound) { |
| 461 | throw new EdgeNotFoundError(id); |
| 462 | } |
| 463 | return undefined; |
| 464 | } |
| 465 | return this.instantiateEdge<TEdgeLabel>(data); |
| 466 | } |
| 467 | |
| 468 | public *getEdges<TEdgeLabel extends EdgeLabel<TSchema>>( |
| 469 | ...labels: TEdgeLabel[] |
no test coverage detected