Magic methods (__get, __set) not working in extended class?
<pre><code>&lt;?php 

abstract class AbstractClass
{
    public function __get($theName)
    {
        return (isset($this-&gt;$theName)) ? $this-&gt;$theName : NULL;
    }

    public function __set($theName, $theValue)
    {
        if (false === property_exists(get_class(), $theName)) {
            throw new Exception(get_class()." does not have '".$theName."' property.");
        } else {
            $this-&gt;$theName = $theValue;
        }
    }
}

class ConcreteClass extends AbstractClass
{
        private $x;
        private $y;

        public function __construct($theX, $theY)
        {
            $this-&gt;x = $theX;
            $this-&gt;y = $theY;
        }
}

$concreteClass = new ConcreteClass(10, 20);

var_dump( $concreteClass-&gt;x );
</code></pre>

<p>Is there some way to amke this work or will I have to add those magic methods to the extended class?</p>
