]> git.mxchange.org Git - core.git/blobdiff - inc/classes/main/index/class_BaseIndex.php
Introduced CalculatableBlock + basic implementation for valid().
[core.git] / inc / classes / main / index / class_BaseIndex.php
index bca12f4a0093d24c92f8adcfbb70c1f8c389147c..a427c5b7c74632a34ff501afb147d06ab6b7bb7f 100644 (file)
@@ -186,11 +186,11 @@ class BaseIndex extends BaseFrameworkSystem {
        }
 
        /**
-        * Calculates minimum length for one entry
+        * Calculates minimum length for one entry/block
         *
-        * @return      $length         Minimum length for one entry
+        * @return      $length         Minimum length for one entry/block
         */
-       protected function caluclateMinimumFileEntryLength () {
+       public function caluclateMinimumBlockLength () {
                // Calulcate it
                // @TODO Not finished yet
                $length = 0;
@@ -214,7 +214,7 @@ class BaseIndex extends BaseFrameworkSystem {
                $fileInstance = ObjectFactory::createObjectByConfiguredName('index_file_class', array($fileName));
 
                // Get iterator instance
-               $iteratorInstance = ObjectFactory::createObjectByConfiguredName('file_io_iterator_class', array($fileInstance));
+               $iteratorInstance = ObjectFactory::createObjectByConfiguredName('file_io_iterator_class', array($fileInstance, $this));
 
                // Is the instance implementing the right interface?
                assert($iteratorInstance instanceof SeekableWritableFileIterator);