class Podcast
Attributes
producer[RW]
summary[RW]
title[RW]
url[RW]
Public Class Methods
all()
click to toggle source
# File lib/podcastme/podcast.rb, line 22 def self.all #all Podcasts will be called in the @@all class variable. @@all end
find(index)
click to toggle source
# File lib/podcastme/podcast.rb, line 6 def self.find(index) #find by index number and convert from string to integer. - 1 bc count starts at 0. #consider putting this method into a findable Module. @@all[index.to_i-1] end
new(title, producer, url, summary)
click to toggle source
# File lib/podcastme/podcast.rb, line 12 def initialize(title, producer, url, summary) #setting properties @title = title @producer = producer @url = url @summary = summary #all instances of Podcast will be stored in a class variable. @@all << self end