diff --git a/src/adjacency-list.cpp b/src/adjacency-list.cpp
index eead545..4ceaa82 100644
--- a/src/adjacency-list.cpp
+++ b/src/adjacency-list.cpp
@@ -87,7 +87,7 @@
 bool
 AdjacencyList::operator==(AdjacencyList& adl) const
 {
-  if (m_adjList.size() != adl.getSize()) {
+  if (size() != adl.size()) {
     return false;
   }
 
diff --git a/src/adjacency-list.hpp b/src/adjacency-list.hpp
index 5ed5012..6b8ea64 100644
--- a/src/adjacency-list.hpp
+++ b/src/adjacency-list.hpp
@@ -129,7 +129,7 @@
   operator==(AdjacencyList& adl) const;
 
   size_t
-  getSize()
+  size() const
   {
     return m_adjList.size();
   }
diff --git a/src/lsa.cpp b/src/lsa.cpp
index 440c2ba..ec27a35 100644
--- a/src/lsa.cpp
+++ b/src/lsa.cpp
@@ -68,7 +68,7 @@
 {
   std::ostringstream os;
   os << m_origRouter << "|" << NameLsa::TYPE_STRING << "|" << m_lsSeqNo << "|"
-     << ndn::time::toIsoString(m_expirationTimePoint) << "|" << m_npl.getSize();
+     << ndn::time::toIsoString(m_expirationTimePoint) << "|" << m_npl.size();
   for (const auto& name : m_npl.getNames()) {
     os << "|" << name;
   }
@@ -269,7 +269,7 @@
 {
   std::ostringstream os;
   os << m_origRouter << "|" << AdjLsa::TYPE_STRING << "|" << m_lsSeqNo << "|"
-     << ndn::time::toIsoString(m_expirationTimePoint) << "|" << m_adl.getSize();
+     << ndn::time::toIsoString(m_expirationTimePoint) << "|" << m_adl.size();
   for (const auto& adjacent : m_adl.getAdjList()) {
     os << "|" << adjacent.getName() << "|" << adjacent.getFaceUri()
        << "|" << adjacent.getLinkCost();
diff --git a/src/name-prefix-list.hpp b/src/name-prefix-list.hpp
index 5ec94ef..8351b3b 100644
--- a/src/name-prefix-list.hpp
+++ b/src/name-prefix-list.hpp
@@ -60,7 +60,7 @@
   sort();
 
   size_t
-  getSize()
+  size() const
   {
     return m_names.size();
   }
diff --git a/src/route/fib.cpp b/src/route/fib.cpp
index 7e19100..752b15a 100644
--- a/src/route/fib.cpp
+++ b/src/route/fib.cpp
@@ -96,7 +96,7 @@
   std::map<ndn::Name, FibEntry>::iterator entryIt = m_table.find(name);
 
   // New FIB entry that has nextHops
-  if (entryIt == m_table.end() && hopsToAdd.getSize() != 0) {
+  if (entryIt == m_table.end() && hopsToAdd.size() != 0) {
     _LOG_DEBUG("New FIB Entry");
 
     FibEntry entry(name);
@@ -113,7 +113,7 @@
     _LOG_DEBUG("Existing FIB Entry");
 
     // Remove empty FIB entry
-    if (hopsToAdd.getSize() == 0) {
+    if (hopsToAdd.size() == 0) {
       remove(name);
       return;
     }
diff --git a/src/route/name-prefix-table.cpp b/src/route/name-prefix-table.cpp
index 4f9d91d..52271ef 100644
--- a/src/route/name-prefix-table.cpp
+++ b/src/route/name-prefix-table.cpp
@@ -106,7 +106,7 @@
     npte->generateNhlfromRteList();
     m_table.push_back(npte);
     // If this entry has next hops, we need to inform the FIB
-    if (npte->getNexthopList().getSize() > 0) {
+    if (npte->getNexthopList().size() > 0) {
       _LOG_TRACE("Updating FIB with next hops for " << npte);
       m_nlsr.getFib().update(name, npte->getNexthopList());
     }
@@ -128,7 +128,7 @@
     (*nameItr)->addRoutingTableEntry(rtpePtr);
     (*nameItr)->generateNhlfromRteList();
 
-    if ((*nameItr)->getNexthopList().getSize() > 0) {
+    if ((*nameItr)->getNexthopList().size() > 0) {
       _LOG_TRACE("Updating FIB with next hops for " << (*nameItr));
       m_nlsr.getFib().update(name, (*nameItr)->getNexthopList());
     }
diff --git a/src/route/nexthop-list.cpp b/src/route/nexthop-list.cpp
index 903ca48..65f6782 100644
--- a/src/route/nexthop-list.cpp
+++ b/src/route/nexthop-list.cpp
@@ -44,7 +44,7 @@
 bool
 operator==(const NexthopList& lhs, const NexthopList& rhs)
 {
-  if (lhs.getSize() != rhs.getSize()) {
+  if (lhs.size() != rhs.size()) {
     return false;
   }
 
diff --git a/src/route/nexthop-list.hpp b/src/route/nexthop-list.hpp
index 1c35079..9ba0772 100644
--- a/src/route/nexthop-list.hpp
+++ b/src/route/nexthop-list.hpp
@@ -76,13 +76,7 @@
   removeNextHop(const NextHop& nh);
 
   size_t
-  getSize()
-  {
-    return m_nexthopList.size();
-  }
-
-  size_t
-  getSize() const
+  size() const
   {
     return m_nexthopList.size();
   }
diff --git a/tests/test-adjacency-list.cpp b/tests/test-adjacency-list.cpp
index 465fd9a..1488daa 100644
--- a/tests/test-adjacency-list.cpp
+++ b/tests/test-adjacency-list.cpp
@@ -19,9 +19,8 @@
  * NLSR, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
  **/
 
-#include "common.hpp"
-
 #include "adjacency-list.hpp"
+#include "common.hpp"
 #include "adjacent.hpp"
 #include "conf-parameter.hpp"
 
@@ -50,7 +49,7 @@
   adjacentList1.insert(adjacent1);
   adjacentList2.insert(adjacent2);
 
-  BOOST_CHECK_EQUAL(adjacentList1.getSize(), (uint32_t)1);
+  BOOST_CHECK_EQUAL(adjacentList1.size(), (uint32_t)1);
   BOOST_CHECK_EQUAL(adjacentList1 == adjacentList2, false);
 
   BOOST_CHECK(adjacentList1.isNeighbor("testname"));
diff --git a/tests/test-conf-file-processor.cpp b/tests/test-conf-file-processor.cpp
index df347f1..abcaefb 100644
--- a/tests/test-conf-file-processor.cpp
+++ b/tests/test-conf-file-processor.cpp
@@ -19,17 +19,15 @@
  * NLSR, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
  **/
 
+#include "conf-file-processor.hpp"
 #include "test-common.hpp"
 #include "logger.hpp"
-
-#include <fstream>
-#include "conf-file-processor.hpp"
 #include "nlsr.hpp"
 
+#include <fstream>
 #include <boost/test/unit_test.hpp>
 #include <boost/filesystem.hpp>
 #include <boost/algorithm/string.hpp>
-
 #include <ndn-cxx/util/dummy-client-face.hpp>
 
 namespace nlsr {
@@ -271,7 +269,7 @@
   BOOST_CHECK_EQUAL(conf.getRoutingCalcInterval(), 9);
 
   // Advertising
-  BOOST_CHECK_EQUAL(nlsr.getNamePrefixList().getSize(), 2);
+  BOOST_CHECK_EQUAL(nlsr.getNamePrefixList().size(), 2);
 }
 
 BOOST_AUTO_TEST_CASE(Log4cxxFileExists)
diff --git a/tests/test-lsa.cpp b/tests/test-lsa.cpp
index e501c59..2750bb4 100644
--- a/tests/test-lsa.cpp
+++ b/tests/test-lsa.cpp
@@ -19,14 +19,12 @@
  * NLSR, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
  **/
 
-#include "test-common.hpp"
-
-#include "adjacent.hpp"
 #include "lsa.hpp"
+#include "test-common.hpp"
+#include "adjacent.hpp"
 #include "name-prefix-list.hpp"
 
 #include <ndn-cxx/util/time.hpp>
-
 #include <sstream>
 
 namespace nlsr {
@@ -70,8 +68,8 @@
   activeAdjacencies.insert(activeAdjacency);
 
   AdjLsa alsa1(routerName, seqNo, testTimePoint,
-               activeAdjacencies.getSize(), activeAdjacencies);
-  BOOST_CHECK_EQUAL(alsa1.getAdl().getSize(), 1);
+               activeAdjacencies.size(), activeAdjacencies);
+  BOOST_CHECK_EQUAL(alsa1.getAdl().size(), 1);
   BOOST_CHECK_EQUAL(alsa1.getLsType(), AdjLsa::TYPE_STRING);
   BOOST_CHECK_EQUAL(alsa1.getLsSeqNo(), seqNo);
   BOOST_CHECK_EQUAL(alsa1.getExpirationTimePoint(), testTimePoint);
@@ -85,15 +83,15 @@
   inactiveAdjacencies.insert(inactiveAdjacency);
 
   AdjLsa alsa2(routerName, seqNo, testTimePoint,
-               inactiveAdjacencies.getSize(), inactiveAdjacencies);
-  BOOST_CHECK_EQUAL(alsa2.getAdl().getSize(), 0);
+               inactiveAdjacencies.size(), inactiveAdjacencies);
+  BOOST_CHECK_EQUAL(alsa2.getAdl().size(), 0);
 
   // Thus, the two LSAs should not have equal content
   BOOST_CHECK_EQUAL(alsa1.isEqualContent(alsa2), false);
 
   // Create a duplicate of alsa1 which should have equal content
   AdjLsa alsa3(routerName, seqNo, testTimePoint,
-               activeAdjacencies.getSize(), activeAdjacencies);
+               activeAdjacencies.size(), activeAdjacencies);
   BOOST_CHECK(alsa1.isEqualContent(alsa3));
 }
 
@@ -132,7 +130,7 @@
 
   const std::string TEST_TIME_POINT_STRING = ss.str();
 
-  AdjLsa lsa("router1", 12, testTimePoint, adjList.getSize(), adjList);
+  AdjLsa lsa("router1", 12, testTimePoint, adjList.size(), adjList);
 
   std::string EXPECTED_OUTPUT =
    "Adj Lsa:\n"
@@ -178,7 +176,7 @@
 
   ndn::time::system_clock::TimePoint testTimePoint = ndn::time::system_clock::now();
 
-  AdjLsa adjlsa1("router1", 1, testTimePoint, adjList.getSize(), adjList);
+  AdjLsa adjlsa1("router1", 1, testTimePoint, adjList.size(), adjList);
   AdjLsa adjlsa2;
 
   BOOST_CHECK(adjlsa2.initializeFromContent(adjlsa1.getData()));
diff --git a/tests/test-name-prefix-list.cpp b/tests/test-name-prefix-list.cpp
index eef0c18..080b259 100644
--- a/tests/test-name-prefix-list.cpp
+++ b/tests/test-name-prefix-list.cpp
@@ -39,11 +39,11 @@
   npl1.insert(a);
   npl1.insert(b);
 
-  BOOST_CHECK_EQUAL(npl1.getSize(), 2);
+  BOOST_CHECK_EQUAL(npl1.size(), 2);
 
   npl1.remove(b);
 
-  BOOST_CHECK_EQUAL(npl1.getSize(), 1);
+  BOOST_CHECK_EQUAL(npl1.size(), 1);
 }
 
 /*
diff --git a/tests/test-name-prefix-table.cpp b/tests/test-name-prefix-table.cpp
index 197cd98..474585c 100644
--- a/tests/test-name-prefix-table.cpp
+++ b/tests/test-name-prefix-table.cpp
@@ -298,7 +298,7 @@
   auto iterator = namePrefixTable.m_rtpool.find(destination);
   BOOST_REQUIRE(iterator != namePrefixTable.m_rtpool.end());
   auto nextHops = (iterator->second)->getNexthopList();
-  BOOST_CHECK_EQUAL(nextHops.getSize(), 2);
+  BOOST_CHECK_EQUAL(nextHops.size(), 2);
 
   // Add the other NextHop
   routingTable.addNextHop(destination, hop3);
@@ -313,7 +313,7 @@
   iterator = namePrefixTable.m_rtpool.find(destination);
   BOOST_REQUIRE(iterator != namePrefixTable.m_rtpool.end());
   nextHops = (iterator->second)->getNexthopList();
-  BOOST_CHECK_EQUAL(nextHops.getSize(), 3);
+  BOOST_CHECK_EQUAL(nextHops.size(), 3);
 }
 
 BOOST_AUTO_TEST_SUITE_END()
diff --git a/tests/test-nexthop-list.cpp b/tests/test-nexthop-list.cpp
index ce042c7..7d0c16d 100644
--- a/tests/test-nexthop-list.cpp
+++ b/tests/test-nexthop-list.cpp
@@ -36,10 +36,10 @@
   NexthopList nhl1;
 
   nhl1.addNextHop(np1);
-  BOOST_CHECK_EQUAL(nhl1.getSize(), (uint32_t)1);
+  BOOST_CHECK_EQUAL(nhl1.size(), (uint32_t)1);
 
   nhl1.removeNextHop(np1);
-  BOOST_CHECK_EQUAL(nhl1.getSize(), (uint32_t)0);
+  BOOST_CHECK_EQUAL(nhl1.size(), (uint32_t)0);
 }
 
 BOOST_AUTO_TEST_CASE(LinkStateRemoveNextHop)
@@ -53,13 +53,13 @@
   NextHop hop2;
   hop2.setRouteCost(13.01);
 
-  BOOST_REQUIRE_EQUAL(hopList.getSize(), 1);
+  BOOST_REQUIRE_EQUAL(hopList.size(), 1);
 
   hopList.removeNextHop(hop2);
-  BOOST_CHECK_EQUAL(hopList.getSize(), 1);
+  BOOST_CHECK_EQUAL(hopList.size(), 1);
 
   hopList.removeNextHop(hop1);
-  BOOST_CHECK_EQUAL(hopList.getSize(), 0);
+  BOOST_CHECK_EQUAL(hopList.size(), 0);
 }
 
 BOOST_AUTO_TEST_CASE(HyperbolicRemoveNextHop)
@@ -75,13 +75,13 @@
   hop2.setHyperbolic(true);
   hop2.setRouteCost(12.35);
 
-  BOOST_REQUIRE_EQUAL(hopList.getSize(), 1);
+  BOOST_REQUIRE_EQUAL(hopList.size(), 1);
 
   hopList.removeNextHop(hop2);
-  BOOST_CHECK_EQUAL(hopList.getSize(), 1);
+  BOOST_CHECK_EQUAL(hopList.size(), 1);
 
   hopList.removeNextHop(hop1);
-  BOOST_CHECK_EQUAL(hopList.getSize(), 0);
+  BOOST_CHECK_EQUAL(hopList.size(), 0);
 }
 
 BOOST_AUTO_TEST_CASE(TieBreaker)
@@ -139,7 +139,7 @@
   list.addNextHop(hopB);
   list.addNextHop(hopC);
 
-  BOOST_REQUIRE_EQUAL(list.getSize(), 3);
+  BOOST_REQUIRE_EQUAL(list.size(), 3);
 
   double lastCost = 0;
   for (const auto& hop : list) {
@@ -150,7 +150,7 @@
   // removing a hop keep the list sorted
   list.removeNextHop(hopA);
 
-  BOOST_REQUIRE_EQUAL(list.getSize(), 2);
+  BOOST_REQUIRE_EQUAL(list.size(), 2);
 
   lastCost = 0;
   for (const auto& hop : list) {
@@ -174,7 +174,7 @@
   list.addNextHop(hopA);
   list.addNextHop(hopB);
 
-  BOOST_REQUIRE_EQUAL(list.getSize(), 1);
+  BOOST_REQUIRE_EQUAL(list.size(), 1);
 
   for (const auto& hop : list) {
     BOOST_CHECK_EQUAL(hop, hopB);
diff --git a/tests/test-nlsr.cpp b/tests/test-nlsr.cpp
index 0159cf4..48cd7bf 100644
--- a/tests/test-nlsr.cpp
+++ b/tests/test-nlsr.cpp
@@ -283,7 +283,7 @@
   // Make sure the routing table was calculated
   RoutingTableEntry* rtEntry = nlsr.getRoutingTable().findRoutingTableEntry(failNeighbor.getName());
   BOOST_REQUIRE(rtEntry != nullptr);
-  BOOST_REQUIRE_EQUAL(rtEntry->getNexthopList().getSize(), 1);
+  BOOST_REQUIRE_EQUAL(rtEntry->getNexthopList().size(), 1);
 
   // Receive FaceEventDestroyed notification
   ndn::nfd::FaceEventNotification event;
@@ -394,7 +394,7 @@
   // Adjacency LSA should be built even though other router is INACTIVE
   AdjLsa* lsa = lsdb.findAdjLsa(lsaKey);
   BOOST_REQUIRE(lsa != nullptr);
-  BOOST_CHECK_EQUAL(lsa->getAdl().getSize(), 1);
+  BOOST_CHECK_EQUAL(lsa->getAdl().size(), 1);
 
   // Receive HELLO response from Router B
   receiveHelloData(neighborBName, conf.getRouterPrefix());
@@ -420,7 +420,7 @@
   // Adjacency LSA should be built
   lsa = lsdb.findAdjLsa(lsaKey);
   BOOST_REQUIRE(lsa != nullptr);
-  BOOST_CHECK_EQUAL(lsa->getAdl().getSize(), 2);
+  BOOST_CHECK_EQUAL(lsa->getAdl().size(), 2);
 }
 
 BOOST_AUTO_TEST_CASE(CanonizeUris)
diff --git a/tests/update/test-prefix-update-processor.cpp b/tests/update/test-prefix-update-processor.cpp
index 42d9fa0..8fb4c27 100644
--- a/tests/update/test-prefix-update-processor.cpp
+++ b/tests/update/test-prefix-update-processor.cpp
@@ -252,7 +252,7 @@
 
   NamePrefixList& namePrefixList = nlsr.getNamePrefixList();
 
-  BOOST_REQUIRE_EQUAL(namePrefixList.getSize(), 1);
+  BOOST_REQUIRE_EQUAL(namePrefixList.size(), 1);
   BOOST_CHECK_EQUAL(namePrefixList.getNames().front(), parameters.getName());
 
   BOOST_CHECK(wasRoutingUpdatePublished());
@@ -271,7 +271,7 @@
   face.receive(*withdrawInterest);
   this->advanceClocks(ndn::time::milliseconds(10));
 
-  BOOST_CHECK_EQUAL(namePrefixList.getSize(), 0);
+  BOOST_CHECK_EQUAL(namePrefixList.size(), 0);
 
   BOOST_CHECK(wasRoutingUpdatePublished());
   BOOST_CHECK(nameLsaSeqNoBeforeInterest < nlsr.getLsdb().getSequencingManager().getNameLsaSeq());
