common: remove NDN_CXX_DECL_FINAL/OVERRIDE macros; use C++11 keywords directly

Change-Id: I8a6bc25a17574093addb144e6cdcc21dd24bbce4
Refs: #3599
diff --git a/src/common.hpp b/src/common.hpp
index a51f58d..bc34cbd 100644
--- a/src/common.hpp
+++ b/src/common.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2013-2015 Regents of the University of California.
+ * Copyright (c) 2013-2016 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -44,23 +44,9 @@
 #define NDN_CXX_PROTECTED_WITH_TESTS_ELSE_PRIVATE private
 #endif
 
-/** \def NDN_CXX_DECL_OVERRIDE
- *  \brief expands to 'override' if compiler supports this feature, otherwise expands to nothing
- */
-/** \def NDN_CXX_DECL_FINAL
- *  \brief expands to 'final' if compiler supports this feature, otherwise expands to nothing
- */
-#ifdef NDN_CXX_HAVE_CXX_OVERRIDE_FINAL
-#define NDN_CXX_DECL_OVERRIDE override
-#define NDN_CXX_DECL_FINAL final
-#else
-#define NDN_CXX_DECL_OVERRIDE
-#define NDN_CXX_DECL_FINAL
-#endif
-
 // require C++11
 #if __cplusplus < 201103L && !defined(__GXX_EXPERIMENTAL_CXX0X__)
-#  error "ndn-cxx applications must be compiled using the C++11 standard"
+#  error "ndn-cxx applications must be compiled using the C++11 standard (-std=c++11)"
 #endif
 
 #include <algorithm>
@@ -137,7 +123,7 @@
 
 namespace ndn {
 using boost::noncopyable;
-}
+} // namespace ndn
 
 #include "util/backports.hpp"
 
diff --git a/src/management/nfd-control-parameters.hpp b/src/management/nfd-control-parameters.hpp
index 93b2e41..c5f26d3 100644
--- a/src/management/nfd-control-parameters.hpp
+++ b/src/management/nfd-control-parameters.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2013-2015 Regents of the University of California.
+ * Copyright (c) 2013-2016 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -97,10 +97,10 @@
   wireEncode(EncodingImpl<TAG>& encoder) const;
 
   virtual Block
-  wireEncode() const NDN_CXX_DECL_FINAL;
+  wireEncode() const final;
 
   virtual void
-  wireDecode(const Block& wire) NDN_CXX_DECL_FINAL;
+  wireDecode(const Block& wire) final;
 
 public: // getters & setters
 
diff --git a/src/security/pib-memory.hpp b/src/security/pib-memory.hpp
index f21af00..377d52d 100644
--- a/src/security/pib-memory.hpp
+++ b/src/security/pib-memory.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2013-2015 Regents of the University of California.
+ * Copyright (c) 2013-2016 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -52,76 +52,76 @@
 public: // TpmLocator management
 
   virtual void
-  setTpmLocator(const std::string& tpmLocator) NDN_CXX_DECL_OVERRIDE;
+  setTpmLocator(const std::string& tpmLocator) override;
 
   virtual std::string
-  getTpmLocator() const NDN_CXX_DECL_OVERRIDE;
+  getTpmLocator() const override;
 
 public: // Identity management
 
   virtual bool
-  hasIdentity(const Name& identity) const NDN_CXX_DECL_OVERRIDE;
+  hasIdentity(const Name& identity) const override;
 
   virtual void
-  addIdentity(const Name& identity) NDN_CXX_DECL_OVERRIDE;
+  addIdentity(const Name& identity) override;
 
   virtual void
-  removeIdentity(const Name& identity) NDN_CXX_DECL_OVERRIDE;
+  removeIdentity(const Name& identity) override;
 
   virtual std::set<Name>
-  getIdentities() const NDN_CXX_DECL_OVERRIDE;
+  getIdentities() const override;
 
   virtual void
-  setDefaultIdentity(const Name& identityName) NDN_CXX_DECL_OVERRIDE;
+  setDefaultIdentity(const Name& identityName) override;
 
   virtual Name
