La classe ReflectionMethod

(PHP 5, PHP 7)

Introduction

La classe ReflectionMethod rapporte des informations sur une méthode.

Synopsis de la classe

ReflectionMethod extends ReflectionFunctionAbstract implements Reflector {
/* Constantes */
const integer IS_STATIC = 1 ;
const integer IS_PUBLIC = 256 ;
const integer IS_PROTECTED = 512 ;
const integer IS_PRIVATE = 1024 ;
const integer IS_ABSTRACT = 2 ;
const integer IS_FINAL = 4 ;
/* Propriétés */
public $name ;
public $class ;
/* Méthodes */
public __construct ( mixed $class , string $name )
public static export ( string $class , string $name [, bool $return = FALSE ] ) : string
public getClosure ( object $object ) : Closure
public getModifiers ( void ) : int
public getPrototype ( void ) : ReflectionMethod
public invoke ( object $object [, mixed $... ] ) : mixed
public invokeArgs ( object $object , array $args ) : mixed
public isAbstract ( void ) : bool
public isConstructor ( void ) : bool
public isDestructor ( void ) : bool
public isFinal ( void ) : bool
public isPrivate ( void ) : bool
public isProtected ( void ) : bool
public isPublic ( void ) : bool
public isStatic ( void ) : bool
public setAccessible ( bool $accessible ) : void
public __toString ( void ) : string
/* Méthodes héritées */
final private ReflectionFunctionAbstract::__clone ( void ) : void
public ReflectionFunctionAbstract::getFileName ( void ) : string
public ReflectionFunctionAbstract::getName ( void ) : string
abstract public ReflectionFunctionAbstract::__toString ( void ) : void
}

Propriétés

name

Nom de la méthode

class

Nom de la classe

Constantes pré-définies

Modificateurs de ReflectionMethod

ReflectionMethod::IS_STATIC

Indique que la méthode est statique

ReflectionMethod::IS_PUBLIC

Indique que la méthode est publique

ReflectionMethod::IS_PROTECTED

Indique que la méthode est protégée

ReflectionMethod::IS_PRIVATE

Indique que la méthode est privée

ReflectionMethod::IS_ABSTRACT

Indique que la méthode est abstraite

ReflectionMethod::IS_FINAL

Indique que la méthode est finale

Sommaire