From 529abe2ebb98df6cd980b4f8225bdd3e4f1c83c8 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Thu, 4 Jan 2018 00:33:43 +0100 Subject: [PATCH] Continued: - more rewrites towards SplFileInfo MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../file_directories/binary/index/class_IndexFile.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/framework/main/classes/file_directories/binary/index/class_IndexFile.php b/framework/main/classes/file_directories/binary/index/class_IndexFile.php index 95aef97e..958792df 100644 --- a/framework/main/classes/file_directories/binary/index/class_IndexFile.php +++ b/framework/main/classes/file_directories/binary/index/class_IndexFile.php @@ -7,6 +7,9 @@ use Org\Mxchange\CoreFramework\Filesystem\Block; use Org\Mxchange\CoreFramework\Filesystem\File\BaseBinaryFile; use Org\Mxchange\CoreFramework\Generic\UnsupportedOperationException; +// Import SPL stuff +use \SplFileInfo; + /** * An index file class * @@ -43,11 +46,11 @@ class IndexFile extends BaseBinaryFile implements Block { /** * Creates an instance of this File class and prepares it for usage * - * @param $fileName Name of the index file + * @param $fileInfoInstance An instance of a SplFileInfo class * @param $blockInstance An instance of a Block class * @return $fileInstance An instance of this File class */ - public final static function createIndexFile ($fileName, Block $blockInstance) { + public final static function createIndexFile (SplFileInfo $fileInfoInstance, Block $blockInstance) { // Get a new instance $fileInstance = new IndexFile(); @@ -55,7 +58,7 @@ class IndexFile extends BaseBinaryFile implements Block { $fileInstance->setBlockInstance($blockInstance); // Init this abstract file - $fileInstance->initFile($fileName); + $fileInstance->initFile($fileInfoInstance); // Return the prepared instance return $fileInstance; -- 2.39.5