GraphDom
Loading...
Searching...
No Matches
graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType > Class Template Referencefinal

#include <full_labeled_set_digraph.h>

Inheritance diagram for graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >:
Collaboration diagram for graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >:

Public Member Functions

 full_labeled_set_digraph (const Compare &v_comp, const VertexLabellerType &v_lab, const EdgeLabellerType &e_lab)
 full_labeled_set_digraph (const Compare &v_comp, const VertexLabellerType &v_lab, EdgeLabellerType &&e_lab=EdgeLabellerType())
 full_labeled_set_digraph (const Compare &v_comp, VertexLabellerType &&v_lab, const EdgeLabellerType &e_lab)
 full_labeled_set_digraph (const Compare &v_comp, VertexLabellerType &&v_lab=VertexLabellerType(), EdgeLabellerType &&e_lab=EdgeLabellerType())
 full_labeled_set_digraph (Compare &&v_comp, const VertexLabellerType &v_lab, const EdgeLabellerType &e_lab)
 full_labeled_set_digraph (Compare &&v_comp, const VertexLabellerType &v_lab, EdgeLabellerType &&e_lab=EdgeLabellerType())
 full_labeled_set_digraph (Compare &&v_comp, VertexLabellerType &&v_lab, const EdgeLabellerType &e_lab)
 full_labeled_set_digraph (Compare &&v_comp, VertexLabellerType &&v_lab=VertexLabellerType(), EdgeLabellerType &&e_lab=EdgeLabellerType())
std::size_t order () const override
 Returns the order of *this, i.e. the number of vertices inside the graph.
const VertexLabelType & get_vertex_label (const typename graph< VertexType >::vertex_const_handle &vertex) const override
const EdgeLabelType & get_edge_label (const typename graph< VertexType >::adj_list_const_iterator &) const override
void erase_vertex (const typename graphdom::graph< VertexType >::vertex_const_handle &vertex) override
 Removes the vertex identified by vertex.
graphdom::graph< VertexType >::adj_list_iterator erase_edge (const typename graph< VertexType >::adj_list_const_iterator &) override
VertexLabelType & get_vertex_label (const typename graph< VertexType >::vertex_const_handle &vertex) override
std::pair< typename graph< VertexType >::vertex_handle, bool > insert_vertex (const VertexType &v_core, const VertexLabelType &vertex_label) override
std::pair< typename graph< VertexType >::vertex_handle, bool > insert_vertex (const VertexType &v_core, VertexLabelType &&vertex_label) override
std::pair< typename graph< VertexType >::vertex_handle, bool > insert_vertex (VertexType &&v_core, const VertexLabelType &vertex_label) override
std::pair< typename graph< VertexType >::vertex_handle, bool > insert_vertex (VertexType &&v_core, VertexLabelType &&vertex_label) override
EdgeLabelType & get_edge_label (const typename graph< VertexType >::adj_list_const_iterator &) override
void insert_edge (const typename graph< VertexType >::vertex_const_handle &tail, const typename graph< VertexType >::vertex_const_handle &head, const EdgeLabelType &edge_label) override
void insert_edge (const typename graph< VertexType >::vertex_const_handle &tail, const typename graph< VertexType >::vertex_const_handle &head, EdgeLabelType &&edge_label) override
Public Member Functions inherited from graphdom::labeled_vertex_set_graph< VertexType, VertexLabelType, VertexLabellerType >
 labeled_vertex_set_graph (const VertexLabellerType &)
 labeled_vertex_set_graph (VertexLabellerType &&)
 ~labeled_vertex_set_graph () override=default
 To be polymorphic, this class has a virtual destructor.
constexpr const VertexLabellerType & get_vertices_labeller () const
std::pair< typename graph< VertexType >::vertex_handle, bool > insert_vertex (const VertexType &v_core) final
std::pair< typename graph< VertexType >::vertex_handle, bool > insert_vertex (VertexType &&v_core) final
Public Member Functions inherited from graphdom::labeled_vertex_graph< VertexType, VertexLabelType >
 ~labeled_vertex_graph () override=default
 To be polymorphic, this class has a virtual destructor.
Public Member Functions inherited from graphdom::graph< VertexType >
virtual ~graph ()=default
 To be polymorphic, this class has a virtual destructor.
virtual void erase_vertex (const vertex_const_handle &vertex)=0
 Removes the vertex identified by vertex.
virtual adj_list_iterator erase_edge (const adj_list_const_iterator &)=0
Public Member Functions inherited from graphdom::set_graph< VertexType >
 ~set_graph () override=default
 To be polymorphic, this class has a virtual destructor.
