diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2017-04-05 02:32:06 +0200 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2017-04-23 02:03:47 +0200 |
commit | b57308e4a134fb6139d2cb52a031d3e7185f16cf (patch) | |
tree | 7c31d445e2f76bb737ef90ce29e0e7e6738d6eb1 /config | |
parent | 40b8ba5a3f34028d208d4e0dc1b46940d6fe5a47 (diff) |
Use override
Diffstat (limited to 'config')
-rw-r--r-- | config/src/apps/configproxy-cmd/main.cpp | 4 | ||||
-rw-r--r-- | config/src/apps/getvespaconfig/getconfig.cpp | 2 | ||||
-rw-r--r-- | config/src/apps/pingproxy/pingproxy.cpp | 2 | ||||
-rw-r--r-- | config/src/tests/configagent/configagent.cpp | 78 | ||||
-rw-r--r-- | config/src/tests/configretriever/configretriever.cpp | 4 | ||||
-rw-r--r-- | config/src/tests/frt/frt.cpp | 4 | ||||
-rw-r--r-- | config/src/tests/frtconnectionpool/frtconnectionpool.cpp | 4 | ||||
-rw-r--r-- | config/src/tests/subscription/subscription.cpp | 1 | ||||
-rw-r--r-- | config/src/tests/trace/trace.cpp | 4 |
9 files changed, 21 insertions, 82 deletions
diff --git a/config/src/apps/configproxy-cmd/main.cpp b/config/src/apps/configproxy-cmd/main.cpp index fcf2a0ca5d7..1d5934f2817 100644 --- a/config/src/apps/configproxy-cmd/main.cpp +++ b/config/src/apps/configproxy-cmd/main.cpp @@ -10,8 +10,8 @@ class Application : public FastOS_Application Flags _flags; bool parseOpts(); public: - void usage(void); - int Main(void) override; + void usage(); + int Main() override; Application() : _flags() {} }; diff --git a/config/src/apps/getvespaconfig/getconfig.cpp b/config/src/apps/getvespaconfig/getconfig.cpp index 23127b79333..df7bbba48b0 100644 --- a/config/src/apps/getvespaconfig/getconfig.cpp +++ b/config/src/apps/getvespaconfig/getconfig.cpp @@ -32,7 +32,7 @@ public: int usage(); void initRPC(const char *spec); void finiRPC(); - virtual int Main() override; + int Main() override; }; diff --git a/config/src/apps/pingproxy/pingproxy.cpp b/config/src/apps/pingproxy/pingproxy.cpp index 667d5689691..ba35892c03c 100644 --- a/config/src/apps/pingproxy/pingproxy.cpp +++ b/config/src/apps/pingproxy/pingproxy.cpp @@ -24,7 +24,7 @@ public: int usage(); void initRPC(const char *spec); void finiRPC(); - virtual int Main() override; + int Main() override; }; diff --git a/config/src/tests/configagent/configagent.cpp b/config/src/tests/configagent/configagent.cpp index 91b657b42f2..0693c33467d 100644 --- a/config/src/tests/configagent/configagent.cpp +++ b/config/src/tests/configagent/configagent.cpp @@ -1,5 +1,4 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -#include <vespa/fastos/fastos.h> #include <vespa/vespalib/testkit/test_kit.h> #include <vespa/config/config.h> #include <vespa/config/raw/rawsource.h> @@ -19,25 +18,10 @@ public: : _key(key) { } - const ConfigKey & getKey() const override - { - return _key; - } - - bool abort() override - { - return false; - } - - bool isAborted() const override - { - return false; - } - - void setError(int errorCode) override - { - (void) errorCode; - } + const ConfigKey & getKey() const override { return _key; } + bool abort() override { return false; } + bool isAborted() const override { return false; } + void setError(int errorCode) override { (void) errorCode; } const ConfigKey _key; }; @@ -57,51 +41,15 @@ public: _isError(iserror) { } - const ConfigKey& getKey() const override - { - return _key; - } - - const ConfigValue & getValue() const override - { - return _value; - } - - const ConfigState & getConfigState() const override - { - return _state; - } - - bool hasValidResponse() const override - { - return _valid; - } - - bool validateResponse() override - { - return _valid; - } - - void fill() override - { - _fillCalled = true; - } - - vespalib::string errorMessage() const override - { - return _errorMessage; - } - - int errorCode() const override - { - return _errorCode; - } - - bool isError() const override - { - return _isError; - } - + const ConfigKey& getKey() const override { return _key; } + const ConfigValue & getValue() const override { return _value; } + const ConfigState & getConfigState() const override { return _state; } + bool hasValidResponse() const override { return _valid; } + bool validateResponse() override { return _valid; } + void fill() override { _fillCalled = true; } + vespalib::string errorMessage() const override { return _errorMessage; } + int errorCode() const override { return _errorCode; } + bool isError() const override { return _isError; } const Trace & getTrace() const override { return _trace; } const ConfigKey _key; diff --git a/config/src/tests/configretriever/configretriever.cpp b/config/src/tests/configretriever/configretriever.cpp index bb4dda0e10e..8273eee2c73 100644 --- a/config/src/tests/configretriever/configretriever.cpp +++ b/config/src/tests/configretriever/configretriever.cpp @@ -1,7 +1,5 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -#include <vespa/fastos/fastos.h> -#include <vespa/log/log.h> -LOG_SETUP("configretriever"); + #include <vespa/vespalib/testkit/test_kit.h> #include <vespa/vespalib/data/slime/slime.h> #include <vespa/config/config.h> diff --git a/config/src/tests/frt/frt.cpp b/config/src/tests/frt/frt.cpp index 26f95df8f42..0de1908858f 100644 --- a/config/src/tests/frt/frt.cpp +++ b/config/src/tests/frt/frt.cpp @@ -1,7 +1,5 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -#include <vespa/fastos/fastos.h> -#include <vespa/log/log.h> -LOG_SETUP("frt"); + #include <vespa/vespalib/testkit/test_kit.h> #include <vespa/config/common/iconfigholder.h> #include <vespa/config/common/trace.h> diff --git a/config/src/tests/frtconnectionpool/frtconnectionpool.cpp b/config/src/tests/frtconnectionpool/frtconnectionpool.cpp index 96dad86a54d..b563ea1929b 100644 --- a/config/src/tests/frtconnectionpool/frtconnectionpool.cpp +++ b/config/src/tests/frtconnectionpool/frtconnectionpool.cpp @@ -1,7 +1,5 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -#include <vespa/fastos/fastos.h> -#include <vespa/log/log.h> -LOG_SETUP("frtconnectionpool_test"); + #include <vespa/vespalib/testkit/testapp.h> #include <vespa/config/frt/frtconnectionpool.h> #include <vespa/fnet/frt/error.h> diff --git a/config/src/tests/subscription/subscription.cpp b/config/src/tests/subscription/subscription.cpp index e47f8b11e60..5974279518a 100644 --- a/config/src/tests/subscription/subscription.cpp +++ b/config/src/tests/subscription/subscription.cpp @@ -1,5 +1,4 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -#include <vespa/fastos/fastos.h> #include <vespa/vespalib/testkit/test_kit.h> #include <vespa/config/common/misc.h> #include <vespa/config/common/configholder.h> diff --git a/config/src/tests/trace/trace.cpp b/config/src/tests/trace/trace.cpp index 566077d47e1..195f7d659a9 100644 --- a/config/src/tests/trace/trace.cpp +++ b/config/src/tests/trace/trace.cpp @@ -1,7 +1,5 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -#include <vespa/fastos/fastos.h> -#include <vespa/log/log.h> -LOG_SETUP("frt"); + #include <vespa/vespalib/testkit/test_kit.h> #include <vespa/config/common/trace.h> #include <vespa/vespalib/trace/tracenode.h> |