You are here

public function MagicGetClass::__get in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetClass.php \Doctrine\Tests\Common\Proxy\MagicGetClass::__get()

Parameters

$name:

Return value

string

Throws

\BadMethodCallException

File

vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetClass.php, line 26

Class

MagicGetClass
Test asset class

Namespace

Doctrine\Tests\Common\Proxy

Code

public function __get($name) {
  if ($name === 'test') {
    return 'test';
  }
  if ($name === 'publicField' || $name === 'id') {
    throw new \BadMethodCallException('Should never be called for "publicField" or "id"');
  }
  return 'not defined';
}