Public Member Functions inherited from graphdom::labeled_edge_non_mixed_graph< VertexType, EdgeLabelType, EdgeLabellerType >
 labeled_edge_non_mixed_graph (const EdgeLabellerType &edge_labeller)
 labeled_edge_non_mixed_graph (EdgeLabellerType &&edge_labeller)
 ~labeled_edge_non_mixed_graph () override=default
 To be polymorphic, this class has a virtual destructor.
constexpr const EdgeLabellerType & get_edges_labeller () const
void insert_edge (const typename graph< VertexType >::vertex_const_handle &first_endpoint, const typename graph< VertexType >::vertex_const_handle &second_endpoint) final
Public Member Functions inherited from graphdom::labeled_edge_graph< VertexType, EdgeLabelType >
 ~labeled_edge_graph () override=default
 To be polymorphic, this class has a virtual destructor.
Public Member Functions inherited from graphdom::non_mixed_graph< VertexType >
 ~non_mixed_graph () override=default
 To be polymorphic, this class has a virtual destructor.

Detailed Description

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare = std::less<VertexType>, typename VertexLabellerType = default_vertex_labeller<VertexType,VertexLabelType>, typename EdgeLabellerType = default_edge_labeller<VertexType,EdgeLabelType>>
class graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >
Template Parameters
VertexType
VertexLabelType
EdgeLabelType
Compare
VertexLabellerType
EdgeLabellerType

Member Function Documentation

◆ erase_edge()

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
graphdom::graph< VertexType >::adj_list_iterator graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::erase_edge ( const typename graph< VertexType >::adj_list_const_iterator & edge_itr)
nodiscardoverride

◆ erase_vertex()

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
void graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::erase_vertex ( const typename graphdom::graph< VertexType >::vertex_const_handle & vertex)
override

Removes the vertex identified by vertex.

After erasion, vertex and all its equivalents are invalidated.

Parameters
vertexAn object that identifies the vertex to be erased.
vertex must be valid and must identify a vertex belonging to *this, otherwise the erasion will cause undefined behavior.

◆ get_edge_label() [1/2]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
const EdgeLabelType & graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::get_edge_label ( const typename graph< VertexType >::adj_list_const_iterator & edge) const
nodiscardoverridevirtual

◆ get_edge_label() [2/2]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
EdgeLabelType & graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::get_edge_label ( const typename graph< VertexType >::adj_list_const_iterator & edge)
nodiscardoverridevirtual

◆ get_vertex_label() [1/2]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
const VertexLabelType & graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::get_vertex_label ( const typename graph< VertexType >::vertex_const_handle & vertex) const
nodiscardoverridevirtual

If vertex is valid then returns a const reference to the label of the vertex identified by vertex (with respect to *this).

Parameters
vertexThis handle must be valid and must identify a vertex belonging to *this, otherwise this method will cause undefined behavior.
Returns
A const reference to label of the vertex identified by vertex (with respect to *this).
Complexity
Constant.

Implements graphdom::labeled_vertex_graph< VertexType, VertexLabelType >.

◆ get_vertex_label() [2/2]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
VertexLabelType & graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::get_vertex_label ( const typename graph< VertexType >::vertex_const_handle & vertex)
nodiscardoverridevirtual

If vertex is valid then returns a reference to the label of the vertex identified by vertex (with respect to *this).

Parameters
vertexThis handle must be valid and must identify a vertex belonging to *this, otherwise this method will cause undefined behavior.
Returns
A reference to label of the vertex identified by vertex (with respect to *this).
Complexity
Constant.

Implements graphdom::labeled_vertex_graph< VertexType, VertexLabelType >.

◆ insert_edge() [1/2]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
void graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::insert_edge ( const typename graph< VertexType >::vertex_const_handle & tail,
const typename graph< VertexType >::vertex_const_handle & head,
const EdgeLabelType & edge_label )
overridevirtual

Inserts in *this a directed edge having tail as tail and head as head, if *this doesn't already contain the same edge.
If and as soon as the insertion took place, the label of the inserted edge is equal to edge_label .

Parameters
tailThis handle must be valid and must identify a vertex belonging to *this, otherwise the insertion will cause undefined behavior.
headThis handle must be valid and must identify a vertex belonging to *this, otherwise the insertion will cause undefined behavior.
edge_labelIf and as soon as the insertion took place, the label of the inserted edge is equal to edge_label .

Implements graphdom::labeled_edge_non_mixed_graph< VertexType, EdgeLabelType, EdgeLabellerType >.

◆ insert_edge() [2/2]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
void graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::insert_edge ( const typename graph< VertexType >::vertex_const_handle & tail,
const typename graph< VertexType >::vertex_const_handle & head,
EdgeLabelType && edge_label )
overridevirtual

Inserts in *this a directed edge having tail as tail and head as head, if *this doesn't already contain the same edge.
If and as soon as the insertion took place, the label of the inserted edge is equal to edge_label .
If the insertion did not take place, edge_label remains unchanged.

