改名
This commit is contained in:
+12
-1
@@ -28,7 +28,7 @@ use Server\ResponseInterface;
|
||||
* Class Container
|
||||
* @package Kiri\Di
|
||||
*/
|
||||
class Container extends BaseObject
|
||||
class Container extends BaseObject implements ContainerInterface
|
||||
{
|
||||
|
||||
use Attributes;
|
||||
@@ -119,6 +119,17 @@ class Container extends BaseObject
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @param string $interface
|
||||
* @param $object
|
||||
*/
|
||||
public function setBindings(string $interface, $object)
|
||||
{
|
||||
$this->_singletons[$interface] = $object;
|
||||
$this->_interfaces[$interface] = get_class($object);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @param $class
|
||||
* @param array $constrict
|
||||
|
||||
Reference in New Issue
Block a user