class Faker::Movies::Tron
Public Class Methods
character()
click to toggle source
Produces a character from Tron
.
@return [String]
@example
Faker::Movies::Tron.character #=> "Bit"
@faker.version next
# File lib/faker/movies/tron.rb, line 16 def character sample(characters) end
characters()
click to toggle source
# File lib/faker/movies/tron.rb, line 131 def characters translate('faker.tron.characters').values.flatten end
game()
click to toggle source
Produces a game from Tron
.
@return [String]
@example
Faker::Movies::Tron.game #=> "Space Paranoids"
@faker.version next
# File lib/faker/movies/tron.rb, line 29 def game sample(games) end
games()
click to toggle source
# File lib/faker/movies/tron.rb, line 135 def games fetch_all('tron.games') end
location()
click to toggle source
Produces a location from Tron
.
@return [String]
@example
Faker::Movies::Tron.location #=> "Flynn's Arcade"
@faker.version next
# File lib/faker/movies/tron.rb, line 42 def location sample(locations) end
locations()
click to toggle source
# File lib/faker/movies/tron.rb, line 139 def locations fetch_all('tron.locations') end
program()
click to toggle source
Produces a program from Tron
.
@return [String]
@example
Faker::Movies::Tron.program #=> "Clu"
@faker.version next
# File lib/faker/movies/tron.rb, line 55 def program sample(programs) end
programs()
click to toggle source
# File lib/faker/movies/tron.rb, line 143 def programs fetch_all('tron.characters.programs') end
quote(character: nil)
click to toggle source
Produces a quote from Tron
.
@param character [String] The name of a character to derive a quote from. @return [String]
@example
Faker::Movies::Tron.quote #=> "Greetings, Programs!"
@example
Faker::Movies::Tron.quote(character: "mcp") #=> "End of Line."
@faker.version next
# File lib/faker/movies/tron.rb, line 73 def quote(character: nil) quoted_characters = translate('faker.tron.quotes') if character.nil? character = sample(quoted_characters.keys).to_s else character = character.to_s.downcase # check alternate spellings, nicknames, titles of characters translate('faker.tron.alternate_character_spellings').each do |k, v| character = k.to_s if v.include?(character) end raise ArgumentError, "Character for quotes can be left blank or #{quoted_characters.keys.join(', ')}" unless quoted_characters.key?(character.to_sym) end fetch("tron.quotes.#{character}") end
tagline()
click to toggle source
Produces a tagline from Tron
.
@return [String]
@example
Faker::Movies::Tron.tagline #=> "The Electronic Gladiator"
@faker.version next
# File lib/faker/movies/tron.rb, line 101 def tagline sample(taglines) end
taglines()
click to toggle source
# File lib/faker/movies/tron.rb, line 147 def taglines fetch_all('tron.taglines') end
user()
click to toggle source
Produces a user from Tron
.
@return [String]
@example
Faker::Movies::Tron.user #=> "Light Cycle"
@faker.version next
# File lib/faker/movies/tron.rb, line 114 def user sample(users) end
users()
click to toggle source
# File lib/faker/movies/tron.rb, line 151 def users fetch_all('tron.characters.users') end
vehicle()
click to toggle source
Produces a vehicle from Tron
.
@return [String]
@example
Faker::Movies::Tron.vehicle #=> "Light Cycle"
@faker.version next
# File lib/faker/movies/tron.rb, line 127 def vehicle sample(vehicles) end
vehicles()
click to toggle source
# File lib/faker/movies/tron.rb, line 155 def vehicles fetch_all('tron.vehicles') end