From the point of view of graph theory, vertices are treated as featureless and indivisible objects, although they may have additional structure depending on the application from which the graph arises;for instance, a semantic network is a graph in which the vertices represent concepts or classes of objects.
More...
#include <Vertex.h>
From the point of view of graph theory, vertices are treated as featureless and indivisible objects, although they may have additional structure depending on the application from which the graph arises;for instance, a semantic network is a graph in which the vertices represent concepts or classes of objects.
- Note
- The neighbour informartion has to be defined in a appropriated graph implementation.
Definition at line 68 of file Vertex.h.
te::graph::Vertex::Vertex |
( |
int |
id, |
|
|
bool |
isNew = true |
|
) |
| |
Constructor.
- Parameters
-
id | The vertex identifier |
isNew | Flag used to indicate that the element is new |
te::graph::Vertex::~Vertex |
( |
| ) |
|
Add a new attribute to this element.
- Parameters
-
idx | Index of the new attribute (must be a valid position) |
ad | AbstractData (can be any type of data) |
It returns the vector of attributes associated with this element.
- Returns
- A vector of AbstractData (can be any type of data)
int te::graph::Vertex::getId |
( |
| ) |
|
It returns the vertex id.
- Returns
- Integer with the vertex identifier
std::set<int>& te::graph::Vertex::getNeighborhood |
( |
| ) |
|
Returns the Neighborhood vector.
- Note
- This information only will be defined in the apropriated graph type
- Returns
- std::vector<int> reference
std::set<int>& te::graph::Vertex::getPredecessors |
( |
| ) |
|
Returns the Predecessors vector.
- Note
- This information only will be defined in the apropriated graph type
- Returns
- std::vector<int> reference
std::set<int>& te::graph::Vertex::getSuccessors |
( |
| ) |
|
Returns the Successors vector.
- Note
- This information only will be defined in the apropriated graph type
- Returns
- std::vector<int> reference
bool te::graph::Vertex::isDirty |
( |
| ) |
|
Used to verify the vertex state.
- Returns
- Boolean value used to indicate the vertex state
bool te::graph::Vertex::isNew |
( |
| ) |
|
Flag used to indicate that this element was a new one.
- Returns
- Boolean value used to indicate the vertex state
void te::graph::Vertex::removeAttribute |
( |
int |
idx | ) |
|
Remove a attribute associated with this element.
- Parameters
-
idx | Index of the attribute (must be a valid position) |
void te::graph::Vertex::setAttributeVecSize |
( |
int |
size | ) |
|
This function is used to set the number of attributes associated with the vertex elements.
- Parameters
-
size | Integer value to define the attribute size |
- Note
- Its important to use this method after a new property was associated to a edge Function defined in AbstractGraph addEdgeProperty.
void te::graph::Vertex::setDirty |
( |
bool |
flag | ) |
|
Flag used to indicate that this element was changed.
- Parameters
-
flag | Boolean value used to indicate the vertex state |
This is the list of all vertex attributes.
Definition at line 193 of file Vertex.h.
bool te::graph::Vertex::m_dirty |
|
protected |
Flag used to indicate that vertex was changed.
Definition at line 201 of file Vertex.h.
std::set<int> te::graph::Vertex::m_neighborhood |
|
protected |
List of all neighbors edges (used in undirectional graph).
Definition at line 199 of file Vertex.h.
bool te::graph::Vertex::m_new |
|
protected |
Flag used to indicate if this element is a new one.
Definition at line 203 of file Vertex.h.
std::set<int> te::graph::Vertex::m_predecessors |
|
protected |
List of all input edges (used in bidirectional graph).
Definition at line 195 of file Vertex.h.
std::set<int> te::graph::Vertex::m_successors |
|
protected |
List of all output edges (used in directional graph).
Definition at line 197 of file Vertex.h.
int te::graph::Vertex::m_vertexId |
|
protected |
This is the vertex unique identifier.
Definition at line 191 of file Vertex.h.
The documentation for this class was generated from the following file:
- /home/castejon/castejon_files/develop/terralib5/git_master/terralib5/src/terralib/graph/core/Vertex.h