public static class Localizers.LabelLocalizer extends Localizers.DomainAwareLocalizer
Localizer
that localizes objects of type
JLabel
using the JLabel.setText(String)
and JComponent.setToolTipText(String)
methods.
Keys for both the text
and tooltip
String
s are obtained from the components
JComponent.getClientProperty(Object)
with
ResourceConstants.DEFAULT_TEXT_KEY
and
ResourceConstants.DEFAULT_DESCRIPTION_KEY
as keys.JComponent.putClientProperty(Object, Object)
,
JLabel.setText(String)
domain
Constructor and Description |
---|
Localizers.LabelLocalizer(ResourceDomain domain) |
Modifier and Type | Method and Description |
---|---|
void |
localize(java.lang.Object item)
Localizes the provided
Object . |
textString, tooltipString
public Localizers.LabelLocalizer(ResourceDomain domain)
domain
- public void localize(java.lang.Object item)
Localizer
Object
. The specific
meaning of localization
to be achieved is up
to the individual implementation.item
- the Object
to localizeLocalizers