Browse Source

[2157] add description for CounterSpec

Yoshitaka Aharen 12 years ago
parent
commit
8c169e9a60
1 changed files with 6 additions and 0 deletions
  1. 6 0
      src/bin/auth/statistics_items.h.pre

+ 6 - 0
src/bin/auth/statistics_items.h.pre

@@ -23,8 +23,14 @@ namespace auth {
 namespace statistics {
 
 struct CounterSpec {
+    // item name: Name of this node. This appears in the spec file.
     const char* const name;
+    // sub counters: If this is a branch node, sub_counters points to
+    //               CounterSpec which contains child nodes. Otherwise, for
+    //               leaf nodes, sub_counters is NULL.
     const struct CounterSpec* const sub_counters;
+    // counter id: If this is a leaf node, counter_id is an enumerator of this
+    //             item. Otherwise, for branch nodes, counter_id is NOT_ITEM.
     const int counter_id;
 };