From 3c0be747595a4e6df146fc7aba0cc1d5359ba231 Mon Sep 17 00:00:00 2001 From: Bernhard Amann Date: Thu, 1 Aug 2013 14:13:20 -0700 Subject: [PATCH] 3 more functions to document. --- src/probabilistic/Topk.h | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/src/probabilistic/Topk.h b/src/probabilistic/Topk.h index 4f0599025d..48ca5c29a4 100644 --- a/src/probabilistic/Topk.h +++ b/src/probabilistic/Topk.h @@ -123,9 +123,30 @@ protected: TopkVal(); private: + /** + * Increment the counter for a specific element + * + * @param e element to increment counter for + * + * @param count increment counter by this much + */ void IncrementCounter(Element* e, unsigned int count = 1); - HashKey* GetHash(Val*) const; // this probably should go somewhere else. - void Typify(BroType*); + + /** + * get the hashkey for a specific value + * + * @param v value to generate key for + * + * @returns HashKey for value + */ + HashKey* GetHash(Val* v) const; // this probably should go somewhere else. + + /** + * Set the type that this TopK instance tracks + * + * @param t type that is tracked + */ + void Typify(BroType* t); BroType* type; CompositeHash* hash;