refactor(registry,util): use default contructors instead of empty

This commit is contained in:
Oleg Shparber 2019-01-26 22:45:24 -05:00
parent e114a7fc3c
commit 62b772089c
6 changed files with 3 additions and 16 deletions

View File

@ -32,10 +32,6 @@
using namespace Zeal::Registry;
DocsetMetadata::DocsetMetadata()
{
}
DocsetMetadata::DocsetMetadata(const QJsonObject &jsonObject)
{
m_name = jsonObject[QStringLiteral("name")].toString();

View File

@ -35,7 +35,7 @@ namespace Registry {
class DocsetMetadata
{
public:
explicit DocsetMetadata();
explicit DocsetMetadata() = default;
explicit DocsetMetadata(const QJsonObject &jsonObject);
void save(const QString &path, const QString &version);

View File

@ -32,10 +32,6 @@ const char prefixSeparator = ':';
const char keywordSeparator = ',';
}
SearchQuery::SearchQuery()
{
}
SearchQuery::SearchQuery(QString query, const QStringList &keywords) :
m_query(std::move(query))
{

View File

@ -35,7 +35,7 @@ namespace Registry {
class SearchQuery
{
public:
explicit SearchQuery();
explicit SearchQuery() = default;
explicit SearchQuery(QString query, const QStringList &keywords = QStringList());
/// Creates a search query from a string. Single separator will be

View File

@ -27,11 +27,6 @@
using namespace Zeal::Util;
Plist::Plist() :
QHash<QString, QVariant>()
{
}
bool Plist::read(const QString &fileName)
{
QScopedPointer<QFile> file(new QFile(fileName));

View File

@ -32,7 +32,7 @@ namespace Util {
class Plist : public QHash<QString, QVariant>
{
public:
Plist();
Plist() = default;
bool read(const QString &fileName);
bool hasError() const;