Graph

package
v0.3.22 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Graph

type Graph[T VertexElementer] struct {
	// contains filtered or unexported fields
}

func NewGraph

func NewGraph[T VertexElementer](sf uts.SortFunc[*Vertex[T]]) *Graph[T]

func (*Graph[T]) AddEdge

func (g *Graph[T]) AddEdge(from, to *Vertex[T])

func (*Graph[T]) AddVertex

func (g *Graph[T]) AddVertex(v *Vertex[T])

type Vertex

type Vertex[T VertexElementer] struct {
	// contains filtered or unexported fields
}

func NewVertex

func NewVertex[T VertexElementer](value T) *Vertex[T]

func (*Vertex[T]) Copy

func (v *Vertex[T]) Copy() uc.Copier

func (*Vertex[T]) Equals

func (v *Vertex[T]) Equals(other uc.Equaler) bool

func (*Vertex[T]) GetValue added in v0.3.20

func (v *Vertex[T]) GetValue() T

type VertexElementer added in v0.3.13

type VertexElementer interface {
	uc.Equaler
	uc.Copier
}

Jump to

Keyboard shortcuts

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