Class CharacterGenerator

java.lang.Object
mocka.generator.AbstractGenerator<Character>
mocka.generator.primitive.CharacterGenerator
All Implemented Interfaces:
Generator<Character>

public class CharacterGenerator extends AbstractGenerator<Character>
  • Method Details

    • getInstance

      public static CharacterGenerator getInstance()
    • get

      public Character get()
      returns a random English alphabet character (a-z or A-Z)
    • getCharacter

      public Character getCharacter(Locale locale)
      returns a random character based on the given locale. (english or korean)
    • getCharacter

      public Character getCharacter()
      returns a random English alphabet character ([a-z] or [A-Z])
    • getCharacter

      public Character getCharacter(Character min, Character max)
      returns a random character between the given min and max values [min, mix]
    • pickFrom

      public Character pickFrom(List<Character> list)
      picks a random character from the given list
    • pickFrom

      public Character pickFrom(Character[] characters)
      picks a random character from the given array
    • getCharacter

      public Character getCharacter(String input)
      picks a random character from the given string
    • getCharacterNotIn

      public Character getCharacterNotIn(Set<Character> set)
      picks a random character not contained in the given set