-  getDefaultIdentity() const NDN_CXX_DECL_OVERRIDE;
+  getDefaultIdentity() const override;
 
 public: // Key management
 
   virtual bool
-  hasKey(const Name& identity, const name::Component& keyId) const NDN_CXX_DECL_OVERRIDE;
+  hasKey(const Name& identity, const name::Component& keyId) const override;
 
   virtual void
-  addKey(const Name& identity, const name::Component& keyId, const PublicKey& publicKey) NDN_CXX_DECL_OVERRIDE;
+  addKey(const Name& identity, const name::Component& keyId, const PublicKey& publicKey) override;
 
   virtual void
-  removeKey(const Name& identity, const name::Component& keyId) NDN_CXX_DECL_OVERRIDE;
+  removeKey(const Name& identity, const name::Component& keyId) override;
 
   virtual PublicKey
-  getKeyBits(const Name& identity, const name::Component& keyId) const NDN_CXX_DECL_OVERRIDE;
+  getKeyBits(const Name& identity, const name::Component& keyId) const override;
 
   virtual std::set<name::Component>
-  getKeysOfIdentity(const Name& identity) const NDN_CXX_DECL_OVERRIDE;
+  getKeysOfIdentity(const Name& identity) const override;
 
   virtual void
-  setDefaultKeyOfIdentity(const Name& identity, const name::Component& keyId) NDN_CXX_DECL_OVERRIDE;
+  setDefaultKeyOfIdentity(const Name& identity, const name::Component& keyId) override;
 
   virtual name::Component
-  getDefaultKeyOfIdentity(const Name& identity) const NDN_CXX_DECL_OVERRIDE;
+  getDefaultKeyOfIdentity(const Name& identity) const override;
 
 public: // Certificate management
 
   virtual bool
-  hasCertificate(const Name& certName) const NDN_CXX_DECL_OVERRIDE;
+  hasCertificate(const Name& certName) const override;
 
   virtual void
-  addCertificate(const IdentityCertificate& certificate) NDN_CXX_DECL_OVERRIDE;
+  addCertificate(const IdentityCertificate& certificate) override;
 
   virtual void
-  removeCertificate(const Name& certName) NDN_CXX_DECL_OVERRIDE;
+  removeCertificate(const Name& certName) override;
 
   virtual IdentityCertificate
-  getCertificate(const Name& certName) const NDN_CXX_DECL_OVERRIDE;
+  getCertificate(const Name& certName) const override;
 
   virtual std::set<Name>
-  getCertificatesOfKey(const Name& identity, const name::Component& keyId) const NDN_CXX_DECL_OVERRIDE;
+  getCertificatesOfKey(const Name& identity, const name::Component& keyId) const override;
 
   virtual void
-  setDefaultCertificateOfKey(const Name& identity, const name::Component& keyId, const Name& certName) NDN_CXX_DECL_OVERRIDE;
+  setDefaultCertificateOfKey(const Name& identity, const name::Component& keyId, const Name& certName) override;
 
   virtual IdentityCertificate
-  getDefaultCertificateOfKey(const Name& identity, const name::Component& keyId) const NDN_CXX_DECL_OVERRIDE;
+  getDefaultCertificateOfKey(const Name& identity, const name::Component& keyId) const override;
 
 private: // Key management
 
diff --git a/src/security/pib-sqlite3.hpp b/src/security/pib-sqlite3.hpp
index c63fb37..7e867cd 100644
--- a/src/security/pib-sqlite3.hpp
+++ b/src/security/pib-sqlite3.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2013-2015 Regents of the University of California.
+ * Copyright (c) 2013-2016 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -61,77 +61,77 @@
 public: // TpmLocator management
 
   virtual void
-  setTpmLocator(const std::string& tpmLocator) NDN_CXX_DECL_FINAL;
+  setTpmLocator(const std::string& tpmLocator) final;
 
   virtual std::string
