]> git.mxchange.org Git - core.git/blobdiff - inc/classes/main/stacker/file/class_BaseFileStack.php
Added missing setter.
[core.git] / inc / classes / main / stacker / file / class_BaseFileStack.php
index f5050899ae5bca521b466e209daf0cb99fe97366..e3aeb4701fb9c3f192b7fa9cec788448e13cfb61 100644 (file)
@@ -139,6 +139,17 @@ class BaseFileStack extends BaseStacker {
                return $this->totalEntries;
        }
 
+       /**
+        * Setter for total entries
+        *
+        * @param       $totalEntries   Total entries in this stack
+        * @return      void
+        */
+       private final function setCounter ($counter) {
+               // Set it
+               $this->totalEntries = $counter;
+       }
+
        /**
         * Increment counter
         *
@@ -442,9 +453,10 @@ class BaseFileStack extends BaseStacker {
         * Initializes this file-based stack.
         *
         * @param       $fileName       File name of this stack
+        * @param       $type           Type of this stack (e.g. url_source for URL sources)
         * @return      void
         */
-       protected function initFileStack ($fileName) {
+       protected function initFileStack ($fileName, $type) {
                // Get a file i/o pointer instance for stack file
                $pointerInstance = ObjectFactory::createObjectByConfiguredName('file_raw_input_output_class', array($fileName));
 
@@ -476,7 +488,7 @@ class BaseFileStack extends BaseStacker {
                 * Get stack index instance. This can be used for faster
                 * "defragmentation" and startup.
                 */
-               $indexInstance = FileStackIndexFactory::createFileStackIndex($fileName);
+               $indexInstance = FileStackIndexFactory::createFileStackIndexInstance($fileName, $type);
 
                // And set it here
                $this->setIndexInstance($indexInstance);