[Groonga-commit] groonga/grnxx at 51d56cd [master] Rename result_set to results.

Back to archive index

susumu.yata null+****@clear*****
Mon Aug 4 15:55:48 JST 2014


susumu.yata	2014-08-04 15:55:48 +0900 (Mon, 04 Aug 2014)

  New Revision: 51d56cd9770da94551805c2d51264910ea7d81af
  https://github.com/groonga/grnxx/commit/51d56cd9770da94551805c2d51264910ea7d81af

  Message:
    Rename result_set to results.

  Modified files:
    include/grnxx/expression.hpp
    lib/grnxx/expression.cpp

  Modified: include/grnxx/expression.hpp (+2 -2)
===================================================================
--- include/grnxx/expression.hpp    2014-08-04 13:21:32 +0900 (3c371b7)
+++ include/grnxx/expression.hpp    2014-08-04 15:55:48 +0900 (6b24a43)
@@ -103,7 +103,7 @@ class Expression {
 
   // Evaluate the expression.
   //
-  // The result is stored into "*result_set".
+  // The result is stored into "*results".
   //
   // Returns true on success.
   // On failure, returns false and stores error information into "*error" if
@@ -111,7 +111,7 @@ class Expression {
   template <typename T>
   bool evaluate(Error *error,
                 const RecordSubset &record_set,
-                Array<T> *result_set);
+                Array<T> *results);
 
  private:
   const Table *table_;

  Modified: lib/grnxx/expression.cpp (+10 -10)
===================================================================
--- lib/grnxx/expression.cpp    2014-08-04 13:21:32 +0900 (a7c9e3b)
+++ lib/grnxx/expression.cpp    2014-08-04 15:55:48 +0900 (3c120cc)
@@ -738,38 +738,38 @@ bool Expression::adjust(Error *error, RecordSet *record_set, Int offset) {
 template <typename T>
 bool Expression::evaluate(Error *error,
                           const RecordSubset &record_set,
-                          Array<T> *result_set) {
+                          Array<T> *results) {
   Node<T> *node = static_cast<Node<T> *>(root_.get());
   if (!node->evaluate(error, record_set)) {
     return false;
   }
-  if (!result_set->resize(error, record_set.size())) {
+  if (!results->resize(error, record_set.size())) {
     return false;
   }
-  for (Int i = 0; i < result_set->size(); ++i) {
-    (*result_set)[i] = node->get(i);
+  for (Int i = 0; i < results->size(); ++i) {
+    (*results)[i] = node->get(i);
   }
   return true;
 }
 
 template bool Expression::evaluate(Error *error,
                                    const RecordSubset &record_set,
-                                   Array<Bool> *result_set);
+                                   Array<Bool> *results);
 template bool Expression::evaluate(Error *error,
                                    const RecordSubset &record_set,
-                                   Array<Int> *result_set);
+                                   Array<Int> *results);
 template bool Expression::evaluate(Error *error,
                                    const RecordSubset &record_set,
-                                   Array<Float> *result_set);
+                                   Array<Float> *results);
 template bool Expression::evaluate(Error *error,
                                    const RecordSubset &record_set,
-                                   Array<Time> *result_set);
+                                   Array<Time> *results);
 template bool Expression::evaluate(Error *error,
                                    const RecordSubset &record_set,
-                                   Array<GeoPoint> *result_set);
+                                   Array<GeoPoint> *results);
 template bool Expression::evaluate(Error *error,
                                    const RecordSubset &record_set,
-                                   Array<Text> *result_set);
+                                   Array<Text> *results);
 
 Expression::Expression(const Table *table, unique_ptr<ExpressionNode> &&root)
     : table_(table),
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index