Linux ns1.utparral.edu.mx 6.8.0-79-generic #79~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Aug 15 16:54:53 UTC 2 x86_64
Apache/2.4.58 (Unix) OpenSSL/1.1.1w PHP/8.2.12 mod_perl/2.0.12 Perl/v5.34.1
: 10.10.1.9 | : 10.10.1.254
Cant Read [ /etc/named.conf ]
daemon
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
README
+ Create Folder
+ Create File
/
opt /
lampp /
htdocs /
phpMyAdmin /
libraries /
di /
[ HOME SHELL ]
Name
Size
Permission
Action
AliasItem.php
850
B
-rwxrwxr-x
Container.php
3.45
KB
-rwxrwxr-x
FactoryItem.php
469
B
-rwxrwxr-x
Item.php
383
B
-rwxrwxr-x
ReflectorItem.php
3.38
KB
-rwxrwxr-x
ServiceItem.php
609
B
-rwxrwxr-x
ValueItem.php
636
B
-rwxrwxr-x
Delete
Unzip
Zip
${this.title}
Close
Code Editor : Container.php
<?php /* vim: set expandtab sw=4 ts=4 sts=4: */ /** * Holds the PMA\libraries\di\Container class * * @package PMA */ namespace PMA\libraries\di; /** * Class Container * * @package PMA\libraries\di */ class Container { /** * @var Item[] $content */ protected $content = array(); /** * @var Container */ protected static $defaultContainer; /** * Create a dependency injection container * * @param Container $base Container */ public function __construct(Container $base = null) { if (isset($base)) { $this->content = $base->content; } else { $this->alias('container', 'Container'); } $this->set('Container', $this); } /** * Get an object with given name and parameters * * @param string $name Name * @param array $params Parameters * * @return mixed */ public function get($name, $params = array()) { if (isset($this->content[$name])) { return $this->content[$name]->get($params); } if (isset($GLOBALS[$name])) { return $GLOBALS[$name]; } return null; } /** * Remove an object from container * * @param string $name Name * * @return void */ public function remove($name) { unset($this->content[$name]); } /** * Rename an object in container * * @param string $name Name * @param string $newName New name * * @return void */ public function rename($name, $newName) { $this->content[$newName] = $this->content[$name]; $this->remove($name); } /** * Set values in the container * * @param string|array $name Name * @param mixed $value Value * * @return void */ public function set($name, $value = null) { if (is_array($name)) { foreach ($name as $key => $val) { $this->set($key, $val); } return; } $this->content[$name] = new ValueItem($value); } /** * Register a service in the container * * @param string $name Name * @param mixed $service Service * * @return void */ public function service($name, $service = null) { if (!isset($service)) { $service = $name; } $this->content[$name] = new ServiceItem($this, $service); } /** * Register a factory in the container * * @param string $name Name * @param mixed $factory Factory * * @return void */ public function factory($name, $factory = null) { if (!isset($factory)) { $factory = $name; } $this->content[$name] = new FactoryItem($this, $factory); } /** * Register an alias in the container * * @param string $name Name * @param string $target Target * * @return void */ public function alias($name, $target) { // The target may be not defined yet $this->content[$name] = new AliasItem($this, $target); } /** * Get the global default container * * @return Container */ public static function getDefaultContainer() { if (!isset(static::$defaultContainer)) { static::$defaultContainer = new Container(); } return static::$defaultContainer; } }
Close