[ Index ] |
PHP Cross Reference of phpBB-3.2.11-deutsch |
[Summary view] [Print] [Text view]
1 --TEST-- 2 Verifies that lazy loading value holder factory can generate proxy for PHP core classes. 3 --FILE-- 4 <?php 5 6 require_once __DIR__ . '/init.php'; 7 8 class PharMock extends Phar 9 { 10 public function __construct() 11 { 12 } 13 14 public function compress($compression_type, $file_ext = null) 15 { 16 echo $compression_type; 17 } 18 } 19 20 $factory = new \ProxyManager\Factory\LazyLoadingValueHolderFactory($configuration); 21 22 $factory 23 ->createProxy('Phar', function (& $wrapped, $proxy, $method, array $parameters, & $initializer) { 24 $initializer = null; 25 $wrapped = new PharMock(); 26 }) 27 ->compress('Lazy Loaded!'); 28 29 ?> 30 --EXPECT-- 31 Lazy Loaded!
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Wed Nov 11 20:33:01 2020 | Cross-referenced by PHPXref 0.7.1 |