Permalink
Browse files

Remove legacy calls from MythDB, Frontend, and Grabber deprecated in

0.24.

Adds back MythVideo class and MythVideo.scanStorageGroups as legacy
wrappers around the new video scanner.
  • Loading branch information...
1 parent 35e0eb4 commit 412b2bf330701329d2c35a81fa9ee01627f5f8c9 @wagnerrp wagnerrp committed Jul 10, 2011
@@ -18,7 +18,8 @@
'MusicPlaylist', 'MusicDirectory']
__all_method__ = ['MythBE', 'BEEventMonitor', 'MythSystemEvent', \
- 'Frontend', 'MythDB', 'MythXML', 'MythMusic']
+ 'Frontend', 'MythDB', 'MythXML', 'MythMusic', \
+ 'MythVideo']
__all__ = ['static', 'MSearch', 'MythLog', 'StorageGroup']\
+__all_exceptions__\
@@ -575,19 +575,6 @@ def __init__(self, *args, **kwargs):
self.jump = self._Jump(self)
self.key = self._Key(self)
- def sendJump(self,jumppoint):
- """legacy - do not use"""
- return self.jump[jumppoint]
- def getJump(self):
- """legacy - do not use"""
- return self.jump.list()
- def sendKey(self,key):
- """legacy - do not use"""
- return self.key[key]
- def getKey(self):
- """legacy - do not use"""
- return self.key.list()
-
def sendQuery(self,query): return self.send('query', query)
def getQuery(self): return self.send('query')
def sendPlay(self,play): return self.send('play', play)
@@ -984,20 +971,12 @@ def searchVideos(self, init=False, key=None, value=None):
return ('videometadata.insertdate>%s', value, 0)
return None
- def getRecorded(self, title=None, subtitle=None, chanid=None,
- starttime=None, progstart=None):
- """legacy - do not use"""
- records = self.searchRecorded(title=title, subtitle=subtitle,\
- chanid=chanid, starttime=starttime,\
- progstart=progstart)
- try:
- return records.next()
- except StopIteration:
- return None
-
- def getChannels(self):
+class MythVideo( MythDB ):
+ """legacy - do not use"""
+ def scanStorageGroups(self, delete=True):
"""legacy - do not use"""
- return Channel.getAllEntries()
+ added, moved, deleted = scanVideos()
+ return (added, deleted)
class MythXML( XMLConnection ):
"""
@@ -361,10 +361,6 @@ def grabInetref(self, inetref, season=None, episode=None):
args = (inetref,)
return self.command('-D', *args).next()
- def grabTitle(self, title, subtitle):
- """legacy - do not use"""
- return self.search(title, subtitle)
-
class SystemEvent( System ):
"""
SystemEvent(eventname, db=None) -> SystemEvent object

0 comments on commit 412b2bf

Please sign in to comment.