PHP Класс PHPPM\Utils

Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
bindAndCall ( callable $fn, object $newThis, array $args = [], string $bindClass = null ) Executes a function in the context of an object. This basically bypasses the private/protected check of PHP.
generateSessionId ( ) : string Generates stronger session ids for session handling.
getMaxMemory ( ) : integer
hijackProperty ( object $object, string $propertyName, mixed $newValue ) Changes a property value of an object. (hijack because you can also change private/protected properties)
isWindows ( ) : boolean

Описание методов

bindAndCall() публичный статический метод

Executes a function in the context of an object. This basically bypasses the private/protected check of PHP.
public static bindAndCall ( callable $fn, object $newThis, array $args = [], string $bindClass = null )
$fn callable
$newThis object
$args array
$bindClass string

generateSessionId() публичный статический метод

Generates stronger session ids for session handling.
public static generateSessionId ( ) : string
Результат string

getMaxMemory() публичный статический метод

public static getMaxMemory ( ) : integer
Результат integer bytes

hijackProperty() публичный статический метод

Changes a property value of an object. (hijack because you can also change private/protected properties)
public static hijackProperty ( object $object, string $propertyName, mixed $newValue )
$object object
$propertyName string
$newValue mixed

isWindows() публичный статический метод

public static isWindows ( ) : boolean
Результат boolean