fullName static method

String fullName()

Generates a random person's name which has the following structure

Implementation

/// Returns a random name.

static String fullName() {
  var result = '';

  if (RandomBoolean.chance(3, 5)) {
    result += RandomString.pick(RandomText._namePrefixes) + ' ';
  }

  result += RandomString.pick(RandomText._firstNames) +
      ' ' +
      RandomString.pick(RandomText._lastNames);

  if (RandomBoolean.chance(5, 10)) {
    result += ' ' + RandomString.pick(RandomText._nameSuffixes);
  }

  return result;
}