úΞ˛“óŽ      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ Ą˘Ł¤ĽŚ§¨ŠŞŤŹ­ Haskell 98alphabsinclai@turing.une.edu.au-ŽŻ,A response is either an ACK or some result. +Represents various MPD errors (aka. ACKs). An unknown ACK (aka. bug) File already exists (ACK 56)  An operation requiring playback  got interrupted (ACK 55)  Update already running (ACK 54) !Playlist loading failed (ACK 53) A system error (ACK 52) "Playlist at maximum size (ACK 51) $File or directory not found ACK 50) Unknown command (ACK 5)  Authentication required (ACK 4) "Invalid password supplied (ACK 3)  Invalid argument passed (ACK 2) BThe MPDError type is used to signal errors, both from the MPD and  otherwise.  ACK type and a message from the  server. Used for misc. errors The connection timed out MPD not responding °A connection to an MPD server. ą˛ł´ľThrow an exception. #Catch an exception from an action. $Run an MPD action against a server.  Host name.  Port number. #An action that supplies passwords. The action to run. śˇ¸šRefresh a connection. <Kill the server. Obviously, the connection is then invalid. Close an MPD connection. ş1Send a command to the MPD and return the result. ťź˝žżŔ ş   ş Haskell 98alphabsinclai@turing.une.edu.auŁRepresents an output device. Output' s ID number Output's name as defined in the MPD  configuration file !Represents the result of running p. !#Number of songs matching the query ""Total play time of matching songs #Represents a single song item. $%&'()*+,-Length in seconds .Year / Track number/ total tracks 0Position in set/ total in set 12#Container for database statistics. 34Number of artists. 5Number of albums. 6Number of songs. 7Daemon uptime in seconds. 8Total playing time. 9$Total play time of all the songs in  the database. :#Last database update in UNIX time. ;Container for MPD status. <=>A percentage (0-100) ?@A9A value that is incremented by the server every time the  playlist changes. BC Current song's position in the playlist. D Current song's playlist ID. E Time elapsed/ total time. F<Bitrate (in kilobytes per second) of playing song (if any). GCrossfade time. H Samplerate/bits/&channels for the chosen output device  (see mpd.conf). I-Job ID of currently running update (if any). JLast error message (if any). K*Represents the different playback states. LMNORepresents a song's playlist index. P(A playlist ID number that more robustly  identifies a song. Q,A playlist position index (starting from 0) R<A query is composed of a scope modifier and a query string. S Query with multiple conditions. TSimple query. UAvailable metadata types/(scope modifiers, used for searching the 4 database for entries with certain metadata values. VWXYZ[\]^_`abcdefTurn off an output device. gTurn on an output device. h-Retrieve information for all output devices. iUpdate the server' s database. #Optionally specify a list of paths j%List all metadata of metadata (sic). Metadata to list k;Non-recursively list the contents of a database directory. Optionally specify a path. lGList the songs (without metadata) in a database directory recursively. m Recursive k. Optionally specify a path n:Search the database for entries exactly matching a query. o5Search the database using case insensitive matching. p.Count the number of entries matching a query. qLike r, but returns a playlist id. rLike s( but returns a list of the files added. s1Add a song (or a whole directory) to a playlist. . Adds to current if no playlist is specified. I Will create a new playlist if the one specified does not already exist. ,Optionally specify a playlist to operate on tGClear a playlist. Clears current playlist if no playlist is specified. ? If the specified playlist does not exist, it will be created. &Optional name of a playlist to clear. uRemove a song from a playlist. 8 If no playlist is specified, current playlist is used.  Note that a playlist position (Q ) is required when operating on # playlists other than the current. ,Optionally specify a playlist to operate on vLoad an existing playlist. w!Move a song to a given position.  Note that a playlist position (Q ) is required when operating on # playlists other than the current. ,Optionally specify a playlist to operate on xDelete existing playlist. yRename an existing playlist. Name of playlist to be renamed New playlist name zSave the current playlist. {!Swap the positions of two songs. ? Note that the positions must be of the same type, i.e. mixing Q and P  will result in a no-op. |Shuffle the playlist. }5Retrieve metadata for songs in the current playlist. Optional playlist index. ~1Retrieve metadata for files in a given playlist. .Retrieve a list of files in a given playlist. €DRetrieve file paths and positions of songs in the current playlist. B Note that this command is only included for completeness sake; it's 1 deprecated and likely to disappear at any time. ARetrieve a list of changed songs currently in the playlist since  a given playlist version. ‚Like % but only returns positions and ids. ƒ?Search for songs in the current playlist with strict matching. „@Search case-insensitively with partial matches for songs in the  current playlist. … Get the currently playing song. †Set crossfading between songs. ‡Begin/continue playing. ˆPause playing. ‰Stop playing. ŠPlay the next song. ‹Play the previous song. ŒSeek to some point in a song. 0 Seeks in current song if no position is given. Set random playing. ŽSet repeating. Set the volume. 5Increase or decrease volume by a given percent, e.g.  ' volume 10'/ will increase the volume by 10 percent, while  ' volume (-10)'& will decrease it by the same amount. C Note that this command is only included for completeness sake ; it's + deprecated and may disappear at any time. ‘+Clear the current error message in status. ’'Retrieve a list of available commands. “)Retrieve a list of unavailable commands. ”,Retrieve a list of available song metadata. •*Retrieve a list of supported urlhandlers. –1Send password to server to authenticate session. ! Password is sent as plain text. —+Check that the server is still responding. ˜Get server statistics. ™Get the server' s status. šLike i!, but returns the update job id. › Toggles play/pause. Plays if stopped. œAdd a list of songs/folders to a playlist. ' Should be more efficient than running r many times. (Delete a list of songs from a playlist. C If there is a duplicate then no further songs will be deleted, so  take care to avoid them (see Ÿ for this). žCrop playlist.  The bounds are inclusive.  If Á or P7 is passed the cropping will leave your playlist alone  on that side. Ÿ#Remove duplicate playlist entries.  "List directories non-recursively. optional path. ĄList files non-recursively. optional path. ˘List all playlists. Ł5Search the database for songs relating to an artist. ¤4Search the database for songs relating to an album. Ľ8Search the database for songs relating to a song title. Ś"List the artists in the database. §=List the albums in the database, optionally matching a given  artist. ¨+List the songs in an album of some artist. Š:Search the database for songs relating to an artist using o. Ş9Search the database for songs relating to an album using o. Ť8Search the database for songs relating to a song title. ŹRetrieve the current playlist.  Equivalent to 'playlistinfo Nothing'. ĂÄĹĆÇČÉĘËĚÍÎĎĐѕ !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ Ą˘Ł¤ĽŚ§¨ŠŞŤŹ“ !" !"#$%&'()*+,-./01$%&'()*+,-./0123456789:3456789:;<=>?@ABCDEFGHIJ<=>?@ABCDEFGHIJKNMLLMNOQPPQRTSSTU a`_^]\[ZYXWVVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ Ą˘Ł¤ĽŚ§¨ŠŞŤŹ Haskell 98alphabsinclai@turing.une.edu.au­ARun an MPD action using localhost:6600 as the default host:port, @ or whatever is found in the environment variables MPD_HOST and & MPD_PORT. If MPD_HOST is of the form "password@host" then the $ password will be supplied as well. Ň?Create an action that produces passwords for a connection. You  can pass these to ' and it will use them to get passwords ? to send to the server until one works or it runs out of them. 4 do gen <- mkPasswordGen ["password1", "password2"] / withMPDEx "localhost" 6600 gen (update []) Ž  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ Ą˘Ł¤ĽŚ§¨ŠŞŤŹ­Ž KNML;<=>?@ABCDEFGHIJ23456789:RTSUa`_^]\[ZYXWVedcbOQP#$%&'()*+,-./01 !"fghinjlmkoprsqt…uvw}~€‚ƒ„xyz|{†Šˆ‡‹ŽŒ‰‘’“”•–—˜™œžŸ Ą˘Ł¤ĽŚ§¨ŠŞŤŹ›š­­Ó      !""#$%%&'()*+,-./01233456789:;;<=>?@ABCDEFGHIJKLMNOPQRQSTUVWXYZ[\]^_`]^_abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ Ą˘Ł¤ĽŚ§¨ŠŞŤŹ­ŽŻ°ą˛ł´ľśˇ¸šşťź˝žżŔÁÂĂÄĹĆÇČÉĘËĚÍÎĎ libmpd-0.1.3 Network.MPDNetwork.MPD.PrimNetwork.MPD.CommandsMPDResponseACKType UnknownACK FileExists NotPlayingBusy PlaylistLoadSystem PlaylistMax FileNotFoundUnknownCommandAuthInvalidPasswordInvalidArgumentMPDErrorACKCustomTimedOutNoMPDthrowMPDcatchMPD withMPDEx reconnectkillcloseDevice dOutputID dOutputNamedOutputEnabledCountcSongs cPlaytimeSongsgArtistsgAlbumsgTitle sgFilePathsgGenresgName sgComposer sgPerformersgLengthsgDatesgTracksgDiscsgIndexStats stsArtists stsAlbumsstsSongs stsUptime stsPlaytime stsDbPlaytime stsDbUpdateStatusstStatestVolumestRepeatstRandomstPlaylistVersionstPlaylistLength stSongPosstSongIDstTime stBitrate stXFadeWidthstAudio stUpdatingDbstErrorStatePausedStoppedPlayingPLIndexIDPosQuery MultiQueryMetaFilenameAnyDisc PerformerComposerDateGenreNameTrackTitleAlbumArtistSeconds disableoutput enableoutputoutputsupdatelistlsinfolistAll listAllinfofindsearchcountaddidaddadd_cleardeleteloadmovermrenamesaveswapshuffle playlistinfolistplaylistinfo listplaylistplaylist plchangesplchangesposid playlistfindplaylistsearch currentSong crossfadeplaypausestopnextpreviousseekrandomrepeat setVolumevolume clearerrorcommands notcommandstagtypes urlhandlerspasswordpingstatsstatusupdateidtoggleaddMany deleteManycropprunelsdirslsfiles lsplaylists findArtist findAlbum findTitle listArtists listAlbums listAlbum searchArtist searchAlbum searchTitle getPlaylistwithMPDrunMPD ConnectionConn connHostName connPortNum connHandle connGetPassconnect safeConnectTo checkConncloseIO getResponse getLineTO tryPasswordrespRead parseResponseparseAcksplitAckbase Data.MaybeNothingfindDuplicates getResponse_ getResponsestoAssoc splitGroups takeValues takeEntries takeSongs takeSongInfo takeString takeIndextakeNumtakeBoolparseNumshowBool parseBool mkPasswordGen