-  getTpmLocator() const NDN_CXX_DECL_FINAL;
+  getTpmLocator() const final;
 
 public: // Identity management
 
   virtual bool
-  hasIdentity(const Name& identity) const NDN_CXX_DECL_FINAL;
+  hasIdentity(const Name& identity) const final;
 
   virtual void
-  addIdentity(const Name& identity) NDN_CXX_DECL_FINAL;
+  addIdentity(const Name& identity) final;
 
   virtual void
-  removeIdentity(const Name& identity) NDN_CXX_DECL_FINAL;
+  removeIdentity(const Name& identity) final;
 
   virtual std::set<Name>
-  getIdentities() const NDN_CXX_DECL_FINAL;
+  getIdentities() const final;
 
   virtual void
-  setDefaultIdentity(const Name& identityName) NDN_CXX_DECL_FINAL;
+  setDefaultIdentity(const Name& identityName) final;
 
   virtual Name
-  getDefaultIdentity() const NDN_CXX_DECL_FINAL;
+  getDefaultIdentity() const final;
 
 public: // Key management
 
   virtual bool
-  hasKey(const Name& identity, const name::Component& keyId) const NDN_CXX_DECL_FINAL;
+  hasKey(const Name& identity, const name::Component& keyId) const final;
 
   virtual void
-  addKey(const Name& identity, const name::Component& keyId, const PublicKey& publicKey) NDN_CXX_DECL_FINAL;
+  addKey(const Name& identity, const name::Component& keyId, const PublicKey& publicKey) final;
 
   virtual void
-  removeKey(const Name& identity, const name::Component& keyId) NDN_CXX_DECL_FINAL;
+  removeKey(const Name& identity, const name::Component& keyId) final;
 
   virtual PublicKey
-  getKeyBits(const Name& identity, const name::Component& keyId) const NDN_CXX_DECL_FINAL;
+  getKeyBits(const Name& identity, const name::Component& keyId) const final;
 
   virtual std::set<name::Component>
-  getKeysOfIdentity(const Name& identity) const NDN_CXX_DECL_FINAL;
+  getKeysOfIdentity(const Name& identity) const final;
 
   virtual void
-  setDefaultKeyOfIdentity(const Name& identity, const name::Component& keyId) NDN_CXX_DECL_FINAL;
+  setDefaultKeyOfIdentity(const Name& identity, const name::Component& keyId) final;
 
   virtual name::Component
-  getDefaultKeyOfIdentity(const Name& identity) const NDN_CXX_DECL_FINAL;
+  getDefaultKeyOfIdentity(const Name& identity) const final;
 
 public: // Certificate Management
 
   virtual bool
-  hasCertificate(const Name& certName) const NDN_CXX_DECL_FINAL;
+  hasCertificate(const Name& certName) const final;
 
   virtual void
-  addCertificate(const IdentityCertificate& certificate) NDN_CXX_DECL_FINAL;
+  addCertificate(const IdentityCertificate& certificate) final;
 
   virtual void
-  removeCertificate(const Name& certName) NDN_CXX_DECL_FINAL;
+  removeCertificate(const Name& certName) final;
 
   virtual IdentityCertificate
-  getCertificate(const Name& certName) const NDN_CXX_DECL_FINAL;
+  getCertificate(const Name& certName) const final;
 
   virtual std::set<Name>
-  getCertificatesOfKey(const Name& identity, const name::Component& keyId) const NDN_CXX_DECL_FINAL;
+  getCertificatesOfKey(const Name& identity, const name::Component& keyId) const final;
 
   virtual void
   setDefaultCertificateOfKey(const Name& identity, const name::Component& keyId,
-                             const Name& certName) NDN_CXX_DECL_FINAL;
+                             const Name& certName) final;
 
   virtual IdentityCertificate
-  getDefaultCertificateOfKey(const Name& identity, const name::Component& keyId) const NDN_CXX_DECL_FINAL;
+  getDefaultCertificateOfKey(const Name& identity, const name::Component& keyId) const final;
 
 private:
   sqlite3* m_database;