]> kaliko git repositories - mpd-sima.git/blob - sima/lib/plugin.py
Add SimaDB and deal with history
[mpd-sima.git] / sima / lib / plugin.py
1 # -*- coding: utf-8 -*-
2
3 class Plugin():
4     def __init__(self, daemon):
5         self.log = daemon.log
6         self.__daemon = daemon
7         #self.history = daemon.player.history
8
9     @property
10     def name(self):
11         return self.__class__.__name__.lower()
12
13     def callback_player(self):
14         """
15         Called on player changes
16         """
17         pass
18
19     def callback_playlist(self):
20         """
21         Called on playlist changes
22
23         Not returning data
24         """
25         pass
26
27     def callback_next_song(self):
28         """Not returning data,
29         Could be use to scrobble
30         """
31         pass
32
33     def callback_need_song(self):
34         """Returns a list of Track objects to add
35         """
36         pass
37
38     def shutdown(self):
39         pass
40
41
42 # VIM MODLINE
43 # vim: ai ts=4 sw=4 sts=4 expandtab