* Creates an instance of this File class and prepares it for usage
*
* @param $fileName Name of the stack file
+ * @param $blockInstance An instance of a CalculatableBlock class
* @return $fileInstance An instance of this File class
*/
- public final static function createStackFile ($fileName) {
+ public final static function createStackFile ($fileName, CalculatableBlock $blockInstance) {
// Get a new instance
$fileInstance = new StackFile();
+ // Set block instance here for callbacks
+ $fileInstance->setBlockInstance($blockInstance);
+
// Init this abstract file
$fileInstance->initFile($fileName);