Parameters
tailThis handle must be valid and must identify a vertex belonging to *this, otherwise the insertion will cause undefined behavior.
headThis handle must be valid and must identify a vertex belonging to *this, otherwise the insertion will cause undefined behavior.
edge_labelIf and as soon as the insertion took place, the label of the inserted edge is equal to edge_label .

Implements graphdom::labeled_edge_non_mixed_graph< VertexType, EdgeLabelType, EdgeLabellerType >.

◆ insert_vertex() [1/4]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
std::pair< typename graphdom::graph< VertexType >::vertex_handle, bool > graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::insert_vertex ( const VertexType & v_core,
const VertexLabelType & vertex_label )
nodiscardoverridevirtual

Inserts in *this a vertex having v_core as core, if *this doesn't already contain a vertex with an equivalent core.
If and as soon as the insertion took place, the label of the inserted vertex is equal to vertex_label .

Parameters
v_core
vertex_labelIf and as soon as the insertion took place, the label of the inserted vertex is equal to vertex_label .
Returns
A pair consisting of a valid handle of the inserted vertex (or the vertex that prevented the insertion) and a bool value set to true if and only if the insertion took place.
Complexity
Logarithmic in the order of the graph, O(log(this->order())).

Implements graphdom::labeled_vertex_set_graph< VertexType, VertexLabelType, VertexLabellerType >.

◆ insert_vertex() [2/4]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
std::pair< typename graphdom::graph< VertexType >::vertex_handle, bool > graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::insert_vertex ( const VertexType & v_core,
VertexLabelType && vertex_label )
nodiscardoverridevirtual

Inserts in *this a vertex having v_core as core, if *this doesn't already contain a vertex with an equivalent core.
If and as soon as the insertion took place, the label of the inserted vertex is equal to vertex_label .
If the insertion did not take place, vertex_label remains unchanged.

Parameters
v_core
vertex_labelIf and as soon as the insertion took place, the label of the inserted vertex is equal to vertex_label .
Returns
A pair consisting of a valid handle of the inserted vertex (or the vertex that prevented the insertion) and a bool value set to true if and only if the insertion took place.
Complexity
Logarithmic in the order of the graph, O(log(this->order())).

Implements graphdom::labeled_vertex_set_graph< VertexType, VertexLabelType, VertexLabellerType >.

◆ insert_vertex() [3/4]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
std::pair< typename graphdom::graph< VertexType >::vertex_handle, bool > graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::insert_vertex ( VertexType && v_core,
const VertexLabelType & vertex_label )
nodiscardoverridevirtual

Inserts in *this a vertex having v_core as core, if *this doesn't already contain a vertex with an equivalent core.
If and as soon as the insertion took place, the label of the inserted vertex is equal to vertex_label .
If the insertion did not take place, v_core remains unchanged.

Parameters
v_core
vertex_labelIf and as soon as the insertion took place, the label of the inserted vertex is equal to vertex_label .
Returns
A pair consisting of a valid handle of the inserted vertex (or the vertex that prevented the insertion) and a bool value set to true if and only if the insertion took place.
Complexity
Logarithmic in the order of the graph, O(log(this->order())).

Implements graphdom::labeled_vertex_set_graph< VertexType, VertexLabelType, VertexLabellerType >.

◆ insert_vertex() [4/4]

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
std::pair< typename graphdom::graph< VertexType >::vertex_handle, bool > graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::insert_vertex ( VertexType && v_core,
VertexLabelType && vertex_label )
nodiscardoverridevirtual

Inserts in *this a vertex having v_core as core, if *this doesn't already contain a vertex with an equivalent core.
If and as soon as the insertion took place, the label of the inserted vertex is equal to vertex_label .
If the insertion did not take place, v_core and vertex_label remain unchanged

Parameters
v_core
vertex_labelIf and as soon as the insertion took place, the label of the inserted vertex is equal to vertex_label .
Returns
A pair consisting of a valid handle of the inserted vertex (or the vertex that prevented the insertion) and a bool value set to true if and only if the insertion took place.
Complexity
Logarithmic in the order of the graph, O(log(this->order())).

Implements graphdom::labeled_vertex_set_graph< VertexType, VertexLabelType, VertexLabellerType >.

◆ order()

template<typename VertexType, typename VertexLabelType, typename EdgeLabelType, typename Compare, typename VertexLabellerType, typename EdgeLabellerType>
std::size_t graphdom::full_labeled_set_digraph< VertexType, VertexLabelType, EdgeLabelType, Compare, VertexLabellerType, EdgeLabellerType >::order ( ) const
nodiscardoverridevirtual

Returns the order of *this, i.e. the number of vertices inside the graph.

Returns
The number of vertices inside *this.
Complexity
Constant.

Implements graphdom::graph< VertexType >.


The documentation for this class was generated from the following files: