Interface Label
- All Known Subinterfaces:
Option
public interface Label
Label container interface for providing language dependent labels.
- Since:
- 4.0.30
-
Method Summary
Modifier and TypeMethodDescriptionTry getting a label in the following order: the label for the specified language; the label for thefallback language
; the value itself.Convenience method to get a label based on a language abbreviation.void
Set the label for the specified language.void
Convenience method to put a label based on a language abbreviation.
-
Method Details
-
getLabel
Try getting a label in the following order:- the label for the specified language;
- the label for the
fallback language
; - the value itself.
- Parameters:
language
- The language to look up.- Returns:
- The label.
- Since:
- 4.0.30
-
getLabel
@ApiDoc(comment="Convenience method to get a label based on a language abbreviation.", since="4.0.30") String getLabel(String lang) Convenience method to get a label based on a language abbreviation.- Parameters:
lang
- The language abbreviation.- Returns:
- The label.
- Since:
- 4.0.30
- See Also:
-
putLabel
@ApiDoc(comment="Set the label for the specified language.", since="4.0.30") void putLabel(Language language, String label) Set the label for the specified language.- Parameters:
language
- The language to store in.label
- The label to store.- Since:
- 4.0.30
-
putLabel
@ApiDoc(comment="Convenience method to put a label based on a language abbreviation.", since="4.0.30") void putLabel(String lang, String label) Convenience method to put a label based on a language abbreviation.- Parameters:
lang
- The language abbreviation.label
- The label to store.- Since:
- 4.0.30
-