From the NannyMUD documentation
2004-12-07
lingua - An object handling linguistic inflections.
/obj/lingua.c
indef_article pluralize pluralp singularize vocp
This object provides functions related to the English language.
NAME
indef_article - Adds the indefinite article.LOCATION
/obj/lingua.cSYNTAX
string indef_article(string word)DESCRIPTION
This function adds the appropriate indefinite article to the word and returns it.RETURN VALUES
"a " + word or "an " + word.
FUNCTION
NAME
pluralize - Forms the plural.LOCATION
/obj/lingua.cSYNTAX
string pluralize(string word) string pluralize(string word, int classical)DESCRIPTION
This function returns the plural version of the given word. If you use the classical flag, and there is a classical plural inflection, that will be returned instead.RETURN VALUES
Generally word + "s", but it handles many irregularities.
FUNCTION
NAME
pluralp - Is a word in plural form?LOCATION
/obj/lingua.cSYNTAX
int pluralp(string word)DESCRIPTION
This function attempts to determine if the word is in plural form.
FUNCTION
NAME
singularize - Forms the possible singulars.LOCATION
/obj/lingua.cSYNTAX
string *singularize(string word)DESCRIPTION
This function returns possible candidates for the singular form of the word. It does not know if any of them are actual real words.
FUNCTION
NAME
vocp - Should the word be preceeded by 'an'?LOCATION
/obj/lingua.cSYNTAX
int vocp(string word)DESCRIPTION
This function is near obsolete. Use indef_article() instead.