FSM Library - C++ version
Dfsm.h
1 /*
2  * Copyright. GaĆ«l Dottel, Christoph Hilken, and Jan Peleska 2016 - 2021
3  *
4  * Licensed under the EUPL V.1.1
5  */
6 #ifndef FSM_FSM_DFSM_H_
7 #define FSM_FSM_DFSM_H_
8 
9 #include <stdlib.h>
10 #include <time.h>
11 
12 #include <fstream>
13 #include <iostream>
14 #include <memory>
15 #include <string>
16 #include <vector>
17 
18 #include "fsm/DFSMTable.h"
19 #include "fsm/Fsm.h"
20 
21 class PkTable;
22 class IOTrace;
23 
24 class Dfsm : public Fsm
25 {
26 private:
27  //TODO
28  std::shared_ptr<DFSMTable> dfsmTable;
29 
30  //TODO
31  std::vector<std::shared_ptr<PkTable>> pktblLst;
32 
36  void createAtRandom();
37 
42  std::shared_ptr<DFSMTable> toDFSMTable() const;
43 public:
55  Dfsm(const std::string & fname, const std::string & fsmName, const int maxNodes, const int maxInput, const int maxOutput, const std::shared_ptr<FsmPresentationLayer> presentationLayer);
56 
67  Dfsm(const std::string & fsmName, const int maxNodes, const int maxInput, const int maxOutput, const std::shared_ptr<FsmPresentationLayer> presentationLayer);
68 
79  Dfsm(const std::string & fsmName, const int maxInput, const int maxOutput, const std::vector<std::shared_ptr<FsmNode>> lst, const std::shared_ptr<FsmPresentationLayer> presentationLayer);
80 
85  Dfsm(const Fsm & fsm);
86 
92  Dfsm minimise();
93 
99  void printTables() const;
100 
108 
118  IOTrace applyDet(const InputTrace & i);
119 
126  bool pass(const IOTrace & io);
127 
133  IOListContainer wMethod(const unsigned int m);
134 
135 
147  IOListContainer wpMethod(const int m);
148 };
149 #endif //FSM_FSM_DFSM_H_
Definition: IOTrace.h:15
Definition: Fsm.h:33
Dfsm(const std::string &fname, const std::string &fsmName, const int maxNodes, const int maxInput, const int maxOutput, const std::shared_ptr< FsmPresentationLayer > presentationLayer)
Definition: Dfsm.cpp:64
IOTrace applyDet(const InputTrace &i)
Definition: Dfsm.cpp:183
bool pass(const IOTrace &io)
Definition: Dfsm.cpp:212
void printTables() const
Definition: Dfsm.cpp:120
IOListContainer wpMethod(const int m)
Definition: Dfsm.cpp:243
Definition: IOListContainer.h:15
Definition: PkTable.h:24
IOListContainer getCharacterisationSet()
Definition: Dfsm.cpp:135
IOListContainer wMethod(const unsigned int m)
Definition: Dfsm.cpp:218
Definition: InputTrace.h:15
Dfsm minimise()
Definition: Dfsm.cpp:103
Definition: Dfsm.h:24