Browse Source

Comments

git-svn-id: svn://bind10.isc.org/svn/bind10/branches/trac440@3899 e5f2f494-b856-4b98-b285-d166d9295462
Michal Vaner 14 years ago
parent
commit
2c54cb72a9
1 changed files with 11 additions and 0 deletions
  1. 11 0
      src/lib/datasrc/zonetable.cc

+ 11 - 0
src/lib/datasrc/zonetable.cc

@@ -57,11 +57,21 @@ MemoryZone::find(const Name&, const RRType&) const {
     return (FindResult(NXDOMAIN, RRsetPtr()));
 }
 
+/// \short Private data and implementation of ZoneTable
 struct ZoneTable::ZoneTableImpl {
+    // Type aliases to make it shorter
     typedef RBTree<Zone> ZoneTree;
     typedef RBNode<Zone> ZoneNode;
+    // The actual storage
     ZoneTree zones;
 
+    /*
+     * The implementation methods are here and just wrap-called in the
+     * ZoneTable. We have variables locally (without impl_->), have
+     * type aliases, etc. And they will get inlined anyway.
+     */
+
+    // Implementation of ZoneTable::addZone
     result::Result addZone(ZonePtr zone) {
         // Sanity check
         if (!zone) {
@@ -102,6 +112,7 @@ struct ZoneTable::ZoneTableImpl {
         }
     }
 
+    // Implementation of ZoneTable::findZone
     ZoneTable::FindResult findZone(const Name& name) const {
         ZoneNode *node(NULL);
         result::Result my_result;