DiaDes
0.1
DIAgnosis of Discrete-Event System
|
#include <Edge.hh>
Public Types | |
typedef Diades::Utils::Exception< Edge > | Exception |
typedef EdgeData::EdgeId | EdgeId |
Public Member Functions | |
Constructors | |
Edge ()=default | |
Edge (const Edge &edge)=default | |
Edge (EdgeData *data) | |
~Edge ()=default | |
EdgeData * | data () |
Edge & | operator= (const Edge &edge)=default |
Edge & | operator= (Edge &&other)=default |
Accessors | |
Node | source () const |
Node | target () const |
const Node & | sourceRef () const |
const Node & | targetRef () const |
bool | valid () const |
bool | operator== (const Edge &edge) const |
bool | operator!= (const Edge &edge) const |
bool | operator< (const Edge &edge) const |
bool | operator> (const Edge &edge) const |
EdgeId | id () const |
const Graph & | owner () const |
int | memoryUsage () const |
Static Public Member Functions | |
static string | typeName () |
Private Member Functions | |
list< Edge >::iterator | sourcePos () const |
data associated with the current Edge More... | |
list< Edge >::iterator | targetPos () const |
void | create (EdgeId idt, NodeData *s, NodeData *t) |
void | destroy () |
void | changeSource (NodeData *s) |
void | changeTarget (NodeData *t) |
Private Attributes | |
EdgeData * | _eData |
Friends | |
class | Graph |
Edge is a friend class of Graph. More... | |
class | Node |
Edge is a friend of Node. More... | |
Stream operation | |
ostream & | operator<< (ostream &os, const Edge &edge) |
An Edge of a Graph defines an edge between a source Node and a target Node To associate an information with one Edge, you can use a EdgeMap<T>
typedef EdgeData::EdgeId Diades::Graph::Edge::EdgeId |
typedef Diades::Utils::Exception<Edge> Diades::Graph::Edge::Exception |
|
default |
Default constructor
Create an invalid transition.
Referenced by memoryUsage(), Diades::Graph::NodeData::newInEdge(), and Diades::Graph::NodeData::newOutEdge().
|
inline |
|
default |
Destructor
Referenced by Edge().
|
inlineprivate |
s | the new source of the edge (as a NodeData) |
Definition at line 129 of file EdgeImpl.hh.
References ensure, Diades::Graph::NodeData::newOutEdge(), Diades::Graph::NodeData::owner(), require, and Diades::Graph::Graph::valid().
Referenced by destroy().
|
inlineprivate |
s | the new target of the edge (as a NodeData) |
Definition at line 143 of file EdgeImpl.hh.
References ensure, Diades::Graph::NodeData::newInEdge(), Diades::Graph::NodeData::owner(), require, and Diades::Graph::Graph::valid().
Referenced by destroy().
idt | the identifier of the edge |
s | the source of the edge (as a NodeData) |
t | the target of the edge (as a NodeData) |
create an EdgeData for an edge from Node(s) to Node(t)
Definition at line 115 of file EdgeImpl.hh.
References Diades::Graph::EdgeData::EdgeData(), ensure, Diades::Graph::NodeData::newInEdge(), Diades::Graph::NodeData::newOutEdge(), Diades::Graph::NodeData::owner(), require, and Diades::Graph::Graph::valid().
Referenced by targetPos().
|
inline |
Definition at line 87 of file Edge.hh.
References _eData, operator=(), source(), sourceRef(), target(), targetRef(), and valid().
|
inlineprivate |
Destroy the EdgeData
Definition at line 241 of file Edge.hh.
References _eData, Diades::Graph::EdgeData::_source, Diades::Graph::EdgeData::_target, changeSource(), changeTarget(), Diades::Graph::NodeData::delInEdge(), Diades::Graph::NodeData::delOutEdge(), ensure, require, and valid().
|
inline |
Identifier of a Edge
Definition at line 177 of file Edge.hh.
References _eData, Diades::Graph::EdgeData::_identifier, owner(), require, and valid().
Referenced by Diades::Graph::hash_value(), operator<(), Diades::Graph::EdgeMap< Diades::Automata::FaultPattern::EventOccurrence >::operator[](), and Diades::Graph::ConstEdgeMap< ValueType >::operator[]().
|
inline |
|
inline |
Inequality operator
t | Edge to compare |
Definition at line 159 of file Edge.hh.
References operator<().
|
inline |
Order of Edge
Definition at line 93 of file EdgeImpl.hh.
References id(), Diades::Graph::Graph::id(), owner(), valid(), and Diades::Graph::Graph::valid().
Referenced by operator!=().
Move assignement (default)
other |
|
inline |
|
inline |
|
inline |
Owner of a transition
Definition at line 85 of file EdgeImpl.hh.
References require, and Diades::Graph::Graph::valid().
Referenced by id(), operator<(), Diades::Graph::EdgeMap< Diades::Automata::FaultPattern::EventOccurrence >::operator[](), Diades::Graph::Graph::source(), Diades::Graph::Graph::sourceRef(), Diades::Graph::Graph::target(), and Diades::Graph::Graph::targetRef().
|
inline |
source state
Definition at line 39 of file EdgeImpl.hh.
Referenced by data().
|
inlineprivate |
data associated with the current Edge
Definition at line 210 of file Edge.hh.
References Diades::Graph::EdgeData::_sourcePos, and require.
|
inline |
source state
Definition at line 56 of file EdgeImpl.hh.
Referenced by data().
|
inline |
target state
Definition at line 47 of file EdgeImpl.hh.
Referenced by data().
|
inlineprivate |
Definition at line 220 of file Edge.hh.
References Diades::Graph::EdgeData::_targetPos, create(), and require.
|
inline |
target state
Definition at line 65 of file EdgeImpl.hh.
Referenced by data().
|
inline |
Validity
Definition at line 72 of file EdgeImpl.hh.
Referenced by data(), destroy(), Diades::Graph::hash_value(), id(), operator<(), Diades::Graph::EdgeMap< Diades::Automata::FaultPattern::EventOccurrence >::operator[](), Diades::Graph::ConstEdgeMap< ValueType >::operator[](), Diades::Graph::Graph::source(), Diades::Graph::Graph::sourceRef(), Diades::Graph::Graph::target(), and Diades::Graph::Graph::targetRef().
|
friend |
|
private |
Definition at line 204 of file Edge.hh.
Referenced by data(), destroy(), id(), operator==(), Diades::Graph::Graph::source(), and Diades::Graph::Graph::sourceRef().