1 | <?php |
||
7 | class Latest_Autoloader_Guard { |
||
8 | |||
9 | /** |
||
10 | * The Plugins_Handler instance. |
||
11 | * |
||
12 | * @var Plugins_Handler |
||
13 | */ |
||
14 | private $plugins_handler; |
||
15 | |||
16 | /** |
||
17 | * The Autoloader_Handler instance. |
||
18 | * |
||
19 | * @var Autoloader_Handler |
||
20 | */ |
||
21 | private $autoloader_handler; |
||
22 | |||
23 | /** |
||
24 | * The Autoloader_locator instance. |
||
25 | * |
||
26 | * @var Autoloader_Locator |
||
27 | */ |
||
28 | private $autoloader_locator; |
||
29 | |||
30 | /** |
||
31 | * The constructor. |
||
32 | * |
||
33 | * @param Plugins_Handler $plugins_handler The Plugins_Handler instance. |
||
34 | * @param Autoloader_Handler $autoloader_handler The Autoloader_Handler instance. |
||
35 | * @param Autoloader_Locator $autoloader_locator The Autoloader_Locator instance. |
||
36 | */ |
||
37 | public function __construct( $plugins_handler, $autoloader_handler, $autoloader_locator ) { |
||
42 | |||
43 | /** |
||
44 | * Indicates whether or not the autoloader should be initialized. Note that this function |
||
45 | * has the side-effect of actually loading the latest autoloader in the event that this |
||
46 | * is not it. |
||
47 | * |
||
48 | * @param string $current_plugin The current plugin we're checking. |
||
49 | * @param string[] $plugins The active plugins to check for autoloaders in. |
||
50 | * |
||
51 | * @return bool True if we should stop initialization, otherwise false. |
||
52 | */ |
||
53 | public function should_stop_init( $current_plugin, $plugins ) { |
||
85 | } |
||
86 |