Class: Shortwave::Model::Group

Inherits:
BaseModel show all
Includes:
WeeklyCharts
Defined in:
lib/shortwave/model/group.rb

Overview

A Last.fm user group.

Attributes

name

the group name

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from WeeklyCharts

#album_chart, #artist_chart, #chart_dates, #track_chart

Methods inherited from BaseModel

facade_name, identified_by, inherited, link_to, #session=, sharable, shoutable, taggable

Instance Attribute Details

#nameObject

Returns the value of attribute name.



11
12
13
# File 'lib/shortwave/model/group.rb', line 11

def name
  @name
end

Instance Method Details

#membersObject

Returns the group’s members. Currently only 50 users are returned



16
17
18
# File 'lib/shortwave/model/group.rb', line 16

def members
  link :members, "User", name
end

#to_sObject

The group name



21
22
23
# File 'lib/shortwave/model/group.rb', line 21

def to_s
  name
end