Here's an algorithm for adding an apostrophe to a given input noun.
How would you contruct a string to show ownership?
/**
* apostrophizes the string properly
* <pre>
* curtis = curtis'
* shaun = shaun's
* </pre>
*
* @param input string to apostrophize
* @return apostrophized string or empty string if the input was empty or null.
*/
public static String apostrophize(String input) {
if (isEmpty(input)) return "";
if ("s".equalsIgnoreCase(StringUtils.right(input,1))) {
return input + "'";
} else {
return input + "'s";
}
}