You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datasketches.apache.org by al...@apache.org on 2020/03/19 15:27:21 UTC

[incubator-datasketches-cpp] branch fi_row created (now 9faa535)

This is an automated email from the ASF dual-hosted git repository.

alsay pushed a change to branch fi_row
in repository https://gitbox.apache.org/repos/asf/incubator-datasketches-cpp.git.


      at 9faa535  move class row back, it was moved accidentally

This branch includes the following new commits:

     new 9faa535  move class row back, it was moved accidentally

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org


[incubator-datasketches-cpp] 01/01: move class row back, it was moved accidentally

Posted by al...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

alsay pushed a commit to branch fi_row
in repository https://gitbox.apache.org/repos/asf/incubator-datasketches-cpp.git

commit 9faa5356997e2169d9c9f110dcb3d41e48e0a8eb
Author: AlexanderSaydakov <Al...@users.noreply.github.com>
AuthorDate: Thu Mar 19 08:26:48 2020 -0700

    move class row back, it was moved accidentally
---
 fi/include/frequent_items_sketch.hpp      | 15 +++++++++++++++
 fi/include/frequent_items_sketch_impl.hpp | 15 ---------------
 2 files changed, 15 insertions(+), 15 deletions(-)

diff --git a/fi/include/frequent_items_sketch.hpp b/fi/include/frequent_items_sketch.hpp
index 6b41baa..f494939 100644
--- a/fi/include/frequent_items_sketch.hpp
+++ b/fi/include/frequent_items_sketch.hpp
@@ -103,6 +103,21 @@ private:
   static inline void check_weight(WW weight);
 };
 
+template<typename T, typename W, typename H, typename E, typename S, typename A>
+class frequent_items_sketch<T, W, H, E, S, A>::row {
+public:
+  row(const T* item, W weight, W offset):
+    item(item), weight(weight), offset(offset) {}
+  const T& get_item() const { return *item; }
+  W get_estimate() const { return weight + offset; }
+  W get_lower_bound() const { return weight; }
+  W get_upper_bound() const { return weight + offset; }
+private:
+  const T* item;
+  W weight;
+  W offset;
+};
+
 }
 
 #include "frequent_items_sketch_impl.hpp"
diff --git a/fi/include/frequent_items_sketch_impl.hpp b/fi/include/frequent_items_sketch_impl.hpp
index 9609a2e..c70dc76 100644
--- a/fi/include/frequent_items_sketch_impl.hpp
+++ b/fi/include/frequent_items_sketch_impl.hpp
@@ -137,21 +137,6 @@ double frequent_items_sketch<T, W, H, E, S, A>::get_apriori_error(uint8_t lg_max
   return get_epsilon(lg_max_map_size) * estimated_total_weight;
 }
 
-template<typename T, typename W, typename H, typename E, typename S, typename A>
-class frequent_items_sketch<T, W, H, E, S, A>::row {
-public:
-  row(const T* item, W weight, W offset):
-    item(item), weight(weight), offset(offset) {}
-  const T& get_item() const { return *item; }
-  W get_estimate() const { return weight + offset; }
-  W get_lower_bound() const { return weight; }
-  W get_upper_bound() const { return weight + offset; }
-private:
-  const T* item;
-  W weight;
-  W offset;
-};
-
 
 template<typename T, typename W, typename H, typename E, typename S, typename A>
 typename frequent_items_sketch<T, W, H, E, S, A>::vector_row


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org