From 95f17c2ae374efa9e17f132950b29f00d0fbc0ab Mon Sep 17 00:00:00 2001 From: Toni Uhlig Date: Thu, 11 Nov 2021 14:36:14 +0100 Subject: Added override keyword to methods that *must* be implemented if they are derived from an interface. Signed-off-by: Toni Uhlig --- src/content/blog/Blog.hpp | 12 ++++++------ src/content/markdown/Markdown.hpp | 12 ++++++------ src/content/static/Static.hpp | 12 ++++++------ 3 files changed, 18 insertions(+), 18 deletions(-) (limited to 'src') diff --git a/src/content/blog/Blog.hpp b/src/content/blog/Blog.hpp index 637ea7b..5e59ec4 100644 --- a/src/content/blog/Blog.hpp +++ b/src/content/blog/Blog.hpp @@ -34,13 +34,13 @@ class Blog : public Content public: explicit Blog(std::string uriBasePath, std::string blogPath, std::string mainTemplatePath); - bool Init(); - void Shutdown(); - bool Render(RequestResponse & rr, RenderData & rd, std::string & out); + bool Init() override; + void Shutdown() override; + bool Render(RequestResponse & rr, RenderData & rd, std::string & out) override; - std::string & GetUriBasePath(); - std::string const & GetMainTemplate() const; - Redirections & GetRedirections(); + std::string & GetUriBasePath() override; + std::string const & GetMainTemplate() const override; + Redirections & GetRedirections() override; static bool ValidateAndSetMetdadata(BlogMetadata const & blogMetadata, BlogEntry & blogEntry); bool ValidateEntries(); diff --git a/src/content/markdown/Markdown.hpp b/src/content/markdown/Markdown.hpp index dfb6451..04b351c 100644 --- a/src/content/markdown/Markdown.hpp +++ b/src/content/markdown/Markdown.hpp @@ -12,13 +12,13 @@ public: explicit Markdown(std::string uriBasePath, std::string markdownFilesPath, std::string mainTemplatePath = ""); bool Init(std::string const & uriBasePath); - bool Init(); - void Shutdown(); - bool Render(RequestResponse & rr, RenderData & rd, std::string & out); + bool Init() override; + void Shutdown() override; + bool Render(RequestResponse & rr, RenderData & rd, std::string & out) override; - std::string & GetUriBasePath(); - std::string const & GetMainTemplate() const; - Redirections & GetRedirections(); + std::string & GetUriBasePath() override; + std::string const & GetMainTemplate() const override; + Redirections & GetRedirections() override; bool HasMarkdownFile(std::string filePath) const; bool HasMarkdownURI(std::string uriPath) const; diff --git a/src/content/static/Static.hpp b/src/content/static/Static.hpp index 8d702ec..94cb63b 100644 --- a/src/content/static/Static.hpp +++ b/src/content/static/Static.hpp @@ -9,13 +9,13 @@ class Static : public Content public: explicit Static(std::string uriBasePath, std::shared_ptr const & fs); - bool Init(); - void Shutdown(); - bool Render(RequestResponse & rr, RenderData & rd, std::string & out); + bool Init() override; + void Shutdown() override; + bool Render(RequestResponse & rr, RenderData & rd, std::string & out) override; - std::string & GetUriBasePath(); - std::string const & GetMainTemplate() const; - Redirections & GetRedirections(); + std::string & GetUriBasePath() override; + std::string const & GetMainTemplate() const override; + Redirections & GetRedirections() override; private: std::string m_UriBasePath; -- cgit v1.2.3