Skip to content

Commit e7f5f1e

Browse files
committed
further namespace fixes
1 parent 1253696 commit e7f5f1e

File tree

8 files changed

+53
-53
lines changed

8 files changed

+53
-53
lines changed

include/maxplus/base/fsm/fsm.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -698,11 +698,11 @@ class FiniteStateMachine : public Abstract::FiniteStateMachine {
698698
return dynamic_cast<StateRef<StateLabelType, EdgeLabelType>>(*s);
699699
};
700700

701-
[[nodiscard]] const ::FSM::Abstract::SetOfStateRefs &getInitialStates() const override {
701+
[[nodiscard]] const ::MaxPlus::FSM::Abstract::SetOfStateRefs &getInitialStates() const override {
702702
return this->initialStates;
703703
};
704704

705-
[[nodiscard]] const ::FSM::Abstract::SetOfStateRefs &getFinalStates() const override {
705+
[[nodiscard]] const ::MaxPlus::FSM::Abstract::SetOfStateRefs &getFinalStates() const override {
706706
return this->finalStates;
707707
};
708708

@@ -736,8 +736,8 @@ class FiniteStateMachine : public Abstract::FiniteStateMachine {
736736
return this->states;
737737
};
738738

739-
[[nodiscard]] ::FSM::Abstract::SetOfStateRefs getStateRefs() const override {
740-
::FSM::Abstract::SetOfStateRefs result;
739+
[[nodiscard]] ::MaxPlus::FSM::Abstract::SetOfStateRefs getStateRefs() const override {
740+
::MaxPlus::FSM::Abstract::SetOfStateRefs result;
741741
for (const auto &s : this->states) {
742742
result.insert(s.second->getReference());
743743
}
@@ -1070,7 +1070,7 @@ class FiniteStateMachine : public Abstract::FiniteStateMachine {
10701070
}
10711071

10721072
[[nodiscard]] bool hasDirectedCycle() const {
1073-
::FSM::Abstract::DetectCycle DC(*this);
1073+
::MaxPlus::FSM::Abstract::DetectCycle DC(*this);
10741074
return DC.checkForCycles(nullptr);
10751075
}
10761076

include/maxplus/base/fsm/iofsm.h

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,18 @@
1010
using InputAction = MaxPlus::MPString;
1111
using OutputAction = MaxPlus::MPString;
1212
using IOAEdgeLabel = std::pair<InputAction, OutputAction>;
13-
using IOAState = ::FSM::Labeled::State<CId, IOAEdgeLabel>;
13+
using IOAState = ::MaxPlus::FSM::Labeled::State<CId, IOAEdgeLabel>;
1414
using IOAStateRef = const IOAState *;
15-
using IOAEdge = ::FSM::Labeled::Edge<CId, IOAEdgeLabel>;
16-
using IOAEdgeRef = ::FSM::Labeled::EdgeRef<CId, IOAEdgeLabel>;
17-
using IOASetOfStates = ::FSM::Labeled::SetOfStates<CId, IOAEdgeLabel>;
18-
using IOASetOfStateRefs = ::FSM::Labeled::SetOfStateRefs<CId, IOAEdgeLabel>;
19-
using IOASetOfEdges = ::FSM::Labeled::SetOfEdges<CId, IOAEdgeLabel>;
20-
using IOASetOfEdgeRefs = ::FSM::Labeled::SetOfEdgeRefs<CId, IOAEdgeLabel>;
15+
using IOAEdge = ::MaxPlus::FSM::Labeled::Edge<CId, IOAEdgeLabel>;
16+
using IOAEdgeRef = ::MaxPlus::FSM::Labeled::EdgeRef<CId, IOAEdgeLabel>;
17+
using IOASetOfStates = ::MaxPlus::FSM::Labeled::SetOfStates<CId, IOAEdgeLabel>;
18+
using IOASetOfStateRefs = ::MaxPlus::FSM::Labeled::SetOfStateRefs<CId, IOAEdgeLabel>;
19+
using IOASetOfEdges = ::MaxPlus::FSM::Labeled::SetOfEdges<CId, IOAEdgeLabel>;
20+
using IOASetOfEdgeRefs = ::MaxPlus::FSM::Labeled::SetOfEdgeRefs<CId, IOAEdgeLabel>;
2121

2222
namespace MaxPlus::FSM::Labeled {
2323

24-
class IOAutomaton : public ::FSM::Labeled::FiniteStateMachine<CId, IOAEdgeLabel> {
24+
class IOAutomaton : public ::MaxPlus::FSM::Labeled::FiniteStateMachine<CId, IOAEdgeLabel> {
2525
public:
2626
virtual ~IOAutomaton(){};
2727
};

include/maxplus/graph/doubleweightedgraph.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ using namespace ::MaxPlus::FSM::Labeled;
5454
* @tparam E edge label type
5555
*/
5656
template <typename SL, typename EL>
57-
class DoubleWeightedGraph : virtual public ::FSM::Labeled::FiniteStateMachine<SL, EL> {
57+
class DoubleWeightedGraph : virtual public ::MaxPlus::FSM::Labeled::FiniteStateMachine<SL, EL> {
5858
public:
5959
virtual ~DoubleWeightedGraph() = default;
6060

include/maxplus/graph/mpautomaton.h

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -143,20 +143,20 @@ inline MPAEdgeLabel makeMPAEdgeLabel(MPDelay delay, MPString &mode) {
143143
}
144144

145145
// Types for edges and states and sets.
146-
using MPAState = ::FSM::Labeled::State<MPAStateLabel, MPAEdgeLabel>;
147-
using MPAStateRef = ::FSM::Labeled::StateRef<MPAStateLabel, MPAEdgeLabel>;
148-
using MPAEdge = ::FSM::Labeled::Edge<MPAStateLabel, MPAEdgeLabel>;
149-
using MPAEdgeRef = ::FSM::Labeled::EdgeRef<MPAStateLabel, MPAEdgeLabel>;
146+
using MPAState = ::MaxPlus::FSM::Labeled::State<MPAStateLabel, MPAEdgeLabel>;
147+
using MPAStateRef = ::MaxPlus::FSM::Labeled::StateRef<MPAStateLabel, MPAEdgeLabel>;
148+
using MPAEdge = ::MaxPlus::FSM::Labeled::Edge<MPAStateLabel, MPAEdgeLabel>;
149+
using MPAEdgeRef = ::MaxPlus::FSM::Labeled::EdgeRef<MPAStateLabel, MPAEdgeLabel>;
150150
using MPAPath = std::list<MPAEdgeRef>;
151-
using MPASetOfStates = ::FSM::Labeled::SetOfStates<MPAStateLabel, MPAEdgeLabel>;
152-
using MPASetOfStateRefs = ::FSM::Labeled::SetOfStateRefs<MPAStateLabel, MPAEdgeLabel>;
153-
using MPASetOfEdges = ::FSM::Labeled::SetOfEdges<MPAStateLabel, MPAEdgeLabel>;
154-
using MPASetOfEdgeRefs = ::FSM::Labeled::SetOfEdgeRefs<MPAStateLabel, MPAEdgeLabel>;
151+
using MPASetOfStates = ::MaxPlus::FSM::Labeled::SetOfStates<MPAStateLabel, MPAEdgeLabel>;
152+
using MPASetOfStateRefs = ::MaxPlus::FSM::Labeled::SetOfStateRefs<MPAStateLabel, MPAEdgeLabel>;
153+
using MPASetOfEdges = ::MaxPlus::FSM::Labeled::SetOfEdges<MPAStateLabel, MPAEdgeLabel>;
154+
using MPASetOfEdgeRefs = ::MaxPlus::FSM::Labeled::SetOfEdgeRefs<MPAStateLabel, MPAEdgeLabel>;
155155

156156
/**
157157
* A max-plus automaton
158158
*/
159-
class MaxPlusAutomaton : public ::FSM::Labeled::FiniteStateMachine<MPAStateLabel, MPAEdgeLabel> {
159+
class MaxPlusAutomaton : public ::MaxPlus::FSM::Labeled::FiniteStateMachine<MPAStateLabel, MPAEdgeLabel> {
160160
public:
161161
// Destructor.
162162
~MaxPlusAutomaton() override = default;
@@ -214,20 +214,20 @@ inline MPString toString(const MPAREdgeLabel &l) {
214214
};
215215

216216
// Types of states, edges, sets and cycle of an MPA with rewards.
217-
using MPARState = ::FSM::Labeled::State<MPAStateLabel, MPAREdgeLabel>;
218-
using MPARStateRef = ::FSM::Labeled::StateRef<MPAStateLabel, MPAREdgeLabel>;
219-
using MPAREdge = ::FSM::Labeled::Edge<MPAStateLabel, MPAREdgeLabel>;
220-
using MPAREdgeRef = ::FSM::Labeled::EdgeRef<MPAStateLabel, MPAREdgeLabel>;
221-
using MPARSetOfStates = ::FSM::Labeled::SetOfStates<MPAStateLabel, MPAREdgeLabel>;
222-
using MPARSetOfEdges = ::FSM::Abstract::SetOfEdges;
223-
using MPARCycle = std::list<const ::FSM::Abstract::Edge *>;
217+
using MPARState = ::MaxPlus::FSM::Labeled::State<MPAStateLabel, MPAREdgeLabel>;
218+
using MPARStateRef = ::MaxPlus::FSM::Labeled::StateRef<MPAStateLabel, MPAREdgeLabel>;
219+
using MPAREdge = ::MaxPlus::FSM::Labeled::Edge<MPAStateLabel, MPAREdgeLabel>;
220+
using MPAREdgeRef = ::MaxPlus::FSM::Labeled::EdgeRef<MPAStateLabel, MPAREdgeLabel>;
221+
using MPARSetOfStates = ::MaxPlus::FSM::Labeled::SetOfStates<MPAStateLabel, MPAREdgeLabel>;
222+
using MPARSetOfEdges = ::MaxPlus::FSM::Abstract::SetOfEdges;
223+
using MPARCycle = std::list<const ::MaxPlus::FSM::Abstract::Edge *>;
224224

225225
/**
226226
* A max-plus automaton with rewards. In addition to the usual max-plus automaton,
227227
* its edges are labeled with rewards; a quantified amount of 'progress'.
228228
*/
229229
class MaxPlusAutomatonWithRewards
230-
: virtual public ::FSM::Labeled::FiniteStateMachine<MPAStateLabel, MPAREdgeLabel> {
230+
: virtual public ::MaxPlus::FSM::Labeled::FiniteStateMachine<MPAStateLabel, MPAREdgeLabel> {
231231
public:
232232
// Destructor.
233233
~MaxPlusAutomatonWithRewards() override = default;

include/maxplus/graph/mpstatespace.h

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -48,22 +48,22 @@
4848

4949
namespace MaxPlus {
5050

51-
using ELSState = ::FSM::Labeled::State<CId, MPString>;
52-
using ELSStateRef = ::FSM::Labeled::StateRef<CId, MPString>;
53-
using ELSEdge = ::FSM::Labeled::Edge<CId, MPString>;
54-
using ELSEdgeRef = ::FSM::Labeled::EdgeRef<CId, MPString>;
55-
using ELSSetOfStates = ::FSM::Labeled::SetOfStates<CId, MPString>;
56-
using ELSSetOfEdges = ::FSM::Labeled::SetOfEdges<CId, MPString>;
51+
using ELSState = ::MaxPlus::FSM::Labeled::State<CId, MPString>;
52+
using ELSStateRef = ::MaxPlus::FSM::Labeled::StateRef<CId, MPString>;
53+
using ELSEdge = ::MaxPlus::FSM::Labeled::Edge<CId, MPString>;
54+
using ELSEdgeRef = ::MaxPlus::FSM::Labeled::EdgeRef<CId, MPString>;
55+
using ELSSetOfStates = ::MaxPlus::FSM::Labeled::SetOfStates<CId, MPString>;
56+
using ELSSetOfEdges = ::MaxPlus::FSM::Labeled::SetOfEdges<CId, MPString>;
5757

5858
using MLSEdgeLabel = struct MLSEdgeLabel {
5959
Matrix *mat;
6060
CDouble rew;
6161
};
6262

63-
using MLSState = ::FSM::Labeled::State<CId, MLSEdgeLabel>;
64-
using MLSEdge = ::FSM::Labeled::Edge<CId, MLSEdgeLabel>;
65-
using MLSSetOfStates = ::FSM::Labeled::SetOfStates<CId, MLSEdgeLabel>;
66-
using MLSSetOfEdges = ::FSM::Abstract::SetOfEdges;
63+
using MLSState = ::MaxPlus::FSM::Labeled::State<CId, MLSEdgeLabel>;
64+
using MLSEdge = ::MaxPlus::FSM::Labeled::Edge<CId, MLSEdgeLabel>;
65+
using MLSSetOfStates = ::MaxPlus::FSM::Labeled::SetOfStates<CId, MLSEdgeLabel>;
66+
using MLSSetOfEdges = ::MaxPlus::FSM::Abstract::SetOfEdges;
6767

6868
} // namespace MaxPlus
6969

include/maxplus/graph/smpls.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ namespace MaxPlus::SMPLS {
5454

5555
using ModeMatrices = std::map<MPString, std::shared_ptr<MaxPlus::Matrix>>;
5656

57-
class EdgeLabeledModeFSM : public ::FSM::Labeled::FiniteStateMachine<CId, MPString> {
57+
class EdgeLabeledModeFSM : public ::MaxPlus::FSM::Labeled::FiniteStateMachine<CId, MPString> {
5858
public:
5959
// put the destructor deliberately into the cc sourc to ensure the class vtable is accessible
6060
// see: <https://stackoverflow.com/questions/3065154/undefined-reference-to-vtable>
@@ -153,7 +153,7 @@ class SMPLSwithEvents : public SMPLS {
153153
*/
154154
void isConsistentUtil(const IOAState &s,
155155
EventList &eventList,
156-
const ::FSM::Abstract::SetOfStateRefs &finalStates,
156+
const ::MaxPlus::FSM::Abstract::SetOfStateRefs &finalStates,
157157
MPString &errMsg,
158158
std::map<IOAStateRef, EventList> &visited);
159159

src/graph/mpautomaton.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ CDouble MaxPlusAutomatonWithRewards::calculateMCR() {
1313
MCMgraph g;
1414
CId nId = 0;
1515

16-
std::map<const ::FSM::Abstract::State *, MCMnode *> nodeMap;
16+
std::map<const ::MaxPlus::FSM::Abstract::State *, MCMnode *> nodeMap;
1717

1818
for (const auto &s : this->getStates()) {
1919
auto *n = g.addNode(nId++);
@@ -44,7 +44,7 @@ CDouble MaxPlusAutomatonWithRewards::calculateMCRAndCycle(
4444
MCMgraph g;
4545

4646
CId nId = 0;
47-
std::map<const ::FSM::Abstract::State *, MCMnode *> nodeMap;
47+
std::map<const ::MaxPlus::FSM::Abstract::State *, MCMnode *> nodeMap;
4848

4949
for (const auto &s : this->getStates()) {
5050
auto *n = g.addNode(nId++);

src/graph/smpls.cc

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@
88
using namespace FSM;
99
using namespace MaxPlus;
1010

11-
using ELSEdge = ::FSM::Labeled::Edge<CId, MPString>;
12-
using ELSEdgeRef = ::FSM::Labeled::EdgeRef<CId, MPString>;
13-
using ELSState = ::FSM::Labeled::State<CId, MPString>;
14-
using ELSStateRef = ::FSM::Labeled::StateRef<CId, MPString>;
15-
using ELSSetOfStates = ::FSM::Labeled::SetOfStates<CId, MPString>;
16-
using ELSSetOfEdges = ::FSM::Abstract::SetOfEdges;
17-
using ELSSetOfEdgeRefs = ::FSM::Abstract::SetOfEdgeRefs;
18-
using ELSSetOfStateRefs = ::FSM::Abstract::SetOfStateRefs;
11+
using ELSEdge = ::MaxPlus::FSM::Labeled::Edge<CId, MPString>;
12+
using ELSEdgeRef = ::MaxPlus::FSM::Labeled::EdgeRef<CId, MPString>;
13+
using ELSState = ::MaxPlus::FSM::Labeled::State<CId, MPString>;
14+
using ELSStateRef = ::MaxPlus::FSM::Labeled::StateRef<CId, MPString>;
15+
using ELSSetOfStates = ::MaxPlus::FSM::Labeled::SetOfStates<CId, MPString>;
16+
using ELSSetOfEdges = ::MaxPlus::FSM::Abstract::SetOfEdges;
17+
using ELSSetOfEdgeRefs = ::MaxPlus::FSM::Abstract::SetOfEdgeRefs;
18+
using ELSSetOfStateRefs = ::MaxPlus::FSM::Abstract::SetOfStateRefs;
1919

2020
namespace MaxPlus::SMPLS {
2121

0 commit comments

Comments
 (0)