接口 ThemeSource
- 所有已知子接口:
HierarchicalThemeSource
- 所有已知实现类:
AbstractRefreshableWebApplicationContext,AnnotationConfigWebApplicationContext,DelegatingThemeSource,GenericWebApplicationContext,GroovyWebApplicationContext,ResourceBundleThemeSource,StaticWebApplicationContext,XmlWebApplicationContext
public interface ThemeSource
Interface to be implemented by objects that can resolveThemes. This enables parameterization and internationalization of messages for a given 'theme'.- 作者:
- Jean-Pierre Pawlak, Juergen Hoeller
- 另请参阅:
Theme
方法详细资料
getTheme
Theme getTheme(String themeName)
Return the Theme instance for the given theme name.The returned Theme will resolve theme-specific messages, codes, file paths, etc (e.g. CSS and image files in a web environment).
- 参数:
themeName- the name of the theme- 返回:
- the corresponding Theme, or
nullif none defined. Note that, by convention, a ThemeSource should at least be able to return a default Theme for the default theme name "theme" but may also return default Themes for other theme names. - 另请参阅:
AbstractThemeResolver.ORIGINAL_DEFAULT_THEME_NAME