Package host.anzo.commons.text
Class RandomNameGenerator
java.lang.Object
host.anzo.commons.text.RandomNameGenerator
RandomNameGenerator is a singleton class that generates random names
by combining adjectives and nouns loaded from text files.
The generated names are unique based on the current seed.
- Since:
- 8/17/2021
-
Method Summary
-
Method Details
-
size
public int size()Returns the total size of the combined words from adjectives and nouns.- Returns:
- the total number of unique combinations of adjectives and nouns
-
nextName
Generates a random name by combining an adjective, a noun, and a random number. The name is generated based on the current seed, ensuring uniqueness.- Returns:
- a randomly generated name in the format "AdjectiveNounNumber"
-