X-Git-Url: https://git.kaliko.me/?a=blobdiff_plain;f=sima%2Flib%2Fplayer.py;h=ea84a648632a2ae76b36811a651517e69dc5d62d;hb=ab9952e0258426133f6bb0fe6395ec7464dfdd33;hp=9f2910d048548bd3a1544b1c6ef4a85a7242b269;hpb=611f98994247324793027cae02d77e5a8efd0f42;p=mpd-sima.git diff --git a/sima/lib/player.py b/sima/lib/player.py index 9f2910d..ea84a64 100644 --- a/sima/lib/player.py +++ b/sima/lib/player.py @@ -3,6 +3,9 @@ # TODO: # Add decorator to filter through history? +# standart library import +import logging + # local import #from sima.lib.track import Track @@ -16,8 +19,8 @@ class Player(object): """ def __init__(self): - self.state = {} - self.current = {} + super().__init__() + self.log = logging.getLogger('sima') def monitor(self): """Monitor player for change @@ -47,10 +50,31 @@ class Player(object): def find_album(self, artist, album): """ Find tracks by track's album name - >>> player.find_track('Nirvana', 'Nevermind') + >>> player.find_album('Nirvana', 'Nevermind') Returns a list of Track objects """ + raise NotImplementedError + + def find_albums(self, artist): + """ + Find albums by artist's name + >>> player.find_alums('Nirvana') + + Returns a list of string objects + """ + raise NotImplementedError + + def fuzzy_find(self, artist): + """ + Find artists based on a fuzzy search in the media library + >>> bea = player.fuzzy_find('beatles') + >>> print(bea) + >>> ['The Beatles'] + + Returns a list of strings (artist names) + """ + raise NotImplementedError def disconnect(self): """Closing client connection with the Player @@ -64,4 +88,3 @@ class Player(object): # VIM MODLINE # vim: ai ts=4 sw=4 sts=4 expandtab -