delete undesired default members instead of making them inaccessible
This commit is contained in:
@ -15,8 +15,8 @@
|
|||||||
#define TEST_CONFIG_H
|
#define TEST_CONFIG_H
|
||||||
|
|
||||||
#include <set>
|
#include <set>
|
||||||
#include <string>
|
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
#include <string>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
@ -96,23 +96,21 @@ public:
|
|||||||
restart_vel.clear();
|
restart_vel.clear();
|
||||||
global_vector.clear();
|
global_vector.clear();
|
||||||
}
|
}
|
||||||
virtual ~TestConfig(){};
|
TestConfig(const TestConfig &) = delete;
|
||||||
|
TestConfig &operator=(const TestConfig &) = delete;
|
||||||
|
|
||||||
std::string tags_line() const
|
std::string tags_line() const
|
||||||
{
|
{
|
||||||
if(tags.size() > 0) {
|
if (tags.size() > 0) {
|
||||||
std::stringstream line;
|
std::stringstream line;
|
||||||
line << tags[0];
|
line << tags[0];
|
||||||
for(size_t i = 1; i < tags.size(); i++) {
|
for (size_t i = 1; i < tags.size(); i++) {
|
||||||
line << ", " << tags[i];
|
line << ", " << tags[i];
|
||||||
}
|
}
|
||||||
return line.str();
|
return line.str();
|
||||||
}
|
}
|
||||||
return "generated";
|
return "generated";
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
|
||||||
TestConfig(const TestConfig &){};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@ -22,6 +22,8 @@ class TestConfigReader : public YamlReader<TestConfigReader> {
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
TestConfigReader(TestConfig &config);
|
TestConfigReader(TestConfig &config);
|
||||||
|
TestConfigReader() = delete;
|
||||||
|
const TestConfigReader & operator=(TestConfig &) = delete;
|
||||||
|
|
||||||
void skip_tests(const yaml_event_t &event);
|
void skip_tests(const yaml_event_t &event);
|
||||||
void prerequisites(const yaml_event_t &event);
|
void prerequisites(const yaml_event_t &event);
|
||||||
|
|||||||
@ -22,6 +22,9 @@ class YamlWriter {
|
|||||||
public:
|
public:
|
||||||
YamlWriter(const char *outfile);
|
YamlWriter(const char *outfile);
|
||||||
virtual ~YamlWriter();
|
virtual ~YamlWriter();
|
||||||
|
YamlWriter() = delete;
|
||||||
|
YamlWriter(const YamlWriter &) = delete;
|
||||||
|
const YamlWriter & operator=(const YamlWriter &) = delete;
|
||||||
|
|
||||||
// emitters
|
// emitters
|
||||||
void emit(const std::string &key, const double value);
|
void emit(const std::string &key, const double value);
|
||||||
@ -34,10 +37,6 @@ private:
|
|||||||
FILE *fp;
|
FILE *fp;
|
||||||
yaml_emitter_t emitter;
|
yaml_emitter_t emitter;
|
||||||
yaml_event_t event;
|
yaml_event_t event;
|
||||||
|
|
||||||
private:
|
|
||||||
YamlWriter(){};
|
|
||||||
YamlWriter(const YamlWriter &){};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Reference in New Issue
Block a user