summaryrefslogtreecommitdiff
path: root/libmpd.rb
diff options
context:
space:
mode:
authorDavid Vazgenovich Shakaryan <dvshakaryan@gmail.com>2009-07-23 22:24:29 -0700
committerDavid Vazgenovich Shakaryan <dvshakaryan@gmail.com>2009-07-23 22:24:29 -0700
commit518fd933403911ed23658c31e945cf88f44d462f (patch)
tree71806b5a048ff17a55ab1b6d852b05518292cb1a /libmpd.rb
parenta421c6c2baea85c0632ca5f2a3f8dc06c2833254 (diff)
downloadruby-libmpd-518fd933403911ed23658c31e945cf88f44d462f.tar.gz
ruby-libmpd-518fd933403911ed23658c31e945cf88f44d462f.tar.xz
New file for methods dealing with MPD status.
Diffstat (limited to 'libmpd.rb')
-rw-r--r--libmpd.rb17
1 files changed, 2 insertions, 15 deletions
diff --git a/libmpd.rb b/libmpd.rb
index 3fddded..ca96290 100644
--- a/libmpd.rb
+++ b/libmpd.rb
@@ -6,6 +6,7 @@
require 'socket'
require 'libmpd/playbackoptions'
+require 'libmpd/status'
class TrueClass # :nodoc:
def to_i
@@ -21,6 +22,7 @@ end
class MPD
include MPDPlaybackOptions
+ include MPDStatus
# Initialise an MPD object with the specified host and port.
#
@@ -67,21 +69,6 @@ class MPD
return hash
end
- # Returns a Hash containing information about the current song.
- def currentsong
- return generate_hash send_request 'currentsong'
- end
-
- # Returns a Hash containing the current status.
- def status
- return generate_hash send_request 'status'
- end
-
- # Returns a Hash containing statistics.
- def stats
- return generate_hash send_request 'stats'
- end
-
# Begins playing the playlist. If argument is supplied, begin at specified
# song position.
def play songpos=false