ReflectionProperty::setAccessible
ReflectionProperty::setAccessible
(PHP 5 >= 5.3.0, PHP 7)
ReflectionProperty::setAccessible — Set property accessibility
Description
public void ReflectionProperty::setAccessible ( bool $accessible )
Sets a property to be accessible. For example, it may allow protected and private properties to be accessed.
Parameters
-
accessible
-
TRUE
to allow accessibility, orFALSE
.
Return Values
No value is returned.
See Also
- ReflectionProperty::isPrivate() - Checks if property is private
- ReflectionProperty::isProtected() - Checks if property is protected
© 1997–2017 The PHP Documentation Group
Licensed under the Creative Commons Attribution License v3.0 or later.
https://secure.php.net/manual/en/reflectionproperty.setaccessible.php