|
GraphLibrary
0.0.1
A simple library that implements various graph algorithms.
|
Stores the properties of a Graph. More...
#include <Property.hpp>
Public Types | |
| using | idx_t = gl::index_type |
Public Member Functions | |
| Property (const idx_t &numNodes=0, const std::string &label="Graph") | |
| Property (const Property &)=default | |
| Copy constructor. More... | |
| Property (Property &&) noexcept=default | |
| Move constructor. More... | |
| Property & | operator= (const Property &)=default |
| Copy assignment. More... | |
| Property & | operator= (Property &&) noexcept=default |
| Move assignment. More... | |
| ~Property ()=default | |
| Destructor. More... | |
| bool | operator== (const Property &rhs) const |
| Check whether two propertes are equal. More... | |
| bool | operator!= (const Property &rhs) const |
| Check whether two propertes are not equal. More... | |
numNodes | |
Access to the number of nodes in the graph. | |
| idx_t | numNodes () const |
| Gets the number of nodes in the graph. More... | |
| void | numNodes (const idx_t &numNodes) |
| Allows changing the number of nodes in the graph. More... | |
| void | numNodesIncrement (const idx_t &increment=1) |
| Increments the number of nodes in the graph. More... | |
| void | numNodesDecrement (const idx_t &decrement=1) |
| Decrements the number of nodes in the graph. More... | |
numEdges | |
Access to the number of edges in the graph. | |
| idx_t | numEdges () const |
| Gets the number of edges in the graph. More... | |
| void | numEdges (const idx_t &numEdges) |
| Allows changing the number of edges in the graph. More... | |
| void | numEdgesIncrement (const idx_t &increment=1) |
| Increments the number of edges in the graph. More... | |
| void | numEdgesDecrement (const idx_t &decrement=1) |
| Decrements the number of edges in the graph. More... | |
Label | |
Access to label of the graph. | |
| std::string | label () const |
| Gets the label of the graph. More... | |
| void | label (const std::string &label) |
| Allows changing the label of the graph. More... | |
Private Attributes | |
| idx_t | numNodes_ |
| Number of nodes in the graph. More... | |
| idx_t | numEdges_ |
| Number of edges in the graph. More... | |
| std::string | label_ |
| Label of the graph. More... | |
Stores the properties of a Graph.
| using gl::Property::idx_t = gl::index_type |
|
inline |
|
default |
Copy constructor.
|
defaultnoexcept |
Move constructor.
|
default |
Destructor.
| bool gl::Property::operator== | ( | const Property & | rhs | ) | const |
Check whether two propertes are equal.
| bool gl::Property::operator!= | ( | const Property & | rhs | ) | const |
Check whether two propertes are not equal.
|
inline |
Gets the number of nodes in the graph.
|
inline |
Allows changing the number of nodes in the graph.
| [in] | numNodes | New value of node count. |
|
inline |
Increments the number of nodes in the graph.
| [in] | increment | Number of nodes that will be added to the graph. |
|
inline |
Decrements the number of nodes in the graph.
| [in] | decrement | Number of nodes that will be removed from the graph. |
|
inline |
Gets the number of edges in the graph.
|
inline |
Allows changing the number of edges in the graph.
| [in] | numEdges | New value of edge count. |
|
inline |
Increments the number of edges in the graph.
| [in] | increment | Number of nodes that will be added to the graph. |
|
inline |
Decrements the number of edges in the graph.
| [in] | decrement | Number of edges that will be removed from the graph. |
|
inline |
Gets the label of the graph.
|
inline |
Allows changing the label of the graph.
| [in] | label | New graph name. |
|
private |
Number of nodes in the graph.
|
private |
Number of edges in the graph.
|
private |
Label of the graph.