summaryrefslogtreecommitdiff
path: root/src/Application.php
blob: fa895d77adf96154339344c922f0aecd8346e50d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<?php

namespace Engelsystem;

use Engelsystem\Container\Container;
use Psr\Container\ContainerInterface;

class Application extends Container
{
    public function __construct()
    {
        $this->registerBaseBindings();
    }

    protected function registerBaseBindings()
    {
        static::setInstance($this);
        Container::setInstance($this);
        $this->instance('app', $this);
        $this->instance('container', $this);
        $this->instance(Container::class, $this);
        $this->instance(Application::class, $this);
        $this->bind(ContainerInterface::class, Application::class);
    }
}