!C99Shell v. 2.0 [PHP 7 Update] [25.02.2019]!

Software: Apache/2.2.22 (Debian). PHP/5.6.36 

uname -a: Linux h05.hvosting.ua 4.9.110-amd64 #3 SMP Sun Nov 4 16:27:09 UTC 2018 x86_64 

uid=1389(h33678) gid=1099(h33678) groups=1099(h33678),502(mgrsecure) 

Safe-mode: OFF (not secure)

/home/h33678/data/www/it-man.ztu.edu.ua/src/vendor/symfony/var-dumper/Caster/   drwxr-xr-x
Free 116.86 GB of 200.55 GB (58.27%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     ReflectionCaster.php (9.96 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

/*
 * This file is part of the Symfony package.
 *
 * (c) Fabien Potencier <fabien@symfony.com>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace Symfony\Component\VarDumper\Caster;

use 
Symfony\Component\VarDumper\Cloner\Stub;

/**
 * Casts Reflector related classes to array representation.
 *
 * @author Nicolas Grekas <p@tchwork.com>
 */
class ReflectionCaster
{
    private static 
$extraMap = array(
        
'docComment' => 'getDocComment',
        
'extension' => 'getExtensionName',
        
'isDisabled' => 'isDisabled',
        
'isDeprecated' => 'isDeprecated',
        
'isInternal' => 'isInternal',
        
'isUserDefined' => 'isUserDefined',
        
'isGenerator' => 'isGenerator',
        
'isVariadic' => 'isVariadic',
    );

    public static function 
castClosure(\Closure $c, array $aStub $stub$isNested)
    {
        
$prefix Caster::PREFIX_VIRTUAL;
        
$c = new \ReflectionFunction($c);

        
$stub->class 'Closure'// HHVM generates unique class names for closures
        
$a = static::castFunctionAbstract($c$a$stub$isNested);

        if (isset(
$a[$prefix.'parameters'])) {
            foreach (
$a[$prefix.'parameters']->value as &$v) {
                
$param $v;
                
$v = new EnumStub(array());
                foreach (static::
castParameter($param, array(), $stubtrue) as $k => $param) {
                    if (
"\0" === $k[0]) {
                        
$v->value[substr($k3)] = $param;
                    }
                }
                unset(
$v->value['position'], $v->value['isVariadic'], $v->value['byReference'], $v);
            }
        }

        if (
$f $c->getFileName()) {
            
$a[$prefix.'file'] = $f;
            
$a[$prefix.'line'] = $c->getStartLine().' to '.$c->getEndLine();
        }

        
$prefix Caster::PREFIX_DYNAMIC;
        unset(
$a['name'], $a[$prefix.'0'], $a[$prefix.'this'], $a[$prefix.'parameter'], $a[Caster::PREFIX_VIRTUAL.'extra']);

        return 
$a;
    }

    public static function 
castGenerator(\Generator $c, array $aStub $stub$isNested)
    {
        return 
class_exists('ReflectionGenerator'false) ? self::castReflectionGenerator(new \ReflectionGenerator($c), $a$stub$isNested) : $a;
    }

    public static function 
castType(\ReflectionType $c, array $aStub $stub$isNested)
    {
        
$prefix Caster::PREFIX_VIRTUAL;

        
$a += array(
            
$prefix.'type' => $c->__toString(),
            
$prefix.'allowsNull' => $c->allowsNull(),
            
$prefix.'isBuiltin' => $c->isBuiltin(),
        );

        return 
$a;
    }

    public static function 
castReflectionGenerator(\ReflectionGenerator $c, array $aStub $stub$isNested)
    {
        
$prefix Caster::PREFIX_VIRTUAL;

        if (
$c->getThis()) {
            
$a[$prefix.'this'] = new CutStub($c->getThis());
        }
        
$x $c->getFunction();
        
$frame = array(
            
'class' => isset($x->class) ? $x->class null,
            
'type' => isset($x->class) ? ($x->isStatic() ? '::' '->') : null,
            
'function' => $x->name,
            
'file' => $c->getExecutingFile(),
            
'line' => $c->getExecutingLine(),
        );
        if (
$trace $c->getTrace(DEBUG_BACKTRACE_IGNORE_ARGS)) {
            
$x = new \ReflectionGenerator($c->getExecutingGenerator());
            
array_unshift($trace, array(
                
'function' => 'yield',
                
'file' => $x->getExecutingFile(),
                
'line' => $x->getExecutingLine() - 1,
            ));
            
$trace[] = $frame;
            
$a[$prefix.'trace'] = new TraceStub($tracefalse0, -1, -1);
        } else {
            
$x = new FrameStub($framefalsetrue);
            
$x ExceptionCaster::castFrameStub($x, array(), $xtrue);
            
$a[$prefix.'executing'] = new EnumStub(array(
                
$frame['class'].$frame['type'].$frame['function'].'()' => $x[$prefix.'src'],
            ));
        }

        return 
$a;
    }

    public static function 
castClass(\ReflectionClass $c, array $aStub $stub$isNested$filter 0)
    {
        
$prefix Caster::PREFIX_VIRTUAL;

        if (
$n = \Reflection::getModifierNames($c->getModifiers())) {
            
$a[$prefix.'modifiers'] = implode(' '$n);
        }

        
self::addMap($a$c, array(
            
'extends' => 'getParentClass',
            
'implements' => 'getInterfaceNames',
            
'constants' => 'getConstants',
        ));

        foreach (
$c->getProperties() as $n) {
            
$a[$prefix.'properties'][$n->name] = $n;
        }

        foreach (
$c->getMethods() as $n) {
            
$a[$prefix.'methods'][$n->name] = $n;
        }

        if (!(
$filter Caster::EXCLUDE_VERBOSE) && !$isNested) {
            
self::addExtra($a$c);
        }

        return 
$a;
    }

    public static function 
castFunctionAbstract(\ReflectionFunctionAbstract $c, array $aStub $stub$isNested$filter 0)
    {
        
$prefix Caster::PREFIX_VIRTUAL;

        
self::addMap($a$c, array(
            
'returnsReference' => 'returnsReference',
            
'returnType' => 'getReturnType',
            
'class' => 'getClosureScopeClass',
            
'this' => 'getClosureThis',
        ));

        if (isset(
$a[$prefix.'returnType'])) {
            
$a[$prefix.'returnType'] = (string) $a[$prefix.'returnType'];
        }
        if (isset(
$a[$prefix.'this'])) {
            
$a[$prefix.'this'] = new CutStub($a[$prefix.'this']);
        }

        foreach (
$c->getParameters() as $v) {
            
$k '$'.$v->name;
            if (
$v->isPassedByReference()) {
                
$k '&'.$k;
            }
            if (
method_exists($v'isVariadic') && $v->isVariadic()) {
                
$k '...'.$k;
            }
            
$a[$prefix.'parameters'][$k] = $v;
        }
        if (isset(
$a[$prefix.'parameters'])) {
            
$a[$prefix.'parameters'] = new EnumStub($a[$prefix.'parameters']);
        }

        if (
$v $c->getStaticVariables()) {
            foreach (
$v as $k => &$v) {
                
$a[$prefix.'use']['$'.$k] = &$v;
            }
            unset(
$v);
            
$a[$prefix.'use'] = new EnumStub($a[$prefix.'use']);
        }

        if (!(
$filter Caster::EXCLUDE_VERBOSE) && !$isNested) {
            
self::addExtra($a$c);
        }

        
// Added by HHVM
        
unset($a[Caster::PREFIX_DYNAMIC.'static']);

        return 
$a;
    }

    public static function 
castMethod(\ReflectionMethod $c, array $aStub $stub$isNested)
    {
        
$a[Caster::PREFIX_VIRTUAL.'modifiers'] = implode(' ', \Reflection::getModifierNames($c->getModifiers()));

        return 
$a;
    }

    public static function 
castParameter(\ReflectionParameter $c, array $aStub $stub$isNested)
    {
        
$prefix Caster::PREFIX_VIRTUAL;

        
// Added by HHVM
        
unset($a['info']);

        
self::addMap($a$c, array(
            
'position' => 'getPosition',
            
'isVariadic' => 'isVariadic',
            
'byReference' => 'isPassedByReference',
        ));

        try {
            if (
method_exists($c'hasType')) {
                if (
$c->hasType()) {
                    
$a[$prefix.'typeHint'] = $c->getType()->__toString();
                }
            } else {
                
$v explode(' '$c->__toString(), 6);
                if (isset(
$v[5]) && === strspn($v[4], '.&$')) {
                    
$a[$prefix.'typeHint'] = $v[4];
                }
            }
        } catch (\
ReflectionException $e) {
            if (
preg_match('/^Class ([^ ]++) does not exist$/'$e->getMessage(), $m)) {
                
$a[$prefix.'typeHint'] = $m[1];
            }
        }

        try {
            
$a[$prefix.'default'] = $v $c->getDefaultValue();
            if (
method_exists($c'isDefaultValueConstant') && $c->isDefaultValueConstant()) {
                
$a[$prefix.'default'] = new ConstStub($c->getDefaultValueConstantName(), $v);
            }
        } catch (\
ReflectionException $e) {
            if (isset(
$a[$prefix.'typeHint']) && $c->allowsNull()) {
                
$a[$prefix.'default'] = null;
            }
        }

        return 
$a;
    }

    public static function 
castProperty(\ReflectionProperty $c, array $aStub $stub$isNested)
    {
        
$a[Caster::PREFIX_VIRTUAL.'modifiers'] = implode(' ', \Reflection::getModifierNames($c->getModifiers()));
        
self::addExtra($a$c);

        return 
$a;
    }

    public static function 
castExtension(\ReflectionExtension $c, array $aStub $stub$isNested)
    {
        
self::addMap($a$c, array(
            
'version' => 'getVersion',
            
'dependencies' => 'getDependencies',
            
'iniEntries' => 'getIniEntries',
            
'isPersistent' => 'isPersistent',
            
'isTemporary' => 'isTemporary',
            
'constants' => 'getConstants',
            
'functions' => 'getFunctions',
            
'classes' => 'getClasses',
        ));

        return 
$a;
    }

    public static function 
castZendExtension(\ReflectionZendExtension $c, array $aStub $stub$isNested)
    {
        
self::addMap($a$c, array(
            
'version' => 'getVersion',
            
'author' => 'getAuthor',
            
'copyright' => 'getCopyright',
            
'url' => 'getURL',
        ));

        return 
$a;
    }

    private static function 
addExtra(&$a, \Reflector $c)
    {
        
$x = isset($a[Caster::PREFIX_VIRTUAL.'extra']) ? $a[Caster::PREFIX_VIRTUAL.'extra']->value : array();

        if (
method_exists($c'getFileName') && $m $c->getFileName()) {
            
$x['file'] = $m;
            
$x['line'] = $c->getStartLine().' to '.$c->getEndLine();
        }

        
self::addMap($x$cself::$extraMap'');

        if (
$x) {
            
$a[Caster::PREFIX_VIRTUAL.'extra'] = new EnumStub($x);
        }
    }

    private static function 
addMap(&$a, \Reflector $c$map$prefix Caster::PREFIX_VIRTUAL)
    {
        foreach (
$map as $k => $m) {
            if (
method_exists($c$m) && false !== ($m $c->$m()) && null !== $m) {
                
$a[$prefix.$k] = $m instanceof \Reflector $m->name $m;
            }
        }
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

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

--[ c99shell v. 2.0 [PHP 7 Update] [25.02.2019] maintained by PinoyWH1Z | C99Shell Github | Generation time: 0.0136 ]--