示例#1
0
 /**
  * Backwards compatibility logic
  *
  * @param string $name
  * @param mixed $value
  */
 function __set($name, $value)
 {
     if ($name === 'ok') {
         $this->sv->setOK($value);
     } elseif (!property_exists($this, $name)) {
         // Caller is using undeclared ad-hoc properties
         $this->{$name} = $value;
     } else {
         throw new Exception("Cannot set '{$name}' property.");
     }
 }