Documentation ¶
Index ¶
- type DirGraph
- func (g *DirGraph) AddEdge(from, to VertexId, weight int) error
- func (g *DirGraph) AddVertex(vertex VertexId) error
- func (g *DirGraph) CheckVertex(vertex VertexId) bool
- func (g *DirGraph) EdgesCount() int
- func (g *DirGraph) EdgesIter() <-chan Edge
- func (g *DirGraph) GetEdge(from, to VertexId) int
- func (g *DirGraph) GetNeighbours(vertex VertexId) VerticesIterable
- func (g *DirGraph) GetPredecessors(vertex VertexId) VerticesIterable
- func (g *DirGraph) GetSuccessors(vertex VertexId) VerticesIterable
- func (g *DirGraph) IsEdge(from, to VertexId) bool
- func (g *DirGraph) IsVertex(vertex VertexId) (exist bool)
- func (g *DirGraph) Order() int
- func (g *DirGraph) RemoveEdge(from, to VertexId) error
- func (g *DirGraph) RemoveVertex(vertex VertexId) error
- func (g *DirGraph) Reverse() *DirGraph
- func (g *DirGraph) TouchVertex(vertex VertexId)
- func (g *DirGraph) VerticesCount() int
- func (g *DirGraph) VerticesIter() <-chan VertexId
- type Edge
- type EdgesIterable
- type UnGraph
- func (g *UnGraph) AddEdge(from, to VertexId, weight int) error
- func (g *UnGraph) AddVertex(vertex VertexId) error
- func (g *UnGraph) CheckVertex(vertex VertexId) bool
- func (g *UnGraph) EdgesCount() int
- func (g *UnGraph) EdgesIter() <-chan Edge
- func (g *UnGraph) GetEdge(from, to VertexId) int
- func (g *UnGraph) GetNeighbours(vertex VertexId) VerticesIterable
- func (g *UnGraph) GetPredecessors(vertex VertexId) VerticesIterable
- func (g *UnGraph) GetSuccessors(vertex VertexId) VerticesIterable
- func (g *UnGraph) IsEdge(from, to VertexId) bool
- func (g *UnGraph) IsVertex(vertex VertexId) (exist bool)
- func (g *UnGraph) Order() int
- func (g *UnGraph) RemoveEdge(from, to VertexId) error
- func (g *UnGraph) RemoveVertex(vertex VertexId) error
- func (g *UnGraph) TouchVertex(vertex VertexId)
- func (g *UnGraph) VerticesCount() int
- func (g *UnGraph) VerticesIter() <-chan VertexId
- type VertexId
- type Vertices
- type VerticesIterable
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DirGraph ¶
type DirGraph struct {
// contains filtered or unexported fields
}
func NewDirected ¶
func NewDirected() *DirGraph
func (*DirGraph) CheckVertex ¶
func (*DirGraph) EdgesCount ¶
func (g *DirGraph) EdgesCount() int
func (*DirGraph) GetNeighbours ¶
func (g *DirGraph) GetNeighbours(vertex VertexId) VerticesIterable
func (*DirGraph) GetPredecessors ¶
func (g *DirGraph) GetPredecessors(vertex VertexId) VerticesIterable
func (*DirGraph) GetSuccessors ¶
func (g *DirGraph) GetSuccessors(vertex VertexId) VerticesIterable
func (*DirGraph) RemoveEdge ¶
func (*DirGraph) RemoveVertex ¶
func (*DirGraph) TouchVertex ¶
func (g *DirGraph) TouchVertex(vertex VertexId)
func (*DirGraph) VerticesCount ¶
func (g *DirGraph) VerticesCount() int
func (*DirGraph) VerticesIter ¶
func (g *DirGraph) VerticesIter() <-chan VertexId
type EdgesIterable ¶
type EdgesIterable interface {
EdgesIter() <-chan Edge
}
type UnGraph ¶
type UnGraph struct {
// contains filtered or unexported fields
}
func NewUndirected ¶
func NewUndirected() *UnGraph
func (*UnGraph) CheckVertex ¶
func (*UnGraph) EdgesCount ¶
func (g *UnGraph) EdgesCount() int
func (*UnGraph) GetNeighbours ¶
func (g *UnGraph) GetNeighbours(vertex VertexId) VerticesIterable
func (*UnGraph) GetPredecessors ¶
func (g *UnGraph) GetPredecessors(vertex VertexId) VerticesIterable
func (*UnGraph) GetSuccessors ¶
func (g *UnGraph) GetSuccessors(vertex VertexId) VerticesIterable
func (*UnGraph) RemoveEdge ¶
func (*UnGraph) RemoveVertex ¶
func (*UnGraph) TouchVertex ¶
func (g *UnGraph) TouchVertex(vertex VertexId)
func (*UnGraph) VerticesCount ¶
func (g *UnGraph) VerticesCount() int
func (*UnGraph) VerticesIter ¶
func (g *UnGraph) VerticesIter() <-chan VertexId
type VerticesIterable ¶
type VerticesIterable interface {
VerticesIter() <-chan VertexId
}
Click to show internal directories.
Click to hide internal directories.