Files
Phraseanet/lib/Alchemy/Phrasea/Controller/Prod/WorkZone.php
2011-12-15 19:55:06 +01:00

50 lines
1.3 KiB
PHP

<?php
/*
* This file is part of Phraseanet
*
* (c) 2005-2010 Alchemy
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Alchemy\Phrasea\Controller\Prod;
use Silex\Application,
Silex\ControllerProviderInterface,
Silex\ControllerCollection;
use Symfony\Component\HttpFoundation\Request,
Symfony\Component\HttpFoundation\Response,
Symfony\Component\HttpFoundation\RedirectResponse,
Symfony\Component\HttpKernel\Exception\HttpException,
Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
use Alchemy\Phrasea\RouteProcessor\WorkZone as RouteWorkZone,
Alchemy\Phrasea\RequestHandler;
/**
*
* @package
* @license http://opensource.org/licenses/gpl-3.0 GPLv3
* @link www.phraseanet.com
*/
class Basket implements ControllerProviderInterface
{
public function connect(Application $app)
{
$controllers = new ControllerCollection();
$controllers->match('/', function(Application $app)
{
$requestHandler = new RequestHandler\WorkZone($app["kernel"]);
$processor = new RouteWorkZone\Root($requestHandler);
return $processor->getResponse();
});
return $controllers;
}
}