* @copyright Since 2007 PrestaShop SA and Contributors * @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) */ declare(strict_types=1); namespace PrestaShop\PrestaShop\Core\Translation\Storage\Provider\Definition; /** * Properties container for single Module translation provider. */ class ThemeProviderDefinition implements ProviderDefinitionInterface { public const DEFAULT_THEME_NAME = 'classic'; private const FILENAME_FILTERS_REGEX = []; private const TRANSLATION_DOMAINS_REGEX = []; /** * @var string */ private $themeName; /** * @param string|null $themeName */ public function __construct(?string $themeName = null) { if (null === $themeName) { $themeName = static::DEFAULT_THEME_NAME; } $this->themeName = $themeName; } /** * {@inheritdoc} */ public function getType(): string { return ProviderDefinitionInterface::TYPE_THEMES; } /** * @return string */ public function getThemeName(): string { return $this->themeName; } /** * {@inheritdoc} */ public function getFilenameFilters(): array { return self::FILENAME_FILTERS_REGEX; } /** * {@inheritdoc} */ public function getTranslationDomains(): array { return self::TRANSLATION_DOMAINS_REGEX; } }