|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ResourceManager
This interface is used to customize not only icons, colors and internationalization but also ui components creation with relative customization and transparency manager.
| Method Summary | ||
|---|---|---|
|
applyCustomization(String key,
T component,
Context context)
Apply the customization using the rule specified by the key param. |
|
|
createComponent(String key,
Context context)
Create the component using the rule specified by the key param. |
|
ComponentUI |
createComponentUI(String key,
Context context)
Create the component ui using the rule specified by the key param. |
|
|
createInstance(Class<T> clazz,
Context context)
Returns an instance of class clazz using passed args. |
|
boolean |
getBoolean(String name,
boolean defaultValue)
Searches for the property with the specified name in the property list. |
|
Color |
getColor(String id)
Returns the color to which this manager maps the specified id. |
|
List<String> |
getColors()
Returns the map that contains all colors definition. |
|
float |
getFloat(String name,
float defaultValue)
Searches for the property with the specified name in the property list. |
|
Icon |
getIcon(String id)
Returns the icon to which this manager maps the specified id. |
|
List<String> |
getIcons()
Returns the map that contains all icons definition. |
|
BufferedImage |
getImage(String id)
Returns the buffered image to which this manager maps the specified id. |
|
int |
getInt(String name,
int defaultValue)
Searches for the property with the specified name in the property list. |
|
|
getObject(Class<T> clazz,
T defaultValue)
Searches for the object with the specified class in the property list. |
|
String |
getProperty(String name)
Searches for the property with the specified name in the property list. |
|
ResourceBundle |
getResourceBundle()
Returns the resource bundle used for the internationalization of mydoggy. |
|
String |
getString(String key)
This method is equivalent to getResourceBundle().getString(key) |
|
TransparencyManager<Window> |
getTransparencyManager()
Returns the transparency manager for the windows used to manage transparency of toolwindows of FLOATING or FLOATING_FREE type. |
|
ResourceBundle |
getUserResourceBundle()
Returns the resource bundle used for the internationalization of special strings like the the toolwindow id. |
|
String |
getUserString(String key)
This method is equivalent to getUserResourceBundle().getString(key) |
|
void |
putBoolean(String name,
boolean value)
Associates a string representing the specified boolean value with the specified name. |
|
Color |
putColor(String id,
Color color)
Associates the specified color with the specified id. |
|
void |
putFloat(String name,
float value)
Associates a string representing the specified float value with the specified name. |
|
Icon |
putIcon(String id,
Icon icon)
Associates the specified icon with the specified id. |
|
void |
putInt(String name,
int value)
Associates a string representing the specified int value with the specified name. |
|
void |
putObject(Object key,
Object value)
Associates the specified value with the specified key. |
|
void |
putProperty(String name,
String value)
Associates the specified value with the specified property name. |
|
void |
setClassloader(ClassLoader classloader)
|
|
void |
setLocale(Locale locale)
Sets the locale of this manager used for the internationalization of the relative toolwindow manager. |
|
void |
setTransparencyManager(TransparencyManager<Window> transparencyManager)
Sets the transparency manager for the windows used to manage transparency of toolwindows of FLOATING or FLOATING_FREE type. |
|
void |
setUserBundle(Locale locale,
String bundle,
ClassLoader classLoader)
Sets the bundle used for the internationalization of special strings like the the toolwindow id. |
|
void |
setUserBundle(ResourceBundle userBundle)
Sets the bundle used for the internationalization of special strings like the the toolwindow id. |
|
| Methods inherited from interface org.noos.xing.mydoggy.Observable |
|---|
addPropertyChangeListener, addPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListener |
| Method Detail |
|---|
void setClassloader(ClassLoader classloader)
<T> T createInstance(Class<T> clazz,
Context context)
clazz using passed args.
clazz - the class of the instance to be returned.context - a context where retrieve arguments.
clazz using passed args.
<T extends Component> T createComponent(String key,
Context context)
key - key whose associated rule is used to create the component.context - a context where retrieve arguments.
ComponentUI createComponentUI(String key,
Context context)
key - key whose associated rule is used to create the component.context - a context where retrieve arguments.
<T extends Component> T applyCustomization(String key,
T component,
Context context)
key - key whose associated rule is used to customize the component.component - the component to be customized.context - a context where retrieve arguments.
Icon getIcon(String id)
id - id whose associated icon is to be returned.
Icon putIcon(String id,
Icon icon)
id - id with which the specified icon is to be associated.icon - icon to be associated with the specified id.
Color getColor(String id)
id - id whose associated color is to be returned.
Color putColor(String id,
Color color)
id - id with which the specified color is to be associated.color - color to be associated with the specified id.
TransparencyManager<Window> getTransparencyManager()
void setTransparencyManager(TransparencyManager<Window> transparencyManager)
transparencyManager - the transparency manager for the windows.BufferedImage getImage(String id)
id - id whose associated buffered image is to be returned.
void setLocale(Locale locale)
locale - the locale to become this manager's locale
void setUserBundle(Locale locale,
String bundle,
ClassLoader classLoader)
locale - the locale for which a resource bundle is desiredbundle - the base name of the resource bundle, a fully qualified class nameclassLoader - the class loader from which to load the resource bundlegetUserResourceBundle()void setUserBundle(ResourceBundle userBundle)
userBundle - the ResourceBundleResourceBundle getResourceBundle()
ResourceBundle getUserResourceBundle()
String getString(String key)
getResourceBundle().getString(key)
key - the key for the desired string
String getUserString(String key)
getUserResourceBundle().getString(key)
key - the key for the desired string
List<String> getColors()
List<String> getIcons()
String getProperty(String name)
null if the property is not found.
name - the property bame.
void putProperty(String name,
String value)
name - property name with which the specified value is to be associated.value - value to be associated with the specified name.
boolean getBoolean(String name,
boolean defaultValue)
defaultValue if the property is not found.
name - the property name.defaultValue - the default value if the property is not found.
void putBoolean(String name,
boolean value)
Boolean.toString(boolean).
name - name with which the string form of value is to be associated.value - value whose string form is to be associated with key.
NullPointerException - if key is null.getBoolean(String, boolean)
float getFloat(String name,
float defaultValue)
defaultValue if the property is not found.
name - the property name.defaultValue - the default value if the property is not found.
void putFloat(String name,
float value)
Float.toString(float).
name - name with which the string form of value is to be associated.value - value whose string form is to be associated with key.
NullPointerException - if key is null.getFloat(String, float)
int getInt(String name,
int defaultValue)
defaultValue if the property is not found.
name - the property name.defaultValue - the default value if the property is not found.
void putInt(String name,
int value)
Integer.toString(int).
name - name with which the string form of value is to be associated.value - value whose string form is to be associated with key.
NullPointerException - if key is null.getInt(String, int)
void putObject(Object key,
Object value)
key - key with which the specified value is to be associated.value - value to be associated with the specified name.
<T> T getObject(Class<T> clazz,
T defaultValue)
defaultValue if the object is not found.
clazz - the object class.defaultValue - the default value if the object is not found.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||