public class PluralsResourceValue extends ResourceValue
mValue| Constructor and Description |
|---|
PluralsResourceValue(java.lang.String name,
boolean isFramework) |
PluralsResourceValue(java.lang.String name,
boolean isFramework,
java.lang.String libraryName)
Constructs a new PluralsResourceValue
|
| Modifier and Type | Method and Description |
|---|---|
void |
addPlural(java.lang.String quantity,
java.lang.String value)
Adds an element into the array
|
int |
getPluralsCount()
Returns the number of plural string
|
java.lang.String |
getQuantity(int index)
Returns the quantity at the given index, such as "one", "two", "few", etc.
|
java.lang.String |
getValue()
Returns the value of the resource, as defined in the XML.
|
java.lang.String |
getValue(int index)
Returns the string element at the given index position.
|
java.lang.String |
getValue(java.lang.String quantity)
Returns the string element for the given quantity
|
equals, getLibraryName, getRawXmlValue, getResourceType, hashCode, isUserDefined, replaceWith, setValue, toStringgetName, isFrameworkpublic PluralsResourceValue(java.lang.String name,
boolean isFramework)
public PluralsResourceValue(java.lang.String name,
boolean isFramework,
java.lang.String libraryName)
name - the name of the arrayisFramework - whether this is a framework resourcepublic void addPlural(java.lang.String quantity,
java.lang.String value)
public int getPluralsCount()
public java.lang.String getQuantity(int index)
index - the index, which must be in the range [0..getPluralsCount()].public java.lang.String getValue(int index)
index - index, which must be in the range [0..getPluralsCount()].public java.lang.String getValue(java.lang.String quantity)
quantity - the quantity string, such as "one", "two", "few", etc.public java.lang.String getValue()
ResourceValuenull,
for example for instances of StyleResourceValue.getValue in class ResourceValue