mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-16 10:01:47 +00:00
Apply modernize-use-equals-default
This commit is contained in:
committed by
Dennis Klein
parent
9444de5868
commit
6aeac265ec
@@ -81,7 +81,8 @@ class FairMQChannel
|
||||
// FairMQChannel& operator=(FairMQChannel&&) = delete;
|
||||
|
||||
/// Destructor
|
||||
virtual ~FairMQChannel() { /* LOG(warn) << "Destroying channel '" << fName << "'"; */ }
|
||||
virtual ~FairMQChannel() = default;
|
||||
// { LOG(warn) << "Destroying channel '" << fName << "'"; }
|
||||
|
||||
struct ChannelConfigurationError : std::runtime_error { using std::runtime_error::runtime_error; };
|
||||
|
||||
|
@@ -52,7 +52,7 @@ class FairMQMessage
|
||||
|
||||
virtual void Copy(const FairMQMessage& msg) = 0;
|
||||
|
||||
virtual ~FairMQMessage() {};
|
||||
virtual ~FairMQMessage() = default;
|
||||
|
||||
private:
|
||||
FairMQTransportFactory* fTransport{nullptr};
|
||||
|
@@ -24,7 +24,7 @@ class FairMQParts
|
||||
|
||||
public:
|
||||
/// Default constructor
|
||||
FairMQParts() {};
|
||||
FairMQParts() = default;
|
||||
/// Copy Constructor
|
||||
FairMQParts(const FairMQParts&) = delete;
|
||||
/// Move constructor
|
||||
@@ -35,7 +35,7 @@ class FairMQParts
|
||||
template <typename... Ts>
|
||||
FairMQParts(Ts&&... messages) { AddPart(std::forward<Ts>(messages)...); }
|
||||
/// Default destructor
|
||||
~FairMQParts() {};
|
||||
~FairMQParts() = default;
|
||||
|
||||
/// Adds part (FairMQMessage) to the container
|
||||
/// @param msg message pointer (for example created with NewMessage() method of FairMQDevice)
|
||||
|
@@ -22,7 +22,7 @@ class FairMQPoller
|
||||
virtual bool CheckInput(const std::string& channelKey, const int index) = 0;
|
||||
virtual bool CheckOutput(const std::string& channelKey, const int index) = 0;
|
||||
|
||||
virtual ~FairMQPoller() {};
|
||||
virtual ~FairMQPoller() = default;
|
||||
};
|
||||
|
||||
using FairMQPollerPtr = std::unique_ptr<FairMQPoller>;
|
||||
|
@@ -35,7 +35,7 @@ enum class TransferCode : int
|
||||
class FairMQSocket
|
||||
{
|
||||
public:
|
||||
FairMQSocket() {}
|
||||
FairMQSocket() = default;
|
||||
FairMQSocket(FairMQTransportFactory* fac) : fTransport(fac) {}
|
||||
|
||||
virtual std::string GetId() const = 0;
|
||||
@@ -76,7 +76,7 @@ class FairMQSocket
|
||||
FairMQTransportFactory* GetTransport() { return fTransport; }
|
||||
void SetTransport(FairMQTransportFactory* transport) { fTransport = transport; }
|
||||
|
||||
virtual ~FairMQSocket() {};
|
||||
virtual ~FairMQSocket() = default;
|
||||
|
||||
private:
|
||||
FairMQTransportFactory* fTransport{nullptr};
|
||||
|
@@ -122,7 +122,7 @@ class FairMQTransportFactory
|
||||
virtual void Resume() = 0;
|
||||
virtual void Reset() = 0;
|
||||
|
||||
virtual ~FairMQTransportFactory() {};
|
||||
virtual ~FairMQTransportFactory() = default;
|
||||
|
||||
static auto CreateTransportFactory(const std::string& type, const std::string& id = "", const fair::mq::ProgOptions* config = nullptr) -> std::shared_ptr<FairMQTransportFactory>;
|
||||
|
||||
|
@@ -27,7 +27,7 @@ enum class FairMQRegionEvent : int
|
||||
|
||||
struct FairMQRegionInfo
|
||||
{
|
||||
FairMQRegionInfo() {}
|
||||
FairMQRegionInfo() = default;
|
||||
|
||||
FairMQRegionInfo(bool _managed, uint64_t _id, void* _ptr, size_t _size, int64_t _flags, FairMQRegionEvent _event)
|
||||
: managed(_managed)
|
||||
@@ -63,7 +63,7 @@ using FairMQRegionEventCallback = std::function<void(FairMQRegionInfo)>;
|
||||
class FairMQUnmanagedRegion
|
||||
{
|
||||
public:
|
||||
FairMQUnmanagedRegion() {}
|
||||
FairMQUnmanagedRegion() = default;
|
||||
FairMQUnmanagedRegion(FairMQTransportFactory* factory) : fTransport(factory) {}
|
||||
|
||||
virtual void* GetData() const = 0;
|
||||
@@ -76,7 +76,7 @@ class FairMQUnmanagedRegion
|
||||
FairMQTransportFactory* GetTransport() { return fTransport; }
|
||||
void SetTransport(FairMQTransportFactory* transport) { fTransport = transport; }
|
||||
|
||||
virtual ~FairMQUnmanagedRegion() {};
|
||||
virtual ~FairMQUnmanagedRegion() = default;
|
||||
|
||||
private:
|
||||
FairMQTransportFactory* fTransport{nullptr};
|
||||
@@ -103,7 +103,7 @@ namespace fair::mq
|
||||
|
||||
struct RegionConfig
|
||||
{
|
||||
RegionConfig() {}
|
||||
RegionConfig() = default;
|
||||
|
||||
RegionConfig(bool l, bool z)
|
||||
: lock(l), zero(z)
|
||||
|
@@ -35,7 +35,7 @@ class ProgOptions
|
||||
{
|
||||
public:
|
||||
ProgOptions();
|
||||
virtual ~ProgOptions() {}
|
||||
virtual ~ProgOptions() = default;
|
||||
|
||||
void ParseAll(const std::vector<std::string>& cmdArgs, bool allowUnregistered);
|
||||
void ParseAll(const int argc, char const* const* argv, bool allowUnregistered = true);
|
||||
|
@@ -84,7 +84,7 @@ struct Machine_ : public state_machine_def<Machine_>
|
||||
, fNewStatePending(false)
|
||||
{}
|
||||
|
||||
virtual ~Machine_() {}
|
||||
virtual ~Machine_() = default;
|
||||
|
||||
// initial states
|
||||
using initial_state = bmpl::vector<IDLE_S, OK_S>;
|
||||
|
@@ -23,8 +23,8 @@ namespace fair::mq
|
||||
class StateQueue
|
||||
{
|
||||
public:
|
||||
StateQueue() {}
|
||||
~StateQueue() {}
|
||||
StateQueue() = default;
|
||||
~StateQueue() = default;
|
||||
|
||||
fair::mq::State WaitForNext()
|
||||
{
|
||||
|
@@ -29,7 +29,7 @@ namespace fair::mq
|
||||
class BenchmarkSampler : public Device
|
||||
{
|
||||
public:
|
||||
BenchmarkSampler() {}
|
||||
BenchmarkSampler() = default;
|
||||
|
||||
void InitTask() override
|
||||
{
|
||||
|
@@ -20,7 +20,7 @@ namespace fair::mq
|
||||
class Multiplier : public Device
|
||||
{
|
||||
public:
|
||||
Multiplier() {}
|
||||
Multiplier() = default;
|
||||
|
||||
protected:
|
||||
bool fMultipart = true;
|
||||
|
@@ -19,7 +19,7 @@ namespace fair::mq
|
||||
class Proxy : public Device
|
||||
{
|
||||
public:
|
||||
Proxy() {}
|
||||
Proxy() = default;
|
||||
|
||||
protected:
|
||||
bool fMultipart = true;
|
||||
|
@@ -25,7 +25,7 @@ namespace fair::mq
|
||||
class Sink : public Device
|
||||
{
|
||||
public:
|
||||
Sink() {}
|
||||
Sink() = default;
|
||||
|
||||
protected:
|
||||
bool fMultipart = false;
|
||||
|
@@ -19,7 +19,7 @@ namespace fair::mq
|
||||
class Splitter : public Device
|
||||
{
|
||||
public:
|
||||
Splitter() {}
|
||||
Splitter() = default;
|
||||
|
||||
protected:
|
||||
bool fMultipart = true;
|
||||
|
@@ -355,7 +355,7 @@ struct Cmds
|
||||
using container = std::vector<std::unique_ptr<Cmd>>;
|
||||
struct CommandFormatError : std::runtime_error { using std::runtime_error::runtime_error; };
|
||||
|
||||
explicit Cmds() {}
|
||||
explicit Cmds() = default;
|
||||
|
||||
template<typename... Rest>
|
||||
explicit Cmds(std::unique_ptr<Cmd>&& first, Rest&&... rest)
|
||||
|
@@ -187,7 +187,7 @@ using Uint16MsgDebugMapHashMap = boost::unordered_map<uint16_t, SizetMsgDebugMap
|
||||
|
||||
struct RegionBlock
|
||||
{
|
||||
RegionBlock() {}
|
||||
RegionBlock() = default;
|
||||
|
||||
RegionBlock(boost::interprocess::managed_shared_memory::handle_t handle, size_t size, size_t hint)
|
||||
: fHandle(handle)
|
||||
|
Reference in New Issue
Block a user