mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-15 01:26:47 +00:00
fairmq: Remove obsolete functions
This commit is contained in:
committed by
Dennis Klein
parent
d09be4ab79
commit
6275f4d267
@@ -482,32 +482,6 @@ void FairMQDevice::InitTaskWrapper()
|
|||||||
ChangeState(Transition::Auto);
|
ChangeState(Transition::Auto);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FairMQDevice::SortSocketsByAddress(const FairMQChannel &lhs, const FairMQChannel &rhs)
|
|
||||||
{
|
|
||||||
return lhs.fAddress < rhs.fAddress;
|
|
||||||
}
|
|
||||||
|
|
||||||
void FairMQDevice::SortChannel(const string& name, const bool reindex)
|
|
||||||
{
|
|
||||||
if (fChannels.find(name) != fChannels.end())
|
|
||||||
{
|
|
||||||
sort(fChannels.at(name).begin(), fChannels.at(name).end(), SortSocketsByAddress);
|
|
||||||
|
|
||||||
if (reindex)
|
|
||||||
{
|
|
||||||
for (auto vi = fChannels.at(name).begin(); vi != fChannels.at(name).end(); ++vi)
|
|
||||||
{
|
|
||||||
// set channel name: name + vector index
|
|
||||||
vi->fName = tools::ToString(name, "[", vi - fChannels.at(name).begin(), "]");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
LOG(error) << "Sorting failed: no channel with the name \"" << name << "\".";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void FairMQDevice::RunWrapper()
|
void FairMQDevice::RunWrapper()
|
||||||
{
|
{
|
||||||
LOG(info) << "DEVICE: Running...";
|
LOG(info) << "DEVICE: Running...";
|
||||||
|
@@ -115,11 +115,6 @@ class FairMQDevice
|
|||||||
/// Outputs the socket transfer rates
|
/// Outputs the socket transfer rates
|
||||||
virtual void LogSocketRates();
|
virtual void LogSocketRates();
|
||||||
|
|
||||||
/// Sorts a channel by address, with optional reindexing of the sorted values
|
|
||||||
/// @param name Channel name
|
|
||||||
/// @param reindex Should reindexing be done
|
|
||||||
void SortChannel(const std::string& name, const bool reindex = true);
|
|
||||||
|
|
||||||
template<typename Serializer, typename DataType, typename... Args>
|
template<typename Serializer, typename DataType, typename... Args>
|
||||||
void Serialize(FairMQMessage& msg, DataType&& data, Args&&... args) const
|
void Serialize(FairMQMessage& msg, DataType&& data, Args&&... args) const
|
||||||
{
|
{
|
||||||
@@ -312,11 +307,6 @@ class FairMQDevice
|
|||||||
return fConfig;
|
return fConfig;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Implements the sort algorithm used in SortChannel()
|
|
||||||
/// @param lhs Right hand side value for comparison
|
|
||||||
/// @param rhs Left hand side value for comparison
|
|
||||||
static bool SortSocketsByAddress(const FairMQChannel &lhs, const FairMQChannel &rhs);
|
|
||||||
|
|
||||||
// overload to easily bind member functions
|
// overload to easily bind member functions
|
||||||
template<typename T>
|
template<typename T>
|
||||||
void OnData(const std::string& channelName, bool (T::* memberFunction)(FairMQMessagePtr& msg, int index))
|
void OnData(const std::string& channelName, bool (T::* memberFunction)(FairMQMessagePtr& msg, int index))
|
||||||
|
Reference in New Issue
Block a user