Interface ISoftMutableGraph<TVertex, TEdge>
Bidirectional graph with soft mutability behavior. Soft mutation means that we can hide some vertices or edges.
Inherited Members
Namespace: GraphShape
Assembly: GraphShape.dll
Syntax
public interface ISoftMutableGraph<TVertex, TEdge> : IBidirectionalGraph<TVertex, TEdge>, IVertexAndEdgeListGraph<TVertex, TEdge>, IVertexListGraph<TVertex, TEdge>, IEdgeListGraph<TVertex, TEdge>, IVertexSet<TVertex>, IEdgeSet<TVertex, TEdge>, IBidirectionalIncidenceGraph<TVertex, TEdge>, IIncidenceGraph<TVertex, TEdge>, IImplicitGraph<TVertex, TEdge>, IGraph<TVertex, TEdge>, IImplicitVertexSet<TVertex> where TEdge : IEdge<TVertex>
Type Parameters
Name | Description |
---|---|
TVertex | Vertex type. |
TEdge | Edge type. |
Properties
| Improve this Doc View SourceHiddenEdgeCount
Gets the number of hidden edges.
Declaration
int HiddenEdgeCount { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
HiddenEdges
Gets the set of hidden edges.
Declaration
IEnumerable<TEdge> HiddenEdges { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<TEdge> |
HiddenVertexCount
Gets the number of hidden vertices.
Declaration
int HiddenVertexCount { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
HiddenVertices
Gets the set of hidden vertices.
Declaration
IEnumerable<TVertex> HiddenVertices { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<TVertex> |
Methods
| Improve this Doc View SourceHiddenEdgeCountOf(TVertex)
Gets the number of hidden edges connected to the given vertex
.
Declaration
int HiddenEdgeCountOf(TVertex vertex)
Parameters
Type | Name | Description |
---|---|---|
TVertex | vertex | Vertex to check. |
Returns
Type | Description |
---|---|
System.Int32 | Number of hidden edges. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
QuikGraph.VertexNotFoundException |
|
HiddenEdgesOf(TVertex)
Gets the hidden edges connected to the given vertex
.
Declaration
IEnumerable<TEdge> HiddenEdgesOf(TVertex vertex)
Parameters
Type | Name | Description |
---|---|---|
TVertex | vertex | Vertex to check. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<TEdge> | Hidden edges. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
QuikGraph.VertexNotFoundException |
|
HideEdge(TEdge)
Hides the given edge
.
Declaration
bool HideEdge(TEdge edge)
Parameters
Type | Name | Description |
---|---|---|
TEdge | edge | Edge to hide. |
Returns
Type | Description |
---|---|
System.Boolean | True if the edge is hidden, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
HideEdge(TEdge, String)
Hides the given edge
, and gives a tag
associated to this hidden edge.
Declaration
bool HideEdge(TEdge edge, string tag)
Parameters
Type | Name | Description |
---|---|---|
TEdge | edge | Edge to hide. |
System.String | tag | Tag associated to the hidden edge. |
Returns
Type | Description |
---|---|
System.Boolean | True if the edge is hidden, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
System.ArgumentNullException |
|
HideEdges(IEnumerable<TEdge>)
Hides the given set of edges
.
Declaration
void HideEdges(IEnumerable<TEdge> edges)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TEdge> | edges | Edges to hide. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
HideEdges(IEnumerable<TEdge>, String)
Hides the given set of edges
, and gives a tag
associated to this hidden edges.
Declaration
void HideEdges(IEnumerable<TEdge> edges, string tag)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TEdge> | edges | Edges to hide. |
System.String | tag | Tag associated to the hidden edges. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
System.ArgumentNullException |
|
HideEdgesIf(Predicate<TEdge>, String)
Hides edges matching the given predicate
, and gives a tag
associated to these hidden edges.
Declaration
void HideEdgesIf(Predicate<TEdge> predicate, string tag)
Parameters
Type | Name | Description |
---|---|---|
System.Predicate<TEdge> | predicate | Hide predicate. |
System.String | tag | Tag associated to the hidden edges. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
System.ArgumentNullException |
|
HideVertex(TVertex)
Hides the given vertex
.
Declaration
bool HideVertex(TVertex vertex)
Parameters
Type | Name | Description |
---|---|---|
TVertex | vertex | Vertex to hide. |
Returns
Type | Description |
---|---|
System.Boolean | True if the vertex is hidden, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
QuikGraph.VertexNotFoundException |
|
HideVertex(TVertex, String)
Hides the given vertex
, and gives a tag
associated to this hidden vertex.
Declaration
bool HideVertex(TVertex vertex, string tag)
Parameters
Type | Name | Description |
---|---|---|
TVertex | vertex | Vertex to hide. |
System.String | tag | Tag associated to the hidden vertex. |
Returns
Type | Description |
---|---|
System.Boolean | True if the vertex is hidden, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
System.ArgumentNullException |
|
QuikGraph.VertexNotFoundException |
|
HideVertices(IEnumerable<TVertex>)
Hides the given set of vertices
.
Declaration
void HideVertices(IEnumerable<TVertex> vertices)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TVertex> | vertices | Vertices to hide. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
QuikGraph.VertexNotFoundException | At least one of |
HideVertices(IEnumerable<TVertex>, String)
Hides the given set of vertices
, and gives a tag
associated to these hidden vertices.
Declaration
void HideVertices(IEnumerable<TVertex> vertices, string tag)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TVertex> | vertices | Vertices to hide. |
System.String | tag | Tag associated to the hidden vertices. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
QuikGraph.VertexNotFoundException | At least one of |
System.ArgumentNullException |
|
HideVerticesIf(Predicate<TVertex>, String)
Hides vertices matching the given predicate
, and gives a tag
associated to these hidden vertices.
Declaration
void HideVerticesIf(Predicate<TVertex> predicate, string tag)
Parameters
Type | Name | Description |
---|---|---|
System.Predicate<TVertex> | predicate | Hide predicate. |
System.String | tag | Tag associated to the hidden vertices. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
System.ArgumentNullException |
|
IsHiddenEdge(TEdge)
Checks if the given edge
is hidden.
Declaration
bool IsHiddenEdge(TEdge edge)
Parameters
Type | Name | Description |
---|---|---|
TEdge | edge | Edge to check. |
Returns
Type | Description |
---|---|
System.Boolean | True if the edge is hidden, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
IsHiddenVertex(TVertex)
Checks if the given vertex
is hidden.
Declaration
bool IsHiddenVertex(TVertex vertex)
Parameters
Type | Name | Description |
---|---|---|
TVertex | vertex | Vertex to check. |
Returns
Type | Description |
---|---|
System.Boolean | True if the vertex is hidden, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
QuikGraph.VertexNotFoundException |
|
Unhide(String)
Un-hides all vertices and edges that were hidden with the given tag
.
Declaration
bool Unhide(string tag)
Parameters
Type | Name | Description |
---|---|---|
System.String | tag | Tag to un-hide. |
Returns
Type | Description |
---|---|
System.Boolean | True if the tag has been un-hidden, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
UnhideAll()
Un-hides all hidden vertices and edges.
Declaration
bool UnhideAll()
Returns
Type | Description |
---|---|
System.Boolean | True if operation succeed, false otherwise. |
UnhideEdge(TEdge)
Un-hides the given edge
if it is hidden.
Declaration
bool UnhideEdge(TEdge edge)
Parameters
Type | Name | Description |
---|---|---|
TEdge | edge | Edge to un-hide. |
Returns
Type | Description |
---|---|
System.Boolean | True if the edge has been un-hidden, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
UnhideEdges(IEnumerable<TEdge>)
Un-hides the given edges
if they are hidden.
Declaration
void UnhideEdges(IEnumerable<TEdge> edges)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TEdge> | edges | Edges to un-hide. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
UnhideEdgesIf(Predicate<TEdge>)
Un-hides edges matching the given predicate
.
Declaration
void UnhideEdgesIf(Predicate<TEdge> predicate)
Parameters
Type | Name | Description |
---|---|---|
System.Predicate<TEdge> | predicate | Un-hide predicate. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
UnhideVertex(TVertex)
Un-hides the given vertex
if it is hidden.
Declaration
bool UnhideVertex(TVertex vertex)
Parameters
Type | Name | Description |
---|---|---|
TVertex | vertex | Vertex to un-hide. |
Returns
Type | Description |
---|---|
System.Boolean | True if the vertex has been un-hidden, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
QuikGraph.VertexNotFoundException |
|
UnhideVertexAndEdges(TVertex)
Un-hides the given vertex
and its connected edges if they are hidden.
Declaration
void UnhideVertexAndEdges(TVertex vertex)
Parameters
Type | Name | Description |
---|---|---|
TVertex | vertex | Vertex to un-hide. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
QuikGraph.VertexNotFoundException |
|