Author: mcantelon
Date: Tue Jan 17 14:56:07 2012
New Revision: 10703

Log:
Tweaked name/functionality for outputting import progress.

Modified:
   trunk/lib/QubitFlatfileImport.class.php

Modified: trunk/lib/QubitFlatfileImport.class.php
==============================================================================
--- trunk/lib/QubitFlatfileImport.class.php     Tue Jan 17 14:45:20 2012        
(r10702)
+++ trunk/lib/QubitFlatfileImport.class.php     Tue Jan 17 14:56:07 2012        
(r10703)
@@ -366,7 +366,7 @@
         }
 
         print '.';
-        print $this->progressDescription();
+        print $this->renderProgressDescription();
 
         $this->row($item);
       } else {
@@ -628,8 +628,10 @@
    *
    * @return void
    */
-  public function progressDescription()
+  public function renderProgressDescription()
   {
+    $output = '';
+
     // return empty string if no intermittant progress display
     if (!isset($this->rowsUntilProgressDisplay)
       || !$this->rowsUntilProgressDisplay
@@ -646,9 +648,11 @@
       $elapsedMinutes = round($elapsed / 60, 2);
       $averageTime = round($elapsed / $rowsProcessed, 2);
 
-      print "\n". $rowsProcessed ." rows processed in ". $elapsedMinutes
+      $output .= "\n". $rowsProcessed ." rows processed in ". $elapsedMinutes
       . " minutes (". $averageTime ." second/row average, ". $memoryUsageMB ." 
MB used).\n";
     }
+
+    return $output;
   }
 
   /**

-- 
You received this message because you are subscribed to the Google Groups 
"Qubit Toolkit Commits" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/qubit-commits?hl=en.

Reply via email to