POE::C...laylist(3pm)

πŸ“¦
version 2.001 Β· 3 versions
, in debian trixie, ubuntu resolute, ubuntu stonking

πŸ’– POE::C...laylist(3pm) πŸ’–

okay bestie, welcome to the manual page for POE::Component::Client::MPD::Playlist (from User Contributed Perl Documentation, no less πŸ‘‘). she's a whole module and she's here to serve.


✨ VERSION ✨

version 2.001 β€” periodt.


🌸 DESCRIPTION 🌸

so POE::Component::Client::MPD::Playlist is the girl in charge of handling general purpose commands. she lives in her own dedicated module purely so that code maintenance stays easy, which is honestly so valid of her. πŸ’…

here's the thing though, bestie, listen up:

To actually achieve those commands, you send the corresponding event to the POCOCM session you created. that session is the one responsible for dispatching the event wherever it needs to go. and under no circumstance β€” like, none, zero, nope β€” should you call subs or methods from this module directly. do not do it. i'm begging. πŸ™ˆ

go read POCOCM's pod to learn how to deal with answers coming back from those commands. iykyk.

and now, the moment you've been waiting for: the list of playlist-related events that POCOCM accepts. πŸŽ€


πŸ” RETRIEVING INFORMATION πŸ”

  • pl.as_items( ) β€” returns an array of Audio::MPD::Common::Item::Songs, one for each of the songs chillin' in the current playlist. one item per song, no more no less. πŸ’–
  • pl.items_changed_since( $plversion ) β€” returns a list of all the songs (as Audio::MPD::Common::Item::Song objects) that got added to the playlist since playlist $plversion. it's giving "what did i miss" energy. ✨

βž•βž– ADDING / REMOVING SONGS βž–βž•

  • pl.add( $path, $path, ... ) β€” adds the songs identified by $path (relative to MPD's music directory) to the current playlist. drop 'em in, bestie. 🎢
  • pl.delete( $number, $number, ... ) β€” removes song $number from the current playlist. heads up: numbering starts from 0, because of course it does. πŸ’€
  • pl.deleteid( $songid, $songid, ... ) β€” removes the specified $songid from the current playlist. that id is the one assigned by mpd when the song was inserted in the playlist, so it's the official receipt. 🧾
  • pl.clear( ) β€” removes all the songs from the current playlist. scorched earth, no survivors, iconic behaviour. πŸ”₯
  • pl.crop( ) β€” removes all of the songs from the current playlist *except* the current one. keeping only the main character, as she deserves. πŸ‘‘

πŸ”€ CHANGING PLAYLIST ORDER πŸ”€

  • pl.shuffle( ) β€” shuffles the current playlist. chaos mode activated. 🌈
  • pl.swap( $song1, $song2 ) β€” swaps the positions of song number $song1 and $song2 in the current playlist. trade places, girlies. πŸ’«
  • pl.swapid( $songid1, $songid2 ) β€” swaps the positions of song id $songid1 and $songid2 in the current playlist. same swap, but by id this time. πŸ¦‹
  • pl.move( $song, $newpos ) β€” moves song number $song to the position $newpos. she's relocating. 🚚
  • pl.moveid( $songid, $newpos ) β€” moves song id $songid to the position $newpos. again, same move, but by id. no cap. πŸ’…

πŸ“ MANAGING PLAYLISTS πŸ“

  • pl.load( $playlist ) β€” loads the list of songs from the specified $playlist file. opening the vault. πŸ—οΈ
  • pl.save( $playlist ) β€” saves the current playlist to a file called $playlist in MPD's playlist directory. archive her, she ate. πŸ’Ύ
  • pl.rm( $playlist ) β€” deletes the playlist named $playlist from MPD's playlist directory. gone, reduced to atoms. πŸ’€

πŸ‘‘ AUTHOR πŸ‘‘

Jerome Quelin πŸ’œ


This software is copyright (c) 2007 by Jerome Quelin.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. slay, legally speaking. 🫢


okay that's the whole page, bestie, you're all caught up. this lil doc was brought to you by perl v5.40.1 on 2025-04-11, source POE::C...laylist(3pm) β€” and yes she's still that girl. bye mwah πŸ’–πŸŽ€πŸŒΈ

πŸ“¦ where this page comes from