File ManagerCurrent Directory: wp-content/plugins/wp-migrate-db/vendor/php-di/php-di/src/DI/AnnotationLinux appserver-0d5e4f1e-php-cc8da225320a42ba9b7d66cba40b1f03 6.6.123+ #1 SMP PREEMPT_DYNAMIC Wed Mar 11 09:04:28 UTC 2026 x86_64Edit File: Injectable.php <?php namespace DeliciousBrains\WPMDB\Container\DI\Annotation; use DeliciousBrains\WPMDB\Container\DI\Scope; use UnexpectedValueException; /** * "Injectable" annotation. * * Marks a class as injectable * * @Annotation * @Target("CLASS") * * @author Domenic Muskulus <domenic@muskulus.eu> * @author Matthieu Napoli <matthieu@mnapoli.fr> */ final class Injectable { /** * The scope of an class: prototype, singleton. * @var string|null */ private $scope; /** * Should the object be lazy-loaded. * @var bool|null */ private $lazy; /** * @param array $values */ public function __construct(array $values) { if (isset($values['scope'])) { if ($values['scope'] === 'prototype') { $this->scope = Scope::PROTOTYPE; } elseif ($values['scope'] === 'singleton') { $this->scope = Scope::SINGLETON; } else { throw new UnexpectedValueException(\sprintf("Value '%s' is not a valid scope", $values['scope'])); } } if (isset($values['lazy'])) { $this->lazy = (bool) $values['lazy']; } } /** * @return string|null */ public function getScope() { return $this->scope; } /** * @return bool|null */ public function isLazy() { return $this->lazy; } } Upload File Directory Listing NameTypeSizeActions.. (Parent Directory)DirInject.phpFile1.92 KB Rename | Delete | EditInjectable.phpFile1.39 KB Rename | Delete | Edit