Class: ItunesController::Track

Inherits:
Object
  • Object
show all
Defined in:
lib/itunesController/track.rb

Overview

Used to store track information

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(location, databaseId, title) ⇒ Track

Returns a new instance of Track.



28
29
30
31
32
# File 'lib/itunesController/track.rb', line 28

def initialize(location,databaseId,title)
    @location = location
    @databaseId = databaseId
    @title = title
end

Instance Attribute Details

#databaseIdObject

Returns the value of attribute databaseId.



26
27
28
# File 'lib/itunesController/track.rb', line 26

def databaseId
  @databaseId
end

#locationObject

Returns the value of attribute location.



26
27
28
# File 'lib/itunesController/track.rb', line 26

def location
  @location
end

#titleObject

Returns the value of attribute title.



26
27
28
# File 'lib/itunesController/track.rb', line 26

def title
  @title
end

Instance Method Details

#to_sObject



34
35
36
# File 'lib/itunesController/track.rb', line 34

def to_s
    return "Location: '#{@location}' - Database ID: #{@databaseId} - Title: '#{@title}' "
end