!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)

/uploads/script/vendor/myclabs/deep-copy/src/DeepCopy/Reflection/   drwxr-xr-x
Free 13.27 GB of 57.97 GB (22.89%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


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

namespace DeepCopy\Reflection;

use 
DeepCopy\Exception\PropertyException;
use 
ReflectionClass;
use 
ReflectionException;
use 
ReflectionObject;
use 
ReflectionProperty;

class 
ReflectionHelper
{
    
/**
     * Retrieves all properties (including private ones), from object and all its ancestors.
     *
     * Standard \ReflectionClass->getProperties() does not return private properties from ancestor classes.
     *
     * @author muratyaman@gmail.com
     * @see http://php.net/manual/en/reflectionclass.getproperties.php
     *
     * @param ReflectionClass $ref
     *
     * @return ReflectionProperty[]
     */
    
public static function getProperties(ReflectionClass $ref)
    {
        
$props $ref->getProperties();
        
$propsArr = array();

        foreach (
$props as $prop) {
            
$propertyName $prop->getName();
            
$propsArr[$propertyName] = $prop;
        }

        if (
$parentClass $ref->getParentClass()) {
            
$parentPropsArr self::getProperties($parentClass);
            foreach (
$propsArr as $key => $property) {
                
$parentPropsArr[$key] = $property;
            }

            return 
$parentPropsArr;
        }

        return 
$propsArr;
    }

    
/**
     * Retrieves property by name from object and all its ancestors.
     *
     * @param object|string $object
     * @param string $name
     *
     * @throws PropertyException
     * @throws ReflectionException
     *
     * @return ReflectionProperty
     */
    
public static function getProperty($object$name)
    {
        
$reflection is_object($object) ? new ReflectionObject($object) : new ReflectionClass($object);

        if (
$reflection->hasProperty($name)) {
            return 
$reflection->getProperty($name);
        }

        if (
$parentClass $reflection->getParentClass()) {
            return 
self::getProperty($parentClass->getName(), $name);
        }

        throw new 
PropertyException(
            
sprintf(
                
'The class "%s" doesn\'t have a property with the given name: "%s".',
                
is_object($object) ? get_class($object) : $object,
                
$name
            
)
        );
    }
}

:: 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.0271 ]--