bioprocessing 6.0.4
bio::SetEdge< V > Class Template Reference

Edges: set implementation of non-oriented edges. More...

#include <bioprocessing/graph/setedge.h>

Inheritance diagram for bio::SetEdge< V >:
Collaboration diagram for bio::SetEdge< V >:

Public Types

typedef V Vertex
 Usable vertex type.
 
typedef SetEdgeRef< V > Edge
 Usable edge type.
 
typedef SetEdgeRef< V > Ref
 Reference type.
 
typedef VertexSet::const_iterator const_iterator
 
typedef VertexSet::iterator iterator
 
- Public Types inherited from bio::BaseEdge< V >
typedef V Vertex
 Vertex type.
 
typedef BaseEdgeRef< V > Edge
 Usable Edge type (RC)
 
typedef BaseEdgeRef< V > Ref
 Reference type.
 

Public Member Functions

 SetEdge (const Vertex &x, const Vertex &y)
 Constructor from a pair of vertices.
 
 SetEdge (const This &other)
 Copy constructor.
 
 SetEdge (const Base &other)
 Copy constructor from base class.
 
virtual ~SetEdge ()
 
const_iterator begin () const
 
const_iterator end () const
 
iterator begin ()
 
iterator end ()
 
Vertex x ()
 access the first vertex (x is the smaller vertex)
 
const Vertex x () const
 access the first vertex (x is the smaller vertex)
 
Vertex y ()
 access the second vertex (y is the bigger vertex)
 
const Vertex y () const
 access the second vertex (y is the bigger vertex)
 
Vertex other (const Vertex &v)
 access the vertex that is not v
 
const Vertex other (const Vertex &v) const
 access the vertex that is not v
 
virtual bool operator== (const This &other) const
 there is equality if both vertices are equal
 
virtual bool operator!= (const This &other) const
 there is equality if both vertices are equal
 
virtual bool operator> (const This &other) const
 For inequality we first look at x, and if they are equal, we look at y.
 
virtual bool operator< (const This &other) const
 For inequality we first look at x, and if they are equal, we look at y.
 
virtual bool operator>= (const This &other) const
 For inequality we first look at x, and if they are equal, we look at y.
 
virtual bool operator<= (const This &other) const
 For inequality we first look at x, and if they are equal, we look at y.
 
- Public Member Functions inherited from bio::BaseEdge< V >
virtual ~BaseEdge ()
 
virtual bool operator== (const This &other) const
 
virtual bool operator!= (const This &other) const
 
virtual bool operator> (const This &other) const
 
virtual bool operator< (const This &other) const
 
virtual bool operator>= (const This &other) const
 
virtual bool operator<= (const This &other) const
 

Public Attributes

VertexSet _set
 

Protected Types

typedef SetEdge< V > This
 Type of *this.
 
typedef BaseEdge< V > Base
 Base class type.
 
typedef std::set< V > VertexSet
 Vertex set type.
 
- Protected Types inherited from bio::BaseEdge< V >
typedef BaseEdge< V > This
 Type of *this.
 

Friends

class SetEdgeRef< V >
 

Detailed Description

template<typename V>
class bio::SetEdge< V >

Edges: set implementation of non-oriented edges.

This class implements an edge with a set of Vertex. By construction, this et is always of size 2.

It is templated on a vertex type (prefer a VertexRef type)

Definition at line 37 of file setedge.h.

Member Typedef Documentation

◆ Base

template<typename V>
typedef BaseEdge<V> bio::SetEdge< V >::Base
protected

Base class type.

Definition at line 42 of file setedge.h.

◆ const_iterator

template<typename V>
typedef VertexSet::const_iterator bio::SetEdge< V >::const_iterator

Definition at line 69 of file setedge.h.

◆ Edge

template<typename V>
typedef SetEdgeRef<V> bio::SetEdge< V >::Edge

Usable edge type.

Definition at line 46 of file setedge.h.

◆ iterator

template<typename V>
typedef VertexSet::iterator bio::SetEdge< V >::iterator

Definition at line 70 of file setedge.h.

◆ Ref

template<typename V>
typedef SetEdgeRef<V> bio::SetEdge< V >::Ref

Reference type.

Definition at line 47 of file setedge.h.

◆ This

template<typename V>
typedef SetEdge<V> bio::SetEdge< V >::This
protected

Type of *this.

Definition at line 41 of file setedge.h.

◆ Vertex

template<typename V>
typedef V bio::SetEdge< V >::Vertex

Usable vertex type.

Definition at line 45 of file setedge.h.

◆ VertexSet

template<typename V>
typedef std::set<V> bio::SetEdge< V >::VertexSet
protected

Vertex set type.

Definition at line 43 of file setedge.h.

Constructor & Destructor Documentation

◆ SetEdge() [1/3]

template<typename V>
bio::SetEdge< V >::SetEdge ( const Vertex & x,
const Vertex & y )
inline

Constructor from a pair of vertices.

Definition at line 52 of file setedge.h.

References _set, x(), and y().

◆ SetEdge() [2/3]

template<typename V>
bio::SetEdge< V >::SetEdge ( const This & other)
inline

Copy constructor.

Definition at line 58 of file setedge.h.

