PluginProbe
BetterDocs – AI Documentation, Knowledge Base, MCP Server, Docs, Wikis, FAQ & Chatbot / 4.8.2
BetterDocs – AI Documentation, Knowledge Base, MCP Server, Docs, Wikis, FAQ & Chatbot v4.8.2
4.9.1 4.9.0 4.8.2 4.8.1 4.8.0 4.7.0 4.6.2 4.6.1 4.6.0 4.5.6 4.5.5 4.5.4 4.5.3 4.5.2 4.5.1 4.5.0 4.4.1 4.4.0 3.3.4 3.4.0 3.4.1 3.4.2 3.5.0 3.5.1 3.5.2 All 199 releases
betterdocs / includes / Dependencies / DI / Annotation / Injectable.php

Injectable.php in BetterDocs – AI Documentation, Knowledge Base, MCP Server, Docs, Wikis, FAQ & Chatbot 4.8.2, at includes/Dependencies/DI/Annotation/Injectable.php

43 lines 710 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 declare(strict_types=1);
4
5 namespace WPDeveloper\BetterDocs\Dependencies\DI\Annotation;
6
7 /**
8 * "Injectable" annotation.
9 *
10 * Marks a class as injectable
11 *
12 * @api
13 *
14 * @Annotation
15 * @Target("CLASS")
16 *
17 * @author Domenic Muskulus <domenic@muskulus.eu>
18 * @author Matthieu Napoli <matthieu@mnapoli.fr>
19 */
20 final class Injectable
21 {
22 /**
23 * Should the object be lazy-loaded.
24 * @var bool|null
25 */
26 private $lazy;
27
28 public function __construct(array $values)
29 {
30 if (isset($values['lazy'])) {
31 $this->lazy = (bool) $values['lazy'];
32 }
33 }
34
35 /**
36 * @return bool|null
37 */
38 public function isLazy()
39 {
40 return $this->lazy;
41 }
42 }
43