MCPcopy Create free account
hub / github.com/Card-Forge/forge / getPlural

Method getPlural

forge-core/src/main/java/forge/util/Lang.java:135–138  ·  view source on GitHub ↗
(final String noun)

Source from the content-addressed store, hash-verified

133 }
134
135 public static String getPlural(final String noun) {
136 return noun + (noun.endsWith("s") && !noun.endsWith("ds") || noun.endsWith("x") || noun.endsWith("ch") ? "es"
137 : noun.endsWith("ds") ? "" : "s");
138 }
139
140 public static String nounWithAmount(final int cnt, final String noun) {
141 final String countedForm = cnt == 1 ? noun : getPlural(noun);

Callers 8

toStringMethod · 0.95
parseMethod · 0.95
nounWithAmountMethod · 0.95
nounWithNumeralMethod · 0.95
getSubTitleMethod · 0.95
getSubTitleMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected