class DbUpdateNegotiator implements ThemeNegotiatorInterface (View source)

Sets the active theme for the database update pages.

Properties

protected ConfigFactoryInterface $configFactory

The config factory.

Methods

__construct(ConfigFactoryInterface $config_factory)

Constructs a DbUpdateNegotiator.

bool
applies(RouteMatchInterface $route_match)

Whether this theme negotiator should be used to set the theme.

string|null
determineActiveTheme(RouteMatchInterface $route_match)

Determine the active theme for the request.

Details

__construct(ConfigFactoryInterface $config_factory)

Constructs a DbUpdateNegotiator.

Parameters

ConfigFactoryInterface $config_factory

The config factory.

bool applies(RouteMatchInterface $route_match)

Whether this theme negotiator should be used to set the theme.

Parameters

RouteMatchInterface $route_match

The current route match object.

Return Value

bool

TRUE if this negotiator should be used or FALSE to let other negotiators decide.

string|null determineActiveTheme(RouteMatchInterface $route_match)

Determine the active theme for the request.

Parameters

RouteMatchInterface $route_match

The current route match object.

Return Value

string|null

The name of the theme, or NULL if other negotiators, like the configured default one, should be used instead.