PHP 8.5.0 RC4 available for testing

La clase ReflectionObject

(PHP 5, PHP 7, PHP 8)

Introducción

La clase ReflectionObject proporciona información sobre un objeto.

Sinopsis de la Clase

class ReflectionObject extends ReflectionClass {
/* Constantaes heredadas constants */
/* Propiedades heredadas */
public string $name;
/* Métodos */
public __construct(object $object)
/* Métodos heredados */
public static ReflectionClass::export(mixed $argumento, bool $return = false): string
public ReflectionClass::getAttributes(?string $name = null, int $flags = 0): array
public ReflectionClass::newLazyGhost(callable $initializer, int $options = 0): object
public ReflectionClass::newLazyProxy(callable $factory, int $options = 0): object
public ReflectionClass::resetAsLazyGhost(object $object, callable $initializer, int $options = 0): void
public ReflectionClass::resetAsLazyProxy(object $object, callable $factory, int $options = 0): void
}

Historial de cambios

Versión Descripción
8.0.0 ReflectionObject::export() ha sido eliminada.

Tabla de contenidos

add a note

User Contributed Notes 1 note

up
4
marcel dot nolte at noltecomputer dot de
16 years ago
To simply enlist all methods and properties of an object simply write:

<?php ReflectionObject::export($yourObject); ?>

,which will cause an var_export-like output.
To Top