@@ -0,0 +1,552 @@
+package examples;%0A%0Aimport org.mapdb.*;%0A%0Aimport java.util.Map;%0A%0A/**%0A * Keep tracks of number of items in map.%0A * %3Cp/%3E%0A * Note: %7B@code Collections.size()%7D typically requires traversing entire collection in MapDB.%0A */%0Apublic class Map_Size_Counter %7B%0A%0A    public static void main(String%5B%5D args) %7B%0A%0A        DB db = DBMaker.newTempFileDB().make();%0A%0A        BTreeMap primary = db.getTreeMap(%22map%22);%0A        Atomic.Long sizeCounter = Atomic.getLong(db, %22mapSize%22);%0A%0A        Bind.size(primary, sizeCounter);%0A%0A        primary.put(%22111%22, %22some value%22);%0A%0A%0A    %7D%0A%0A%7D

Add map size counter example