org.robolectric.res.PluralRules Maven / Gradle / Ivy
package org.robolectric.res;
import java.util.List;
public class PluralRules extends TypedResource> {
public PluralRules(List data, ResType resType, XmlContext xmlContext) {
super(data, resType, xmlContext);
}
public Plural find(int quantity) {
for (Plural p : getData()) {
if (p.num == quantity && p.usedInEnglish) return p;
}
for (Plural p : getData()) {
if (p.num == -1) return p;
}
return null;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy