class RuntimePublicReflectionPropertyTestProxyMock in Plug 7
Mock that simulates proxy public property lazy loading
Hierarchy
- class \Doctrine\Tests\Common\Reflection\RuntimePublicReflectionPropertyTestProxyMock implements Proxy
Expanded class hierarchy of RuntimePublicReflectionPropertyTestProxyMock
File
- lib/
doctrine/ common/ tests/ Doctrine/ Tests/ Common/ Reflection/ RuntimePublicReflectionPropertyTest.php, line 73
Namespace
Doctrine\Tests\Common\ReflectionView source
class RuntimePublicReflectionPropertyTestProxyMock implements Proxy {
/**
* @var \Closure|null
*/
private $initializer = null;
/**
* @var \Closure|null
*/
private $initialized = false;
/**
* @var string
*/
public $checkedProperty = 'testValue';
/**
* {@inheritDoc}
*/
public function __getInitializer() {
return $this->initializer;
}
/**
* {@inheritDoc}
*/
public function __setInitializer(\Closure $initializer = null) {
$this->initializer = $initializer;
}
/**
* {@inheritDoc}
*/
public function __getLazyProperties() {
}
/**
* {@inheritDoc}
*/
public function __load() {
}
/**
* {@inheritDoc}
*/
public function __isInitialized() {
return $this->initialized;
}
/**
* {@inheritDoc}
*/
public function __setInitialized($initialized) {
$this->initialized = (bool) $initialized;
}
/**
* @param string $name
*/
public function __get($name) {
if ($this->initializer) {
$cb = $this->initializer;
$cb();
}
return $this->checkedProperty;
}
/**
* @param string $name
* @param mixed $value
*/
public function __set($name, $value) {
if ($this->initializer) {
$cb = $this->initializer;
$cb();
}
// triggers notices if `$name` is used: see https://bugs.php.net/bug.php?id=63463
$this->checkedProperty = $value;
}
/**
* @param string $name
*
* @return integer
*/
public function __isset($name) {
if ($this->initializer) {
$cb = $this->initializer;
$cb();
}
return isset($this->checkedProperty);
}
/**
* {@inheritDoc}
*/
public function __setCloner(\Closure $cloner = null) {
}
/**
* {@inheritDoc}
*/
public function __getCloner() {
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
Proxy:: |
constant | Marker for Proxy class names. | ||
Proxy:: |
constant | Length of the proxy marker. | ||
RuntimePublicReflectionPropertyTestProxyMock:: |
public | property | ||
RuntimePublicReflectionPropertyTestProxyMock:: |
private | property | ||
RuntimePublicReflectionPropertyTestProxyMock:: |
private | property | ||
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function | ||
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function |
Retrieves the callback to be used when cloning the proxy. Overrides Proxy:: |
|
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function |
Retrieves the initializer callback used to initialize the proxy. Overrides Proxy:: |
|
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function |
Retrieves the list of lazy loaded properties for a given proxy Overrides Proxy:: |
|
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function |
Returns whether this proxy is initialized or not. Overrides Proxy:: |
|
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function | ||
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function |
Initializes this proxy if its not yet initialized. Overrides Proxy:: |
|
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function | ||
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function |
Sets the callback to be used when cloning the proxy. That initializer should accept
a single parameter, which is the cloned proxy instance itself. Overrides Proxy:: |
|
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function |
Marks the proxy as initialized or not. Overrides Proxy:: |
|
RuntimePublicReflectionPropertyTestProxyMock:: |
public | function |
Sets the initializer callback to be used when initializing the proxy. That
initializer should accept 3 parameters: $proxy, $method and $params. Those
are respectively the proxy object that is being initialized, the method name
that triggered… Overrides Proxy:: |