|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mentawai.list.LocalizedListData
public class LocalizedListData
This class implements a ListData that supports multiple locales. It is a ListData that you can construct by-hand by adding the items using the add methods. The difference of LocalizedListData from SimpleListData is that SimpleListData does not support locales, in other words, it can only be used to construct lists that will return the same list for every locale. (non-localized list)
| Constructor Summary | |
|---|---|
LocalizedListData(String name)
|
|
| Method Summary | |
|---|---|
void |
add(int id,
String value,
Locale loc)
|
void |
add(String id,
String value,
Locale loc)
|
void |
clear()
|
String |
getName()
Returns the name of this list. |
String |
getValue(int id)
Returns the string value of the list data item with the given id with the default locale. |
String |
getValue(int id,
Locale loc)
Returns the string value of the list data item with the given id in the given locale. |
String |
getValue(String id)
Returns the string value for the list data item with the default locale. |
String |
getValue(String id,
Locale loc)
Returns the string value of the list data item with the given id in the given locale. |
List<ListItem> |
getValues()
Returns a list of ListItem for the default locale. |
List<ListItem> |
getValues(Locale loc)
Returns a list of ListItem in the given locale. |
int |
size()
Returns the size of this list. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public LocalizedListData(String name)
| Method Detail |
|---|
public void clear()
public void add(int id,
String value,
Locale loc)
public void add(String id,
String value,
Locale loc)
public String getValue(int id,
Locale loc)
ListData
getValue in interface ListDataid - The id of the list data item.loc - The locale of the list data item.
public String getValue(String id)
ListData
getValue in interface ListDatapublic String getValue(int id)
ListData
getValue in interface ListDataid - The id of the list data item
public String getValue(String id,
Locale loc)
ListData
getValue in interface ListDataid - The id of the list data item.loc - The locale of the list data item.
public List<ListItem> getValues(Locale loc)
ListData
getValues in interface ListDataloc - The locale of the ListItems.
public List<ListItem> getValues()
ListData
getValues in interface ListDatapublic String getName()
ListData
getName in interface ListDatapublic int size()
ListData
size in interface ListDatapublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||