Augmentation vers version 3.3.0
This commit is contained in:
17
vendor/ocramius/proxy-manager/README.md
vendored
17
vendor/ocramius/proxy-manager/README.md
vendored
@@ -1,8 +1,8 @@
|
||||
# Proxy Manager
|
||||
|
||||
This library aims at providing abstraction for generating various kinds of [proxy classes](http://marco-pivetta.com/proxy-pattern-in-php/).
|
||||
This library aims at providing abstraction for generating various kinds of [proxy classes](http://ocramius.github.io/presentations/proxy-pattern-in-php/).
|
||||
|
||||

|
||||

|
||||
|
||||
[](https://travis-ci.org/Ocramius/ProxyManager)
|
||||
[](https://scrutinizer-ci.com/g/Ocramius/ProxyManager/)
|
||||
@@ -19,14 +19,19 @@ This library aims at providing abstraction for generating various kinds of [prox
|
||||
|
||||
## Documentation
|
||||
|
||||
You can learn about the proxy pattern and how to use the **ProxyManager** on the [online documentation](http://ocramius.github.io/ProxyManager).
|
||||
You can learn about the proxy pattern and how to use the **ProxyManager** in the [docs](docs), which are also
|
||||
[compiled to HTML](http://ocramius.github.io/ProxyManager).
|
||||
|
||||
## Help/Support
|
||||
|
||||
[](https://gitter.im/Ocramius/ProxyManager?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
|
||||
|
||||
## Installation
|
||||
|
||||
The suggested installation method is via [composer](https://getcomposer.org/):
|
||||
|
||||
```sh
|
||||
php composer.phar require ocramius/proxy-manager:1.0.*
|
||||
php composer.phar require ocramius/proxy-manager
|
||||
```
|
||||
|
||||
## Proxy example
|
||||
@@ -37,9 +42,9 @@ Here's how you build a lazy loadable object with ProxyManager using a *Virtual P
|
||||
$factory = new \ProxyManager\Factory\LazyLoadingValueHolderFactory();
|
||||
|
||||
$proxy = $factory->createProxy(
|
||||
'MyApp\HeavyComplexObject',
|
||||
\MyApp\HeavyComplexObject::class,
|
||||
function (& $wrappedObject, $proxy, $method, $parameters, & $initializer) {
|
||||
$wrappedObject = new HeavyComplexObject(); // instantiation logic here
|
||||
$wrappedObject = new \MyApp\HeavyComplexObject(); // instantiation logic here
|
||||
$initializer = null; // turning off further lazy initialization
|
||||
}
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user