module Faker::Name
Constants
- PREFIXES
- SUFFIXES
Public Instance Methods
first_name()
click to toggle source
# File lib/ffakerer/name.rb, line 16 def first_name FIRST_NAMES.rand end
last_name()
click to toggle source
# File lib/ffakerer/name.rb, line 20 def last_name LAST_NAMES.rand end
name()
click to toggle source
# File lib/ffakerer/name.rb, line 8 def name case rand(10) when 0 then "#{prefix} #{first_name} #{last_name}" when 1 then "#{first_name} #{last_name} #{suffix}" else "#{first_name} #{last_name}" end end
prefix()
click to toggle source
# File lib/ffakerer/name.rb, line 24 def prefix PREFIXES.rand end
suffix()
click to toggle source
# File lib/ffakerer/name.rb, line 28 def suffix SUFFIXES.rand end