Package org.apache.wicket.resource
Interface IPropertiesFactory
-
- All Known Implementing Classes:
PropertiesFactory
public interface IPropertiesFactoryImplementations are responsible forlocatingPropertiesobjects, which are a thin wrapper aroundValueMapand is used to locate localized messages.The
clearCache()method should remove any cached references to properties objects used by an implementation, so thatload(Class, String)gets the freshest instance possible.Listenersare related to cached properties and should be used to inform observers when sets of properties are reloaded.- Author:
- Juergen Donnerstag
- See Also:
Properties
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddListener(IPropertiesChangeListener listener)Add a listener which will be called when a change to the underlying resource stream (e.g.voidclearCache()Remove all cached properties.Propertiesload(java.lang.Class<?> clazz, java.lang.String path)Load the properties associated with the path
-
-
-
Method Detail
-
addListener
void addListener(IPropertiesChangeListener listener)
Add a listener which will be called when a change to the underlying resource stream (e.g. properties file) has been detected- Parameters:
listener-
-
clearCache
void clearCache()
Remove all cached properties.
-
load
Properties load(java.lang.Class<?> clazz, java.lang.String path)
Load the properties associated with the path- Parameters:
clazz- The class requesting the propertiespath- The path to identify the resource- Returns:
- The properties
-
-