for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
namespace Spiral\Bootloader\Attributes;
use Spiral\Core\InjectableConfig;
final class AttributesConfig extends InjectableConfig
{
public const CONFIG = 'attributes';
/**
* @var array{
array{
2
* annotations: array{support:bool},
* cache: array{storage: null|non-empty-string, enabled: bool},
* }
*/
protected array $config = [
'annotations' => [
'support' => true,
],
'cache' => [
'storage' => null,
'enabled' => false,
];
public function isAnnotationsReaderEnabled(): bool
return (bool)$this->config['annotations']['support'];
}
public function isCacheEnabled(): bool
return (bool)($this->config['cache']['enabled'] ?? false);
* @return non-empty-string|null
non-empty-string|null
0
public function getCacheStorage(): ?string
return $this->config['cache']['storage'] ?? null;