Class: Syobocal::Comment::Music

Inherits:
Object
  • Object
show all
Defined in:
lib/syobocal/comment/music.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(title, category, data_list) ⇒ Music

Returns a new instance of Music.



6
7
8
# File 'lib/syobocal/comment/music.rb', line 6

def initialize(title, category, data_list)
  @title, @category, @data_list = title, category, data_list
end

Instance Attribute Details

#categoryObject (readonly)

Returns the value of attribute category.



4
5
6
# File 'lib/syobocal/comment/music.rb', line 4

def category
  @category
end

#data_listObject (readonly)

Returns the value of attribute data_list.



4
5
6
# File 'lib/syobocal/comment/music.rb', line 4

def data_list
  @data_list
end

#titleObject (readonly)

Returns the value of attribute title.



4
5
6
# File 'lib/syobocal/comment/music.rb', line 4

def title
  @title
end

Instance Method Details

#==(other) ⇒ Object



10
11
12
# File 'lib/syobocal/comment/music.rb', line 10

def ==(other)
  other.instance_of?(self.class) && other.title == title && other.category == category && other.data_list == data_list
end