]> git.mxchange.org Git - core.git/commitdiff
Fixed calling ObjectFactory::createObjectByConfiguredName() as 2nd parameter must...
authorRoland Haeder <roland@mxchange.org>
Thu, 15 May 2014 19:23:04 +0000 (21:23 +0200)
committerRoland Haeder <roland@mxchange.org>
Thu, 15 May 2014 19:23:04 +0000 (21:23 +0200)
Signed-off-by: Roland Häder <roland@mxchange.org>
inc/classes/main/console/class_ConsoleTools.php
inc/classes/main/file_stack/class_BaseFileStack.php
inc/classes/main/io/io_handler/class_FileIoStream.php

index 32746b476178f973ecf1fdbe4fc60fdf2fcf8f50..068bbf5003b661588504c5f53518410434bcf76d 100644 (file)
@@ -207,7 +207,7 @@ class ConsoleTools extends BaseFrameworkSystem {
 
                try {
                        // Get a file pointer
-                       $fileInstance = ObjectFactory::createObjectByConfiguredName('file_raw_input_class', $helperInstance->getConfigInstance()->getConfigEntry('hostname_file'));
+                       $fileInstance = ObjectFactory::createObjectByConfiguredName('file_raw_input_class', array($helperInstance->getConfigInstance()->getConfigEntry('hostname_file')));
 
                        // Read the file
                        $rawData = trim($fileInstance->readFromFile());
index f782ad10325cfd2e360ece15e47aaf92aa86c801..d53d1e3b1bb84b3e61e8c00a1e2f5d28f6033968 100644 (file)
@@ -41,10 +41,10 @@ class BaseFileStack extends BaseFrameworkSystem {
         */
        protected function initStack ($fileName) {
                // Get a file i/o pointer instance
-               $pointerInstance = ObjectFactory::createObjectByConfiguredName('file_raw_input_output_class', $fileName);
+               $pointerInstance = ObjectFactory::createObjectByConfiguredName('file_raw_input_output_class', array($fileName));
 
                // Get iterator instance
-               $iteratorInstance = ObjectFactory::createObjectByConfiguredName('file_io_iterator_class', $pointerInstance);
+               $iteratorInstance = ObjectFactory::createObjectByConfiguredName('file_io_iterator_class', array($pointerInstance));
 
                // Is the instance implementing the right interface?
                assert($iteratorInstance instanceof SeekableFileIterator);
index d8cd58031fa7c1a9b2d57d46db0d4334c9a24ed9..35bc0c8b36de4d4156b774bfb69d4126aebe1227 100644 (file)
@@ -79,7 +79,7 @@ class FileIoStream extends BaseFrameworkSystem implements FileInputStreamer, Fil
                for ($idx = 0; $idx < 5; $idx++) {
                        // Get a file output pointer
                        try {
-                               $fileInstance = ObjectFactory::createObjectByConfiguredName('file_raw_output_class', $fileName);
+                               $fileInstance = ObjectFactory::createObjectByConfiguredName('file_raw_output_class', array($fileName));
                        } catch (FileIoException $e) {
                                // Create missing directory
                                $dirName = dirname($fileName);
@@ -147,7 +147,7 @@ class FileIoStream extends BaseFrameworkSystem implements FileInputStreamer, Fil
                $readData = ''; // This will contain our read data
 
                // Get a file input handler
-               $fileInstance = ObjectFactory::createObjectByConfiguredName('file_raw_input_class', $fqfn);
+               $fileInstance = ObjectFactory::createObjectByConfiguredName('file_raw_input_class', array($fqfn));
 
                // Read all it's contents (we very and transparently decompress it below)
                while ($readRawLine = $fileInstance->readFromFile()) {