References _set, and other().

◆ SetEdge() [3/3]

template<typename V>
bio::SetEdge< V >::SetEdge ( const Base & other)
inline

Copy constructor from base class.

Definition at line 60 of file setedge.h.

References _set, and other().

◆ ~SetEdge()

template<typename V>
virtual bio::SetEdge< V >::~SetEdge ( )
inlinevirtual

Definition at line 65 of file setedge.h.

Member Function Documentation

◆ begin() [1/2]

template<typename V>
iterator bio::SetEdge< V >::begin ( )
inline

Definition at line 73 of file setedge.h.

References _set.

◆ begin() [2/2]

template<typename V>
const_iterator bio::SetEdge< V >::begin ( ) const
inline

Definition at line 71 of file setedge.h.

References _set.

Referenced by operator<(), operator>(), other(), other(), x(), x(), y(), and y().

◆ end() [1/2]

template<typename V>
iterator bio::SetEdge< V >::end ( )
inline

Definition at line 74 of file setedge.h.

References _set.

◆ end() [2/2]

template<typename V>
const_iterator bio::SetEdge< V >::end ( ) const
inline

Definition at line 72 of file setedge.h.

References _set.

Referenced by operator<(), and operator>().

◆ operator!=()

template<typename V>
virtual bool bio::SetEdge< V >::operator!= ( const This & other) const
inlinevirtual

there is equality if both vertices are equal

Definition at line 107 of file setedge.h.

References other(), x(), and y().

◆ operator<()

template<typename V>
virtual bool bio::SetEdge< V >::operator< ( const This & other) const
inlinevirtual

For inequality we first look at x, and if they are equal, we look at y.

(alphabetical ordering)

Definition at line 127 of file setedge.h.

References begin(), end(), and other().

◆ operator<=()

template<typename V>
virtual bool bio::SetEdge< V >::operator<= ( const This & other) const
inlinevirtual

For inequality we first look at x, and if they are equal, we look at y.

(alphabetical ordering)

Definition at line 147 of file setedge.h.

References other().

◆ operator==()

template<typename V>
virtual bool bio::SetEdge< V >::operator== ( const This & other) const
inlinevirtual

there is equality if both vertices are equal

Definition at line 102 of file setedge.h.

References other(), x(), and y().

◆ operator>()

template<typename V>
virtual bool bio::SetEdge< V >::operator> ( const This & other) const
inlinevirtual

For inequality we first look at x, and if they are equal, we look at y.

(alphabetical ordering)

Definition at line 113 of file setedge.h.

References begin(), end(), and other().

◆ operator>=()

template<typename V>
virtual bool bio::SetEdge< V >::operator>= ( const This & other) const
inlinevirtual

For inequality we first look at x, and if they are equal, we look at y.

(alphabetical ordering)

Definition at line 141 of file setedge.h.

References other().

◆ other() [1/2]

template<typename V>
Vertex bio::SetEdge< V >::other ( const Vertex & v)
inlinevirtual

access the vertex that is not v

Reimplemented from bio::BaseEdge< V >.

Definition at line 87 of file setedge.h.

References begin().

Referenced by operator!=(), operator<(), operator<=(), operator==(), operator>(), operator>=(), SetEdge(), and SetEdge().

◆ other() [2/2]

template<typename V>
const Vertex bio::SetEdge< V >::other ( const Vertex & v) const
inlinevirtual

access the vertex that is not v

Reimplemented from bio::BaseEdge< V >.

Definition at line 93 of file setedge.h.

References begin().

◆ x() [1/2]

template<typename V>
Vertex bio::SetEdge< V >::x ( )
inlinevirtual

access the first vertex (x is the smaller vertex)

Reimplemented from bio::BaseEdge< V >.

Definition at line 79 of file setedge.h.

References begin().

Referenced by operator!=(), operator==(), and SetEdge().

◆ x() [2/2]

template<typename V>
const Vertex bio::SetEdge< V >::x ( ) const
inlinevirtual

access the first vertex (x is the smaller vertex)

Reimplemented from bio::BaseEdge< V >.

Definition at line 81 of file setedge.h.

References begin().

◆ y() [1/2]

template<typename V>
Vertex bio::SetEdge< V >::y ( )
inlinevirtual

access the second vertex (y is the bigger vertex)

Reimplemented from bio::BaseEdge< V >.

Definition at line 83 of file setedge.h.

References begin().

Referenced by operator!=(), operator==(), and SetEdge().

◆ y() [2/2]

template<typename V>
const Vertex bio::SetEdge< V >::y ( ) const
inlinevirtual

access the second vertex (y is the bigger vertex)

Reimplemented from bio::BaseEdge< V >.

Definition at line 85 of file setedge.h.

References begin().

Friends And Related Symbol Documentation

◆ SetEdgeRef< V >

template<typename V>
friend class SetEdgeRef< V >
friend

Definition at line 153 of file setedge.h.

Member Data Documentation

◆ _set

template<typename V>
VertexSet bio::SetEdge< V >::_set

Definition at line 153 of file setedge.h.

Referenced by begin(), begin(), end(), end(), SetEdge(), SetEdge(), and SetEdge().


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