|
Aleph-w 7.10.0
A C++ Library for Data Structures and Algorithms
|
Common attributes and methods for nodes (vertexes) belonging to graphs. More...
#include <graph-dry.H>
Public Types | |
| using | Item_Type = NodeInfo |
| using | Node = GTNodeCommon |
| Common alias for set types. | |
| using | Node_Type = NodeInfo |
| The node. | |
Public Member Functions | |
| GTNodeCommon () noexcept=default | |
| another alias for set type | |
| GTNodeCommon (const NodeInfo &info) | |
| Copy constructor from info value. | |
| GTNodeCommon (NodeInfo &&info) | |
| Move constructor from info value. | |
| GTNodeCommon (const GTNodeCommon &other) | |
| Copy constructor. | |
| GTNodeCommon (GTNodeCommon &&other) noexcept | |
| Move constructor. | |
| GTNodeCommon & | operator= (const GTNodeCommon &other) |
| Copy assignment operator. | |
| GTNodeCommon & | operator= (GTNodeCommon &&other) noexcept |
| Move assignment operator. | |
| NodeInfo & | get_info () noexcept |
| Return a modifiable reference to the data contained in the node. | |
| const NodeInfo & | get_info () const noexcept |
| Return a constant reference to the data contained in the node. | |
| unsigned int | state () const noexcept |
| Return the state's value. | |
| void | set_state (unsigned int s) noexcept |
Set the state to value s | |
Public Attributes | |
| Graph_Attr | attrs |
| Attributes of node. | |
| NodeInfo | node_info |
| size_t | num_arcs = 0 |
| data associated to the node. Access it with get_info() | |
Common attributes and methods for nodes (vertexes) belonging to graphs.
This class defines common attributes and methods for graphs. All graph nodes inherit the data and function members of this class. Although this class exports data members, it is not recommended to directly access them. Instead use the macros NODE_BITS, NODE_COUNTER and NODE_COOKIE, which define access to the three attributes.
Definition at line 693 of file graph-dry.H.
| using GTNodeCommon< NodeInfo >::Item_Type = NodeInfo |
Definition at line 715 of file graph-dry.H.
| using GTNodeCommon< NodeInfo >::Node = GTNodeCommon |
Common alias for set types.
Definition at line 717 of file graph-dry.H.
| using GTNodeCommon< NodeInfo >::Node_Type = NodeInfo |
The node.
Definition at line 719 of file graph-dry.H.
|
defaultnoexcept |
another alias for set type
Default constructor
|
inline |
Copy constructor from info value.
Definition at line 725 of file graph-dry.H.
|
inline |
Move constructor from info value.
Definition at line 728 of file graph-dry.H.
|
inline |
Copy constructor.
Definition at line 731 of file graph-dry.H.
|
inlinenoexcept |
Move constructor.
Definition at line 734 of file graph-dry.H.
|
inlinenoexcept |
Return a constant reference to the data contained in the node.
Definition at line 756 of file graph-dry.H.
References GTNodeCommon< NodeInfo >::node_info.
|
inlinenoexcept |
Return a modifiable reference to the data contained in the node.
Definition at line 753 of file graph-dry.H.
References GTNodeCommon< NodeInfo >::node_info.
Referenced by Aleph::__dfp_phase2_subgraph(), Aleph::__find_depth_first_spanning_tree(), Aleph::__map_subgraph(), Aleph::build_subgraph(), Aleph::Find_Depth_First_Spanning_Tree< GT, SA >::build_tree(), Aleph::Find_Breadth_First_Spanning_Tree< GT, SA >::build_tree(), check(), Aleph::AStar_Min_Path< GT, Distance, Heuristic, Itor, SA, HeapT >::compute_min_paths_tree(), Aleph::Dijkstra_Min_Paths< GT, Distance, Itor, SA, HeapT >::compute_min_paths_tree(), Aleph::AStar_Min_Path< GT, Distance, Heuristic, Itor, SA, HeapT >::compute_partial_min_paths_tree(), Aleph::Dijkstra_Min_Paths< GT, Distance, Itor, SA, HeapT >::compute_partial_min_paths_tree(), Aleph::AStar_Min_Path< GT, Distance, Heuristic, Itor, SA, HeapT >::compute_partial_path(), Aleph::Matrix_Graph< GT, SA >::copy(), Aleph::copy_graph(), Aleph::find_depth_first_spanning_tree(), main(), Aleph::Compute_Cut_Nodes< GT, SA >::map_cut_graph(), Aleph::Compute_Cut_Nodes< GT, SA >::map_subgraph(), Aleph::Dft_Node_Attr< GT >::operator()(), Aleph::Init_Prim_Info< GT >::operator()(), NodeInitializer::operator()(), EuclideanHeuristic::operator()(), ManhattanHeuristic::operator()(), Aleph::Init_P< GT >::operator()(), Aleph::Init_Arc< GT >::operator()(), Aleph::Dft_Load_Node< GT >::operator()(), Aleph::Rnode< GT >::operator()(), Aleph::Dft_Load_Node< GT >::operator()(), Aleph::Dft_Store_Node< GT >::operator()(), Aleph::Wnode< GT >::operator()(), Aleph::Dft_Store_Node< GT >::operator()(), Aleph::Euclidean_Heuristic< GT, Distance >::operator()(), Aleph::Manhattan_Heuristic< GT, Distance >::operator()(), ManhattanH< GT >::operator()(), Aleph::Chebyshev_Heuristic< GT, Distance >::operator()(), GT_Tree< GT >::operator()(), Aleph::Dft_Df_Tree_Label< GT >::operator()(), Aleph::Dft_Node_Cmp< GT >::operator()(), Aleph::Dft_Copy_Node< GTT, GTS >::operator()(), print_grid_with_path(), Aleph::Find_Depth_First_Spanning_Tree< GT, SA >::put_in_tree(), AStarGridTest::SetUp(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST_F(), TEST_F(), TEST_F(), TEST_F(), TEST_F(), Aleph::Karger_Min_Cut< GT, SA >::update_arcs(), and Aleph::Build_Subgraph< GT, SA >::visit().
|
inline |
Copy assignment operator.
Definition at line 737 of file graph-dry.H.
References GTNodeCommon< NodeInfo >::node_info.
|
inlinenoexcept |
Move assignment operator.
Definition at line 745 of file graph-dry.H.
References GTNodeCommon< NodeInfo >::node_info.
|
inlinenoexcept |
Set the state to value s
Definition at line 762 of file graph-dry.H.
References NODE_BITS.
Referenced by Graph_Traverse< GT, Itor, Q, Show_Arc >::exec(), Aleph::Directed_Find_Path< GT, Itor, SA >::find(), Graph_Traverse< GT, Itor, Q, Show_Arc >::operator()(), Graph_Traverse< GT, Itor, Q, Show_Arc >::operator()(), and Aleph::Graph_Traverse_Generator< GT, Itor, Q, Show_Arc >::traverse().
|
inlinenoexcept |
Return the state's value.
Definition at line 759 of file graph-dry.H.
References NODE_BITS.
Referenced by Graph_Traverse< GT, Itor, Q, Show_Arc >::exec(), Graph_Traverse< GT, Itor, Q, Show_Arc >::operator()(), Graph_Traverse< GT, Itor, Q, Show_Arc >::operator()(), and Aleph::Graph_Traverse_Generator< GT, Itor, Q, Show_Arc >::traverse().
| Graph_Attr GTNodeCommon< NodeInfo >::attrs |
| NodeInfo GTNodeCommon< NodeInfo >::node_info |
Definition at line 702 of file graph-dry.H.
Referenced by GTNodeCommon< NodeInfo >::get_info(), GTNodeCommon< NodeInfo >::get_info(), Aleph::Graph_Anode< Node_Info >::operator=(), Aleph::Graph_Node< __Node_Info >::operator=(), Aleph::Graph_Snode< Node_Info >::operator=(), GTNodeCommon< NodeInfo >::operator=(), and GTNodeCommon< NodeInfo >::operator=().
| size_t GTNodeCommon< NodeInfo >::num_arcs = 0 |
data associated to the node. Access it with get_info()
Number of arcs.
If the graph is directed, then this field does not have much sense, since it counts the total of arcs (incoming and outcoming).
Definition at line 713 of file graph-dry.H.
Referenced by Aleph::mat_path_detail::append_node(), Aleph::Graph_Anode< Node_Info >::compress(), Aleph::Graph_Anode< Node_Info >::contract_arc_array(), Aleph::Graph_Anode< Node_Info >::init(), Aleph::Graph_Anode< Node_Info >::insert_arc(), Aleph::Initialize_Dist< AM, Compare >::operator()(), Aleph::Graph_Anode< Node_Info >::remove_arc(), Aleph::Graph_Anode< Node_Info >::remove_arc_ne(), Aleph::search_arc(), Aleph::search_spanning_tree_arc(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), and TEST().