55 protected $deprecatedPublicProperties = [];
69 $property, $version, $class =
null, $component =
null
71 $this->deprecatedPublicProperties[
$property] = [ $version, $class ?: __CLASS__, $component ];
75 if ( isset( $this->deprecatedPublicProperties[
$name] ) ) {
76 list( $version, $class, $component ) = $this->deprecatedPublicProperties[
$name];
77 $qualifiedName = $class .
'::$' .
$name;
82 $qualifiedName = __CLASS__ .
'::$' .
$name;
85 trigger_error(
"Cannot access non-public property $qualifiedName", E_USER_ERROR );
88 trigger_error(
"Undefined property: $qualifiedName", E_USER_NOTICE );
94 if ( isset( $this->deprecatedPublicProperties[
$name] ) ) {
95 list( $version, $class, $component ) = $this->deprecatedPublicProperties[
$name];
96 $qualifiedName = $class .
'::$' .
$name;
102 $qualifiedName = __CLASS__ .
'::$' .
$name;
105 trigger_error(
"Cannot access non-public property $qualifiedName", E_USER_ERROR );
120 if ( property_exists( $this,
$property ) ) {
132 $obfuscatedProps = array_keys( (
array)$this );
133 $obfuscatedPropTail =
"\0$property";
134 foreach ( $obfuscatedProps
as $obfuscatedProp ) {
136 if ( strpos( $obfuscatedProp, $obfuscatedPropTail, 1 ) !==
false ) {
137 $classname = substr( $obfuscatedProp, 1, -strlen( $obfuscatedPropTail ) );
138 if ( $classname ===
'*' ) {
140 $classname = __CLASS__;