C# Класс FastGraph.BidirectionalGraph

Наследование: IEdgeListAndIncidenceGraph, IMutableBidirectionalGraph, ICloneable
Показать файл Открыть проект

Private Properties

Свойство Тип Описание
AddEdgeInternal bool
Clone TEdge>.BidirectionalGraph
ICloneable object
NotifyEdgesRemoved void
NotifyVerticesRemoved void
RemoveEdgesInternal int
RemoveInOutEdges IEnumerable

Открытые методы

Метод Описание
AddEdge ( edge ) : bool
AddEdgeRange ( IEnumerable edges ) : int
AddVertex ( vertex ) : bool
AddVertexRange ( IEnumerable vertices ) : int
AddVerticesAndEdge ( edge ) : bool
AddVerticesAndEdgeRange ( IEnumerable edges ) : int
BidirectionalGraph ( ) : System

Initializes a new instance of the BidirectionalGraph{TVertex,TEdge} class.

BidirectionalGraph ( BidirectionalGraph other ) : System

Copy constructor that creates sufficiently deep copy of the graph.

BidirectionalGraph ( bool allowParallelEdges ) : System

Initializes a new instance of the BidirectionalGraph{TVertex,TEdge} class.

BidirectionalGraph ( bool allowParallelEdges, int capacity ) : System

Initializes a new instance of the BidirectionalGraph{TVertex,TEdge} class.

BidirectionalGraph ( bool allowParallelEdges, int vertexCapacity, int edgeCapacity ) : System

Initializes a new instance of the BidirectionalGraph{TVertex,TEdge} class.

Clear ( ) : void
ClearEdges ( vertex ) : void
ClearInEdges ( vertex ) : void
ClearOutEdges ( vertex ) : void
ContainsEdge ( edge ) : bool
ContainsEdge ( source, target ) : bool
ContainsVertex ( vertex ) : bool
Degree ( vertex ) : int
InDegree ( vertex ) : int
InEdge ( vertex, int index ) : TEdge
InEdges ( vertex ) : IEnumerable
IsInEdgesEmpty ( vertex ) : bool
IsOutEdgesEmpty ( vertex ) : bool
MergeVertex ( vertex, EdgeFactory edgeFactory ) : void

Removes the given vertex and merges all its connection to other vertices.

MergeVerticesIf ( VertexPredicate vertexPredicate, EdgeFactory edgeFactory ) : void

Removes vertices matching the given vertexPredicate and merges all their connections to other vertices.

OutDegree ( vertex ) : int
OutEdge ( vertex, int index ) : TEdge
OutEdges ( vertex ) : IEnumerable
RemoveEdge ( edge ) : bool
RemoveEdgeIf ( EdgePredicate predicate ) : int
RemoveInEdgeIf ( vertex, EdgePredicate predicate ) : int
RemoveOutEdgeIf ( vertex, EdgePredicate predicate ) : int
RemoveVertex ( vertex ) : bool
RemoveVertexIf ( VertexPredicate predicate ) : int
TrimEdgeExcess ( ) : void
TryGetEdge ( source, target, &edge ) : bool
TryGetEdges ( source, target, IEnumerable &edges ) : bool
TryGetInEdges ( vertex, IEnumerable &edges ) : bool
TryGetOutEdges ( vertex, IEnumerable &edges ) : bool

Защищенные методы

Метод Описание
OnEdgeAdded ( edge ) : void

Called on each added edge.

OnEdgeRemoved ( edge ) : void

Called on each removed edge.

OnVertexAdded ( vertex ) : void

Called on each added vertex.

OnVertexRemoved ( vertex ) : void

Called for each removed vertex.

Приватные методы

Метод Описание
AddEdgeInternal ( edge ) : bool
Clone ( ) : TEdge>.BidirectionalGraph
ICloneable ( ) : object
NotifyEdgesRemoved ( IEnumerable edges ) : void
NotifyVerticesRemoved ( ICollection vertices ) : void
RemoveEdgesInternal ( ICollection edgesToRemove ) : int
RemoveInOutEdges ( vertex ) : IEnumerable

Описание методов

AddEdge() публичный Метод

public AddEdge ( edge ) : bool
Результат bool

AddEdgeRange() публичный Метод

public AddEdgeRange ( IEnumerable edges ) : int
edges IEnumerable
Результат int

AddVertex() публичный Метод

public AddVertex ( vertex ) : bool
Результат bool

AddVertexRange() публичный Метод

public AddVertexRange ( IEnumerable vertices ) : int
vertices IEnumerable
Результат int

AddVerticesAndEdge() публичный Метод

public AddVerticesAndEdge ( edge ) : bool
Результат bool

AddVerticesAndEdgeRange() публичный Метод

public AddVerticesAndEdgeRange ( IEnumerable edges ) : int
edges IEnumerable
Результат int

BidirectionalGraph() публичный Метод

Initializes a new instance of the BidirectionalGraph{TVertex,TEdge} class.
public BidirectionalGraph ( ) : System
Результат System

BidirectionalGraph() публичный Метод

Copy constructor that creates sufficiently deep copy of the graph.
public BidirectionalGraph ( BidirectionalGraph other ) : System
other BidirectionalGraph Graph to copy.
Результат System

BidirectionalGraph() публичный Метод

