category

graph_common

Common graph predicates shared by all graph objects. Uses self-dispatch to call object-specific predicates such as neighbors/3, vertices/2, and edges/2.

Availability:
logtalk_load(graphs(loader))
Author: Paulo Moura
Version: 1:0:0
Date: 2026-02-25
Compilation flags:
static
Implements:
Uses:
Remarks:
(none)

Public predicates

(no local declarations; see entity ancestors if any)

Protected predicates

pairs_to_edges/2

Converts a list of Vertex-Neighbors pairs from a dictionary into a flat list of Vertex1-Vertex2 edges.

Compilation flags:
static
Template:
pairs_to_edges(Pairs,Edges)
Mode and number of proofs:
pairs_to_edges(+list(pair),-list) - one

vertex_neighbors_to_edges/4

Converts a neighbor list for a vertex into edges using a difference list.

Compilation flags:
static
Template:
vertex_neighbors_to_edges(Neighbors,Vertex,Edges,RestEdges)
Mode and number of proofs:
vertex_neighbors_to_edges(+list,+vertex,-list,-list) - one

wpairs_to_edges/2

Converts a list of Vertex-WNeighbors pairs from a dictionary into a flat list of (Vertex1-Vertex2)-Weight weighted edges.

Compilation flags:
static
Template:
wpairs_to_edges(Pairs,Edges)
Mode and number of proofs:
wpairs_to_edges(+list(pair),-list) - one

wvertex_neighbors_to_edges/4

Converts a weighted neighbor list for a vertex into weighted edges using a difference list.

Compilation flags:
static
Template:
wvertex_neighbors_to_edges(WNeighbors,Vertex,Edges,RestEdges)
Mode and number of proofs:
wvertex_neighbors_to_edges(+list,+vertex,-list,-list) - one

Private predicates

(no local declarations; see entity ancestors if any)

Operators

(none)