DiaDes  0.1
DIAgnosis of Discrete-Event System
MarkingGraph.hh
Go to the documentation of this file.
1 #ifndef __DIADES__PETRI_MARKINGGRAPH__HH__
2 #define __DIADES__PETRI_MARKINGGRAPH__HH__
4 #include<diades/graph/Graph.hh>
7 
8 namespace Diades
9 {
10  namespace Petri
11  {
12 
14  {
15  private:
17  const TwinPattern & _net;
19  public:
20  MarkingGraph(const TwinPattern & net):_net(net),_edgeLabel()
21  {
22 
23  _edgeLabel.init(*this);
24  }
25 
27 
28  const TwinPattern & net() const { return _net; }
29 
30 
32  {
33  return _table;
34  }
35 
36  const MarkingTable & table() const
37  {
38  return _table;
39  }
40 
42  {
44  _edgeLabel[edge] = label;
45  return edge;
46  }
47  void markingGraph2Dot(const string & filename);
48  };
49 
50 
51  };
52 };
53 
54 
55 
56 
57 #endif
Diades::Graph::Edge newEdge(Diades::Graph::Node source, Diades::Graph::Node target, const string &label)
Definition: MarkingGraph.hh:41
Edge newEdge(Node source, Node target)
const MarkingTable & table() const
Definition: MarkingGraph.hh:36
MarkingGraph(const TwinPattern &net)
Definition: MarkingGraph.hh:20
const TwinPattern & net() const
Definition: MarkingGraph.hh:28
Node source(const Edge &edge) const
Definition: GraphIntOld.hh:744
void markingGraph2Dot(const string &filename)
void init(Graph &g, SizeType capacity=0, ValueType dflt=ValueType())
Definition: EdgeMap.hh:314
Namespace of the Diades project.
Diades::Graph::EdgeMap< std::string > _edgeLabel
Definition: MarkingGraph.hh:18
const TwinPattern & _net
Definition: MarkingGraph.hh:17
Node target(const Edge &edge) const
Definition: GraphIntOld.hh:736