chunks: drop pointless init of virtual base from abstract class
Change-Id: I8d47dc5bdcb1d12f808d729d71a2bbdc0b87daf4
This commit is contained in:
1 parent
887336ca8d
commit
06807dcdb4
7 files changed
+27
-35
No files matched your search
@@ -1,5 +1,5 @@
|
||||
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
|
||||
/**
|
||||
/*
|
||||
* Copyright (c) 2016-2017, Regents of the University of California,
|
||||
* Colorado State University,
|
||||
* University Pierre & Marie Curie, Sorbonne University.
|
||||
@@ -138,7 +138,8 @@ class DiscoverVersionDummy : public DiscoverVersion
|
||||
{
|
||||
public:
|
||||
DiscoverVersionDummy(const Name& prefix, Face& face, const Options& options)
|
||||
: DiscoverVersion(prefix, face, options)
|
||||
: Options(options)
|
||||
, DiscoverVersion(prefix, face)
|
||||
, isDiscoverRunning(false)
|
||||
, m_prefix(prefix)
|
||||
{
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
|
||||
/**
|
||||
* Copyright (c) 2016, Regents of the University of California,
|
||||
* Colorado State University,
|
||||
* University Pierre & Marie Curie, Sorbonne University.
|
||||
/*
|
||||
* Copyright (c) 2016-2017, Regents of the University of California,
|
||||
* Colorado State University,
|
||||
* University Pierre & Marie Curie, Sorbonne University.
|
||||
*
|
||||
* This file is part of ndn-tools (Named Data Networking Essential Tools).
|
||||
* See AUTHORS.md for complete list of ndn-tools authors and contributors.
|
||||
@@ -25,16 +25,12 @@
|
||||
|
||||
#include "discover-version-fixed.hpp"
|
||||
|
||||
#include <cmath>
|
||||
#include <boost/lexical_cast.hpp>
|
||||
|
||||
namespace ndn {
|
||||
namespace chunks {
|
||||
|
||||
DiscoverVersionFixed::DiscoverVersionFixed(const Name& prefix, Face& face, const Options& options)
|
||||
: Options(options)
|
||||
, DiscoverVersion(prefix, face, options)
|
||||
, m_strayExcludes()
|
||||
, DiscoverVersion(prefix, face)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
|
||||
/**
|
||||
* Copyright (c) 2016, Regents of the University of California,
|
||||
* Colorado State University,
|
||||
* University Pierre & Marie Curie, Sorbonne University.
|
||||
/*
|
||||
* Copyright (c) 2016-2017, Regents of the University of California,
|
||||
* Colorado State University,
|
||||
* University Pierre & Marie Curie, Sorbonne University.
|
||||
*
|
||||
* This file is part of ndn-tools (Named Data Networking Essential Tools).
|
||||
* See AUTHORS.md for complete list of ndn-tools authors and contributors.
|
||||
@@ -46,10 +46,9 @@ namespace chunks {
|
||||
*/
|
||||
class DiscoverVersionFixed : public DiscoverVersion
|
||||
{
|
||||
|
||||
public:
|
||||
/**
|
||||
* @brief create a DiscoverVersionSpecified service
|
||||
* @brief create a DiscoverVersionFixed service
|
||||
*/
|
||||
DiscoverVersionFixed(const Name& prefix, Face& face, const Options& options);
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
|
||||
/*
|
||||
* Copyright (c) 2016-2017, Regents of the University of California,
|
||||
* Colorado State University,
|
||||
* University Pierre & Marie Curie, Sorbonne University.
|
||||
* Copyright (c) 2016-2017, Regents of the University of California,
|
||||
* Colorado State University,
|
||||
* University Pierre & Marie Curie, Sorbonne University.
|
||||
*
|
||||
* This file is part of ndn-tools (Named Data Networking Essential Tools).
|
||||
* See AUTHORS.md for complete list of ndn-tools authors and contributors.
|
||||
@@ -34,10 +34,9 @@ namespace chunks {
|
||||
DiscoverVersionIterative::DiscoverVersionIterative(const Name& prefix, Face& face,
|
||||
const Options& options)
|
||||
: chunks::Options(options)
|
||||
, DiscoverVersion(prefix, face, options)
|
||||
, DiscoverVersion(prefix, face)
|
||||
, Options(options)
|
||||
, m_latestVersion(0)
|
||||
, m_latestVersionData(nullptr)
|
||||
, m_foundVersion(false)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
|
||||
/*
|
||||
* Copyright (c) 2016-2017, Regents of the University of California,
|
||||
* Colorado State University,
|
||||
* University Pierre & Marie Curie, Sorbonne University.
|
||||
* Copyright (c) 2016-2017, Regents of the University of California,
|
||||
* Colorado State University,
|
||||
* University Pierre & Marie Curie, Sorbonne University.
|
||||
*
|
||||
* This file is part of ndn-tools (Named Data Networking Essential Tools).
|
||||
* See AUTHORS.md for complete list of ndn-tools authors and contributors.
|
||||
@@ -43,16 +43,14 @@ class DiscoverVersionIterativeOptions : public virtual Options
|
||||
{
|
||||
public:
|
||||
explicit
|
||||
DiscoverVersionIterativeOptions(const Options& opt = Options())
|
||||
: Options(opt)
|
||||
, maxRetriesAfterVersionFound(0)
|
||||
, discoveryTimeout(time::milliseconds(300))
|
||||
DiscoverVersionIterativeOptions(const Options& opts = Options())
|
||||
: Options(opts)
|
||||
{
|
||||
}
|
||||
|
||||
public:
|
||||
int maxRetriesAfterVersionFound; // how many times to retry after a discoveryTimeout
|
||||
time::milliseconds discoveryTimeout; // timeout for version discovery
|
||||
int maxRetriesAfterVersionFound{0}; ///< how many times to retry after a discoveryTimeout
|
||||
time::milliseconds discoveryTimeout{300}; ///< timeout for version discovery
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
@@ -31,9 +31,8 @@
|
||||
namespace ndn {
|
||||
namespace chunks {
|
||||
|
||||
DiscoverVersion::DiscoverVersion(const Name& prefix, Face& face, const Options& options)
|
||||
: Options(options)
|
||||
, m_prefix(prefix)
|
||||
DiscoverVersion::DiscoverVersion(const Name& prefix, Face& face)
|
||||
: m_prefix(prefix)
|
||||
, m_face(face)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -62,7 +62,7 @@ public:
|
||||
/**
|
||||
* @brief create a DiscoverVersion service
|
||||
*/
|
||||
DiscoverVersion(const Name& prefix, Face& face, const Options& options);
|
||||
DiscoverVersion(const Name& prefix, Face& face);
|
||||
|
||||
virtual
|
||||
~DiscoverVersion();
|
||||
|
||||
Reference in new issue
Block a user