Package org.keycloak.theme
Interface ThemeResourceProvider
- 
- All Superinterfaces:
- Provider
 - All Known Implementing Classes:
- ClasspathThemeResourceProviderFactory
 
 public interface ThemeResourceProvider extends Provider A theme resource provider can be used to load additional templates and resources. An example use of this would be a custom authenticator that requires an additional template and a JavaScript file. The theme is searched for templates and resources first. Theme resource providers are only searched if the template or resource is not found. This allows overriding templates and resources from theme resource providers in the theme.- Author:
- Stian Thorgersen
 
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default PropertiesgetMessages(String baseBundlename, Locale locale)Load the message bundle for the specific name and localeInputStreamgetResourceAsStream(String path)Load the resource for the specific pathURLgetTemplate(String name)Load the template for the specific name
 
- 
- 
- 
Method Detail- 
getTemplateURL getTemplate(String name) throws IOException Load the template for the specific name- Parameters:
- name- the template name
- Returns:
- the URL of the template, or null if the template is unknown
- Throws:
- IOException
 
 - 
getResourceAsStreamInputStream getResourceAsStream(String path) throws IOException Load the resource for the specific path- Parameters:
- path- the resource path
- Returns:
- an InputStream to read the resource, or null if the resource is unknown
- Throws:
- IOException
 
 - 
getMessagesdefault Properties getMessages(String baseBundlename, Locale locale) throws IOException Load the message bundle for the specific name and locale- Parameters:
- baseBundlename- The base name of the bundle, such as "messages" in messages_en.properties.
- locale- The locale of the desired message bundle.
- Returns:
- The localized messages from the bundle.
- Throws:
- IOException- If bundle can not be read.
 
 
- 
 
-