Interface IMutableVertexSet<TVertex>
Represents a mutable set of vertices.
Inherited Members
Namespace: QuikGraph
Assembly: QuikGraph.dll
Syntax
public interface IMutableVertexSet<TVertex> : IVertexSet<TVertex>, IImplicitVertexSet<TVertex>
Type Parameters
Name | Description |
---|---|
TVertex | Vertex type. |
Methods
| Improve this Doc View SourceAddVertex(TVertex)
Adds a vertex to this set.
Declaration
bool AddVertex(TVertex vertex)
Parameters
Type | Name | Description |
---|---|---|
TVertex | vertex | Vertex to add. |
Returns
Type | Description |
---|---|
System.Boolean | True if the vertex was added, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
AddVertexRange(IEnumerable<TVertex>)
Adds given vertices to this set.
Declaration
int AddVertexRange(IEnumerable<TVertex> vertices)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<TVertex> | vertices | Vertices to add. |
Returns
Type | Description |
---|---|
System.Int32 | The number of vertex added. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
RemoveVertex(TVertex)
Removes the given vertex from this set.
Declaration
bool RemoveVertex(TVertex vertex)
Parameters
Type | Name | Description |
---|---|---|
TVertex | vertex | Vertex to remove. |
Returns
Type | Description |
---|---|
System.Boolean | True if the vertex was removed, false otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
RemoveVertexIf(VertexPredicate<TVertex>)
Removes all vertices matching the given predicate
.
Declaration
int RemoveVertexIf(VertexPredicate<TVertex> predicate)
Parameters
Type | Name | Description |
---|---|---|
VertexPredicate<TVertex> | predicate | Predicate to check on each vertex. |
Returns
Type | Description |
---|---|
System.Int32 | The number of vertex removed. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
Events
| Improve this Doc View SourceVertexAdded
Fired when a vertex is added to this set.
Declaration
event VertexAction<TVertex> VertexAdded
Event Type
Type | Description |
---|---|
VertexAction<TVertex> |
VertexRemoved
Fired when a vertex is removed from this set.
Declaration
event VertexAction<TVertex> VertexRemoved
Event Type
Type | Description |
---|---|
VertexAction<TVertex> |