From 61a9098b7d88656d0297a18c1b7685c04d1c64dc Mon Sep 17 00:00:00 2001 From: Bart Visscher Date: Thu, 26 Sep 2013 18:41:19 +0200 Subject: Add Helper and URLGenerator interfaces to server container --- lib/private/server.php | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'lib/private/server.php') diff --git a/lib/private/server.php b/lib/private/server.php index e4cc0c6da81..4000f546a3b 100644 --- a/lib/private/server.php +++ b/lib/private/server.php @@ -105,6 +105,12 @@ class Server extends SimpleContainer implements IServerContainer { $this->registerService('L10NFactory', function($c) { return new \OC\L10N\Factory(); }); + $this->registerService('URLGenerator', function($c) { + return new \OC\URLGenerator(); + }); + $this->registerService('AppHelper', function($c) { + return new \OC\AppHelper(); + }); $this->registerService('UserCache', function($c) { return new UserCache(); }); @@ -229,6 +235,20 @@ class Server extends SimpleContainer implements IServerContainer { return $this->query('L10NFactory')->get($app); } + /** + * @return \OC\URLGenerator + */ + function getURLGenerator() { + return $this->query('URLGenerator'); + } + + /** + * @return \OC\Helper + */ + function getHelper() { + return $this->query('AppHelper'); + } + /** * Returns an ICache instance * -- cgit v1.2.3