1
0
mirror of https://github.com/danbee/mpd-client synced 2025-03-04 08:39:09 +00:00
mpd-client/lib/mpd_client/artist.rb

26 lines
312 B
Ruby

module MPDClient
class Artist
include ClassToProc
include Jsonable
attr :name
def initialize(name)
@name = name
end
def to_h
{
name: name
}
end
class << self
def all
MPDClient.conn.artists.sort.map(&self)
end
end
end
end