mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-15 09:31:45 +00:00
FairMQ: Remove deprecated TransportFactory factory method
This commit is contained in:
committed by
Mohammad Al-Turany
parent
7cfd93c998
commit
9b7841e89e
@@ -1,11 +1,25 @@
|
||||
/********************************************************************************
|
||||
* Copyright (C) 2012-2017 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
|
||||
* Copyright (C) 2012-2018 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
|
||||
* *
|
||||
* This software is distributed under the terms of the *
|
||||
* GNU Lesser General Public Licence (LGPL) version 3, *
|
||||
* copied verbatim in the file "LICENSE" *
|
||||
********************************************************************************/
|
||||
|
||||
#include <FairMQSocket.h>
|
||||
#include <FairMQDevice.h>
|
||||
#include <FairMQLogger.h>
|
||||
#include <options/FairMQProgOptions.h>
|
||||
|
||||
#include <fairmq/Tools.h>
|
||||
#include <fairmq/Transports.h>
|
||||
|
||||
#include <boost/algorithm/string.hpp> // join/split
|
||||
|
||||
#include <boost/uuid/uuid.hpp>
|
||||
#include <boost/uuid/uuid_generators.hpp>
|
||||
#include <boost/uuid/uuid_io.hpp>
|
||||
|
||||
#include <list>
|
||||
#include <cstdlib>
|
||||
#include <stdexcept>
|
||||
@@ -14,24 +28,7 @@
|
||||
#include <mutex>
|
||||
#include <thread>
|
||||
#include <functional>
|
||||
|
||||
#include <boost/algorithm/string.hpp> // join/split
|
||||
|
||||
#include <boost/uuid/uuid.hpp>
|
||||
#include <boost/uuid/uuid_generators.hpp>
|
||||
#include <boost/uuid/uuid_io.hpp>
|
||||
|
||||
#include "FairMQSocket.h"
|
||||
#include "FairMQDevice.h"
|
||||
#include "FairMQLogger.h"
|
||||
#include <fairmq/Tools.h>
|
||||
|
||||
#include "options/FairMQProgOptions.h"
|
||||
#include "zeromq/FairMQTransportFactoryZMQ.h"
|
||||
#include "shmem/FairMQTransportFactorySHM.h"
|
||||
#ifdef NANOMSG_FOUND
|
||||
#include "nanomsg/FairMQTransportFactoryNN.h"
|
||||
#endif
|
||||
#include <sstream>
|
||||
|
||||
using namespace std;
|
||||
|
||||
@@ -804,39 +801,6 @@ shared_ptr<FairMQTransportFactory> FairMQDevice::AddTransport(const string& tran
|
||||
}
|
||||
}
|
||||
|
||||
unique_ptr<FairMQTransportFactory> FairMQDevice::MakeTransport(const string& transport)
|
||||
{
|
||||
unique_ptr<FairMQTransportFactory> tr;
|
||||
|
||||
if (transport == "zeromq")
|
||||
{
|
||||
tr = fair::mq::tools::make_unique<FairMQTransportFactoryZMQ>();
|
||||
}
|
||||
else if (transport == "shmem")
|
||||
{
|
||||
tr = fair::mq::tools::make_unique<FairMQTransportFactorySHM>();
|
||||
}
|
||||
#ifdef NANOMSG_FOUND
|
||||
else if (transport == "nanomsg")
|
||||
{
|
||||
tr = fair::mq::tools::make_unique<FairMQTransportFactoryNN>();
|
||||
}
|
||||
#endif
|
||||
else
|
||||
{
|
||||
LOG(error) << "Unavailable transport requested: " << "\"" << transport << "\"" << ". Available are: "
|
||||
<< "\"zeromq\""
|
||||
<< "\"shmem\""
|
||||
#ifdef NANOMSG_FOUND
|
||||
<< ", \"nanomsg\""
|
||||
#endif
|
||||
<< ". Returning nullptr.";
|
||||
return tr;
|
||||
}
|
||||
|
||||
return tr;
|
||||
}
|
||||
|
||||
void FairMQDevice::CreateOwnConfig()
|
||||
{
|
||||
// TODO: make fConfig a shared_ptr when no old user code has FairMQProgOptions ptr*
|
||||
|
Reference in New Issue
Block a user