fix: Use namespaced typenames/headers

This commit is contained in:
Dennis Klein
2022-03-22 13:59:37 +01:00
parent 0959095a39
commit 12a85c6fb1
32 changed files with 114 additions and 116 deletions

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2018 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2018-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -17,7 +17,7 @@
namespace fair::mq::test
{
class ErrorState : public FairMQDevice
class ErrorState : public Device
{
public:
void Init() override

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2018 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2018-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -18,7 +18,7 @@
namespace fair::mq::test
{
class Exceptions : public FairMQDevice
class Exceptions : public Device
{
public:
auto Init() -> void override

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -17,7 +17,7 @@
namespace fair::mq::test
{
class PairLeft : public FairMQDevice
class PairLeft : public Device
{
protected:
auto InitTask() -> void override

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -17,7 +17,7 @@
namespace fair::mq::test
{
class PairRight : public FairMQDevice
class PairRight : public Device
{
protected:
auto InitTask() -> void override

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -15,7 +15,7 @@
namespace fair::mq::test
{
class PollOut : public FairMQDevice
class PollOut : public Device
{
protected:
auto InitTask() -> void override
@@ -25,8 +25,8 @@ class PollOut : public FairMQDevice
auto Run() -> void override
{
auto msg1 = FairMQMessagePtr{NewMessage()};
auto msg2 = FairMQMessagePtr{NewMessage()};
auto msg1 = NewMessage();
auto msg2 = NewMessage();
Send(msg1, "data1");
Send(msg2, "data2");
};

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -17,7 +17,7 @@
namespace fair::mq::test
{
class Pub : public FairMQDevice
class Pub : public Device
{
protected:
auto InitTask() -> void override
@@ -27,15 +27,15 @@ class Pub : public FairMQDevice
auto Run() -> void override
{
auto ready1 = FairMQMessagePtr{NewMessage()};
auto ready2 = FairMQMessagePtr{NewMessage()};
auto ready1 = NewMessage();
auto ready2 = NewMessage();
auto r1 = Receive(ready1, "control");
auto r2 = Receive(ready2, "control");
if (r1 >= 0 && r2 >= 0)
{
LOG(info) << "Received both ready signals, proceeding to publish data";
auto msg = FairMQMessagePtr{NewMessage()};
auto msg = NewMessage();
auto d1 = Send(msg, "data");
if (d1 >= 0)
{
@@ -46,8 +46,8 @@ class Pub : public FairMQDevice
LOG(error) << "Failed sending data: d1 = " << d1;
}
auto ack1 = FairMQMessagePtr{NewMessage()};
auto ack2 = FairMQMessagePtr{NewMessage()};
auto ack1 = NewMessage();
auto ack2 = NewMessage();
auto a1 = Receive(ack1, "control");
auto a2 = Receive(ack2, "control");
if (a1 >= 0 && a2 >= 0)

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -18,7 +18,7 @@ namespace fair::mq::test
using namespace std;
class Pull : public FairMQDevice
class Pull : public Device
{
protected:
auto InitTask() -> void override
@@ -28,7 +28,7 @@ class Pull : public FairMQDevice
auto Run() -> void override
{
auto msg = FairMQMessagePtr{NewMessage()};
auto msg = NewMessage();
if (Receive(msg, "data") >= 0)
{

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -15,7 +15,7 @@
namespace fair::mq::test
{
class Push : public FairMQDevice
class Push : public Device
{
protected:
auto InitTask() -> void override
@@ -25,7 +25,7 @@ class Push : public FairMQDevice
auto Run() -> void override
{
auto msg = FairMQMessagePtr{NewMessage()};
auto msg = NewMessage();
Send(msg, "data");
};
};

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -16,7 +16,7 @@
namespace fair::mq::test
{
class Rep : public FairMQDevice
class Rep : public Device
{
protected:
auto InitTask() -> void override
@@ -26,16 +26,16 @@ class Rep : public FairMQDevice
auto Run() -> void override
{
auto request1 = FairMQMessagePtr{NewMessage()};
auto request1 = NewMessage();
if (Receive(request1, "data") >= 0) {
LOG(info) << "Received request 1";
auto reply = FairMQMessagePtr{NewMessage()};
auto reply = NewMessage();
Send(reply, "data");
}
auto request2 = FairMQMessagePtr{NewMessage()};
auto request2 = NewMessage();
if (Receive(request2, "data") >= 0) {
LOG(info) << "Received request 2";
auto reply = FairMQMessagePtr{NewMessage()};
auto reply = NewMessage();
Send(reply, "data");
}

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -16,7 +16,7 @@
namespace fair::mq::test
{
class Req : public FairMQDevice
class Req : public Device
{
protected:
auto InitTask() -> void override
@@ -26,10 +26,10 @@ class Req : public FairMQDevice
auto Run() -> void override
{
auto request = FairMQMessagePtr{NewMessage()};
auto request = NewMessage();
Send(request, "data");
auto reply = FairMQMessagePtr{NewMessage()};
auto reply = NewMessage();
if (Receive(reply, "data") >= 0) {
LOG(info) << "received reply";
}

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2018 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2018-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -18,7 +18,7 @@
namespace fair::mq::test
{
class Signals : public FairMQDevice
class Signals : public Device
{
public:
void Init() override

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -17,7 +17,7 @@
namespace fair::mq::test
{
class Sub : public FairMQDevice
class Sub : public Device
{
protected:
auto InitTask() -> void override
@@ -27,17 +27,17 @@ class Sub : public FairMQDevice
auto Run() -> void override
{
auto ready = FairMQMessagePtr{NewMessage()};
auto ready = NewMessage();
auto r1 = Send(ready, "control");
if (r1 >= 0)
{
LOG(info) << "Sent first control signal";
auto msg = FairMQMessagePtr{NewMessage()};
auto msg = NewMessage();
auto d1 = Receive(msg, "data");
if (d1 >= 0)
{
LOG(info) << "Received data";
auto ack = FairMQMessagePtr{NewMessage()};
auto ack = NewMessage();
auto a1 = Send(ack, "control");
if (a1 >= 0)
{

View File

@@ -1,5 +1,5 @@
/********************************************************************************
* Copyright (C) 2015-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* Copyright (C) 2015-2022 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
* *
* This software is distributed under the terms of the *
* GNU Lesser General Public Licence (LGPL) version 3, *
@@ -17,7 +17,7 @@
namespace fair::mq::test
{
class TestWaitFor : public FairMQDevice
class TestWaitFor : public Device
{
public:
void PreRun() override