summaryrefslogtreecommitdiffstats
path: root/lib/backgroundjob
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2013-05-03 16:42:48 +0200
committerRobin Appelman <icewind@owncloud.com>2013-05-03 16:42:48 +0200
commitb7585050b565ac8f42c3afa625037adaf1a8d92c (patch)
tree0fb36a867b93969705715206147dee6b5efe60dd /lib/backgroundjob
parentb31dc10c3c4b73b08c926751effbade601c7cab8 (diff)
downloadnextcloud-server-b7585050b565ac8f42c3afa625037adaf1a8d92c.tar.gz
nextcloud-server-b7585050b565ac8f42c3afa625037adaf1a8d92c.zip
Move legacy backgroundjob classes to a place where they can be autoloaded
Diffstat (limited to 'lib/backgroundjob')
-rw-r--r--lib/backgroundjob/legacy/queuedjob.php18
-rw-r--r--lib/backgroundjob/legacy/regularjob.php15
2 files changed, 33 insertions, 0 deletions
diff --git a/lib/backgroundjob/legacy/queuedjob.php b/lib/backgroundjob/legacy/queuedjob.php
new file mode 100644
index 00000000000..2bc001103b8
--- /dev/null
+++ b/lib/backgroundjob/legacy/queuedjob.php
@@ -0,0 +1,18 @@
+<?php
+/**
+ * Copyright (c) 2013 Robin Appelman <icewind@owncloud.com>
+ * This file is licensed under the Affero General Public License version 3 or
+ * later.
+ * See the COPYING-README file.
+ */
+
+namespace OC\BackgroundJob\Legacy;
+
+class QueuedJob extends \OC\BackgroundJob\QueuedJob {
+ public function run($argument) {
+ $class = $argument['klass'];
+ $method = $argument['method'];
+ $parameters = $argument['parameters'];
+ call_user_func(array($class, $method), $parameters);
+ }
+}
diff --git a/lib/backgroundjob/legacy/regularjob.php b/lib/backgroundjob/legacy/regularjob.php
new file mode 100644
index 00000000000..d4cfa348cea
--- /dev/null
+++ b/lib/backgroundjob/legacy/regularjob.php
@@ -0,0 +1,15 @@
+<?php
+/**
+ * Copyright (c) 2013 Robin Appelman <icewind@owncloud.com>
+ * This file is licensed under the Affero General Public License version 3 or
+ * later.
+ * See the COPYING-README file.
+ */
+
+namespace OC\BackgroundJob\Legacy;
+
+class RegularJob extends \OC\BackgroundJob\Job {
+ public function run($argument) {
+ call_user_func($argument);
+ }
+}