class FindRecipe::Recipe::TrendingRecipe
Public Class Methods
all()
click to toggle source
# File lib/find_recipe/trending_recipe.rb, line 18 def self.all @@all end
create_recipes()
click to toggle source
Create recipes based off an array of recipe data hashes output by the scraper
# File lib/find_recipe/trending_recipe.rb, line 5 def self.create_recipes recipe_array = FindRecipe::Scraper.scrape_trending_recipes_page recipes = recipe_array.collect do |recipe| self.new(recipe) end recipes.each do |recipe| recipe.add_additional_recipe_data @@all << recipe end end