public class LocaleTargetIdManager extends AbstractTargetIdManager
TargetIdManager that treats the Locale as a
target ID. The current target ID is one returned by LocaleContextHolder.getLocale(), and if no available
target IDs are specified in the site configuration, the available locales of the JVM will be used instead. The locales
are always converted lower case.| Constructor and Description |
|---|
LocaleTargetIdManager() |
| Modifier and Type | Method and Description |
|---|---|
List<String> |
getAvailableTargetIds()
Returns the available target IDs defined in the current site configuration.
|
String |
getCurrentTargetId()
Returns the target ID for the current request, or null or empty if there's no target ID.
|
getFallbackTargetIdpublic String getCurrentTargetId() throws IllegalStateException
TargetIdManagerIllegalStateExceptionpublic List<String> getAvailableTargetIds()
AbstractTargetIdManagerIllegalStateException is thrown.getAvailableTargetIds in interface TargetIdManagergetAvailableTargetIds in class AbstractTargetIdManagerCopyright © 2020 CrafterCMS. All rights reserved.