Class: ITunesCharts::ChartItem

Inherits:
Object
  • Object
show all
Defined in:
lib/itunes_charts/chart_item.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id, name, url, image = nil, parent = nil) ⇒ ChartItem

Returns a new instance of ChartItem.



5
6
7
8
9
10
11
# File 'lib/itunes_charts/chart_item.rb', line 5

def initialize(id, name, url, image=nil, parent=nil)
  self.id = id
  self.name = name
  self.url = url
  self.image = image
  self.parent = parent
end

Instance Attribute Details

#idObject

Returns the value of attribute id.



3
4
5
# File 'lib/itunes_charts/chart_item.rb', line 3

def id
  @id
end

#imageObject

Returns the value of attribute image.



3
4
5
# File 'lib/itunes_charts/chart_item.rb', line 3

def image
  @image
end

#nameObject

Returns the value of attribute name.



3
4
5
# File 'lib/itunes_charts/chart_item.rb', line 3

def name
  @name
end

#parentObject

Returns the value of attribute parent.



3
4
5
# File 'lib/itunes_charts/chart_item.rb', line 3

def parent
  @parent
end

#urlObject

Returns the value of attribute url.



3
4
5
# File 'lib/itunes_charts/chart_item.rb', line 3

def url
  @url
end