graph

package
v0.1.19 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 26, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GraphNode

type GraphNode struct {
	// contains filtered or unexported fields
}

GraphNode is a node in an implicit graph.

func NewGraphNode

func NewGraphNode(id int64) *GraphNode

NewGraphNode returns a new GraphNode.

func (*GraphNode) AddNeighbor

func (g *GraphNode) AddNeighbor(n *GraphNode)

AddMeighbor adds an edge between g and n.

func (*GraphNode) AddRoot

func (g *GraphNode) AddRoot(n *GraphNode)

AddRoot adds provides an entrance into the graph g from n.

func (*GraphNode) Edge

func (g *GraphNode) Edge(uid, vid int64) graph.Edge

Edge allows GraphNode to satisfy the graph.Graph interface.

func (*GraphNode) EdgeBetween

func (g *GraphNode) EdgeBetween(uid, vid int64) graph.Edge

EdgeBetween allows GraphNode to satisfy the graph.Graph interface.

func (*GraphNode) From

func (g *GraphNode) From(id int64) graph.Nodes

From allows GraphNode to satisfy the graph.Graph interface.

func (*GraphNode) HasEdgeBetween

func (g *GraphNode) HasEdgeBetween(uid, vid int64) bool

HasEdgeBetween allows GraphNode to satisfy the graph.Graph interface.

func (*GraphNode) ID

func (g *GraphNode) ID() int64

ID allows GraphNode to satisfy the graph.Node interface.

func (*GraphNode) Node

func (g *GraphNode) Node(id int64) graph.Node

Node allows GraphNode to satisfy the graph.Graph interface.

func (*GraphNode) Nodes

func (g *GraphNode) Nodes() graph.Nodes

Nodes allows GraphNode to satisfy the graph.Graph interface.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL