use Friendica\App;
use Friendica\Core\Cache;
use Friendica\Core\Config;
+use Friendica\Core\L10n\L10n;
use Friendica\Core\Lock\ILock;
+use Friendica\Core\Process;
+use Friendica\Core\Session\ISession;
+use Friendica\Core\StorageManager;
use Friendica\Database\Database;
use Friendica\Factory;
+use Friendica\Model\Storage\IStorage;
+use Friendica\Model\User\Cookie;
use Friendica\Util;
use Psr\Log\LoggerInterface;
],
App\Mode::class => [
'call' => [
- ['determineRunMode', [$_SERVER], Dice::CHAIN_CALL],
+ ['determineRunMode', [true, $_SERVER], Dice::CHAIN_CALL],
['determine', [], Dice::CHAIN_CALL],
],
],
- Config\Configuration::class => [
+ Config\IConfiguration::class => [
'instanceOf' => Factory\ConfigFactory::class,
'call' => [
['createConfig', [], Dice::CHAIN_CALL],
],
],
- Config\PConfiguration::class => [
+ Config\IPConfiguration::class => [
'instanceOf' => Factory\ConfigFactory::class,
'call' => [
['createPConfig', [], Dice::CHAIN_CALL],
],
Database::class => [
'constructParams' => [
- [DICE::INSTANCE => \Psr\Log\NullLogger::class],
+ [Dice::INSTANCE => \Psr\Log\NullLogger::class],
$_SERVER,
],
],
*/
LoggerInterface::class => [
'instanceOf' => Factory\LoggerFactory::class,
+ 'constructParams' => [
+ 'index',
+ ],
'call' => [
- ['create', [], Dice::CHAIN_CALL],
+ ['create', ['index'], Dice::CHAIN_CALL],
],
],
'$devLogger' => [
'instanceOf' => Factory\LoggerFactory::class,
+ 'constructParams' => [
+ 'dev',
+ ],
'call' => [
['createDev', [], Dice::CHAIN_CALL],
]
['determineModule', [], Dice::CHAIN_CALL],
],
],
- Friendica\Core\Process::class => [
+ Process::class => [
'constructParams' => [
[Dice::INSTANCE => '$basepath'],
],
],
+ App\Router::class => [
+ 'constructParams' => [
+ $_SERVER, null
+ ],
+ 'call' => [
+ ['loadRoutes', [include __DIR__ . '/routes.config.php'], Dice::CHAIN_CALL],
+ ],
+ ],
+ L10n::class => [
+ 'constructParams' => [
+ $_SERVER, $_GET
+ ],
+ ],
+ ISession::class => [
+ 'instanceOf' => Factory\SessionFactory::class,
+ 'call' => [
+ ['createSession', [$_SERVER], Dice::CHAIN_CALL],
+ ['start', [], Dice::CHAIN_CALL],
+ ],
+ ],
+ Cookie::class => [
+ 'constructParams' => [
+ $_SERVER, $_COOKIE
+ ],
+ ],
+ IStorage::class => [
+ 'instanceOf' => StorageManager::class,
+ 'call' => [
+ ['getBackend', [], Dice::CHAIN_CALL],
+ ],
+ ],
];