aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/install/helper/iohandler/iohandler_base.php
diff options
context:
space:
mode:
authorMateBartus <mate.bartus@gmail.com>2015-06-02 21:56:27 +0200
committerMate Bartus <mate.bartus@gmail.com>2015-07-08 01:27:59 +0200
commit37b0134aa437e3e874464d3cf0d29c34a8da184a (patch)
treed088a06b34ef3cea896f0366a7766124415c360b /phpBB/install/helper/iohandler/iohandler_base.php
parent4df89d88486faa0c70473271c6ba757d5faab851 (diff)
downloadforums-37b0134aa437e3e874464d3cf0d29c34a8da184a.tar
forums-37b0134aa437e3e874464d3cf0d29c34a8da184a.tar.gz
forums-37b0134aa437e3e874464d3cf0d29c34a8da184a.tar.bz2
forums-37b0134aa437e3e874464d3cf0d29c34a8da184a.tar.xz
forums-37b0134aa437e3e874464d3cf0d29c34a8da184a.zip
[ticket/13740] Add backend support for install progress tracking
PHPBB3-13740
Diffstat (limited to 'phpBB/install/helper/iohandler/iohandler_base.php')
-rw-r--r--phpBB/install/helper/iohandler/iohandler_base.php39
1 files changed, 39 insertions, 0 deletions
diff --git a/phpBB/install/helper/iohandler/iohandler_base.php b/phpBB/install/helper/iohandler/iohandler_base.php
index c0e6921fb2..f767ecf4e9 100644
--- a/phpBB/install/helper/iohandler/iohandler_base.php
+++ b/phpBB/install/helper/iohandler/iohandler_base.php
@@ -49,6 +49,21 @@ abstract class iohandler_base implements iohandler_interface
protected $language;
/**
+ * @var int
+ */
+ protected $task_progress_count;
+
+ /**
+ * @var int
+ */
+ protected $current_task_progress;
+
+ /**
+ * @var string
+ */
+ protected $current_task_name;
+
+ /**
* Constructor
*/
public function __construct()
@@ -56,6 +71,10 @@ abstract class iohandler_base implements iohandler_interface
$this->errors = array();
$this->warnings = array();
$this->logs = array();
+
+ $this->task_progress_count = 0;
+ $this->current_task_progress = 0;
+ $this->current_task_name = '';
}
/**
@@ -93,6 +112,26 @@ abstract class iohandler_base implements iohandler_interface
}
/**
+ * {@inheritdoc}
+ */
+ public function set_task_count($task_count)
+ {
+ $this->task_progress_count = $task_count;
+ }
+
+ /**
+ * {@inheritdoc}
+ */
+ public function set_progress($task_lang_key, $task_number)
+ {
+ if (!empty($task_lang_key))
+ {
+ $this->current_task_name = $this->language->lang($task_lang_key);
+ $this->current_task_progress = $task_number;
+ }
+ }
+
+ /**
* Localize message.
*
* Note: When an array is passed into the parameters below, it will be