Initializes a new instance of the BidirectionalGraph{TVertex,TEdge} class.
public BidirectionalGraph ( bool allowParallelEdges ) : System
allowParallelEdges bool Indicates if parallel edges are allowed.
Результат System

BidirectionalGraph() публичный Метод

Initializes a new instance of the BidirectionalGraph{TVertex,TEdge} class.
public BidirectionalGraph ( bool allowParallelEdges, int capacity ) : System
allowParallelEdges bool Indicates if parallel edges are allowed.
capacity int Vertex capacity.
Результат System

BidirectionalGraph() публичный Метод

Initializes a new instance of the BidirectionalGraph{TVertex,TEdge} class.
public BidirectionalGraph ( bool allowParallelEdges, int vertexCapacity, int edgeCapacity ) : System
allowParallelEdges bool Indicates if parallel edges are allowed.
vertexCapacity int Vertex capacity.
edgeCapacity int Edge capacity.
Результат System

Clear() публичный Метод

public Clear ( ) : void
Результат void

ClearEdges() публичный Метод

public ClearEdges ( vertex ) : void
Результат void

ClearInEdges() публичный Метод

public ClearInEdges ( vertex ) : void
Результат void

ClearOutEdges() публичный Метод

public ClearOutEdges ( vertex ) : void
Результат void

ContainsEdge() публичный Метод

public ContainsEdge ( edge ) : bool
Результат bool

ContainsEdge() публичный Метод

public ContainsEdge ( source, target ) : bool
Результат bool

ContainsVertex() публичный Метод

public ContainsVertex ( vertex ) : bool
Результат bool

Degree() публичный Метод

public Degree ( vertex ) : int
Результат int

InDegree() публичный Метод

public InDegree ( vertex ) : int
Результат int

InEdge() публичный Метод

public InEdge ( vertex, int index ) : TEdge
index int
Результат TEdge

InEdges() публичный Метод

public InEdges ( vertex ) : IEnumerable
Результат IEnumerable

IsInEdgesEmpty() публичный Метод

public IsInEdgesEmpty ( vertex ) : bool
Результат bool

IsOutEdgesEmpty() публичный Метод

public IsOutEdgesEmpty ( vertex ) : bool
Результат bool

MergeVertex() публичный Метод

Removes the given vertex and merges all its connection to other vertices.
is . is . is not part of the graph.
public MergeVertex ( vertex, EdgeFactory edgeFactory ) : void
vertex The vertex.
edgeFactory EdgeFactory Factory method to create an edge.
Результат void

MergeVerticesIf() публичный Метод

Removes vertices matching the given vertexPredicate and merges all their connections to other vertices.
is . is .
public MergeVerticesIf ( VertexPredicate vertexPredicate, EdgeFactory edgeFactory ) : void
vertexPredicate VertexPredicate Predicate to match vertices.
edgeFactory EdgeFactory Factory method to create an edge.
Результат void

OnEdgeAdded() защищенный Метод

Called on each added edge.
protected OnEdgeAdded ( edge ) : void
edge Added edge.
Результат void

OnEdgeRemoved() защищенный Метод

Called on each removed edge.
protected OnEdgeRemoved ( edge ) : void
edge Removed edge.
Результат void

OnVertexAdded() защищенный Метод

Called on each added vertex.
protected OnVertexAdded ( vertex ) : void
vertex Added vertex.
Результат void

OnVertexRemoved() защищенный Метод

Called for each removed vertex.
protected OnVertexRemoved ( vertex ) : void
vertex Removed vertex.
Результат void

OutDegree() публичный Метод

public OutDegree ( vertex ) : int
Результат int

OutEdge() публичный Метод

public OutEdge ( vertex, int index ) : TEdge
index int
Результат TEdge

OutEdges() публичный Метод

public OutEdges ( vertex ) : IEnumerable
Результат IEnumerable

RemoveEdge() публичный Метод

public RemoveEdge ( edge ) : bool
Результат bool

RemoveEdgeIf() публичный Метод

public RemoveEdgeIf ( EdgePredicate predicate ) : int
predicate EdgePredicate
Результат int

RemoveInEdgeIf() публичный Метод

public RemoveInEdgeIf ( vertex, EdgePredicate predicate ) : int
predicate EdgePredicate
Результат int

RemoveOutEdgeIf() публичный Метод

public RemoveOutEdgeIf ( vertex, EdgePredicate predicate ) : int
predicate EdgePredicate
Результат int

RemoveVertex() публичный Метод

public RemoveVertex ( vertex ) : bool
Результат bool

RemoveVertexIf() публичный Метод

public RemoveVertexIf ( VertexPredicate predicate ) : int
predicate VertexPredicate
Результат int

TrimEdgeExcess() публичный Метод

public TrimEdgeExcess ( ) : void
Результат void

TryGetEdge() публичный Метод

public TryGetEdge ( source, target, &edge ) : bool
Результат bool

TryGetEdges() публичный Метод

public TryGetEdges ( source, target, IEnumerable &edges ) : bool
edges IEnumerable
Результат bool

TryGetInEdges() публичный Метод

public TryGetInEdges ( vertex, IEnumerable &edges ) : bool
edges IEnumerable
Результат bool

TryGetOutEdges() публичный Метод

public TryGetOutEdges ( vertex, IEnumerable &edges ) : bool
edges IEnumerable
Результат bool