diff options
| author | Christian Weiske <cweiske@cweiske.de> | 2014-08-14 18:41:34 +0200 |
|---|---|---|
| committer | Christian Weiske <cweiske@cweiske.de> | 2014-08-14 18:41:34 +0200 |
| commit | 3780cf15a59c48b3d71e8ec27e3bdacd8a119460 (patch) | |
| tree | 84498c8ebdb29f212ab1b37c1d8b911eb6a237e9 /appinfo/application.php | |
| download | grauphel-3780cf15a59c48b3d71e8ec27e3bdacd8a119460.tar.gz grauphel-3780cf15a59c48b3d71e8ec27e3bdacd8a119460.zip | |
wip
Diffstat (limited to 'appinfo/application.php')
| -rw-r--r-- | appinfo/application.php | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/appinfo/application.php b/appinfo/application.php new file mode 100644 index 0000000..ecee129 --- /dev/null +++ b/appinfo/application.php @@ -0,0 +1,45 @@ +<?php +namespace OCA\Grauphel\AppInfo; +use \OCP\AppFramework\App; + +class Application extends App +{ + public function __construct(array $urlParams=array()) + { + parent::__construct('grauphel', $urlParams); + + $container = $this->getContainer(); + + /** + * Controllers + */ + $container->registerService( + 'ApiController', + function($c) { + return new \OCA\Grauphel\Controller\ApiController( + $c->query('AppName'), + $c->query('Request') + ); + } + ); + $container->registerService( + 'AccessController', + function($c) { + return new \OCA\Grauphel\Controller\AccessController( + $c->query('AppName'), + $c->query('Request') + ); + } + ); + $container->registerService( + 'OAuthController', + function($c) { + return new \OCA\Grauphel\Controller\OAuthController( + $c->query('AppName'), + $c->query('Request') + ); + } + ); + } +} +?> |
