Exemple #1
0
 def getExpiring(self):
     """
     Returns a list of Program objects for expiring shows on the backend.
     """
     for prog in self._request('Dvr/GetExpiringList')\
                 .readJSON()['ProgramList']['Programs']:
         yield Program.fromJSON(prog, self.db)
Exemple #2
0
 def getExpiring(self):
     """
     Returns a list of Program objects for expiring shows on the backend.
     """
     for prog in self._request('Dvr/GetExpiring')\
                 .readJSON()['ProgramList']['Programs']:
         yield Program.fromJSON(prog, self.db)
Exemple #3
0
 def getRecorded(self, descending=True):
     """
     Returns a list of Program objects for recorded shows on the backend.
     """
     for prog in self._request('Dvr/GetRecorded', Descending=descending)\
                 .readJSON()['ProgramList']['Programs']:
         yield Program.fromJSON(prog, self.db)
Exemple #4
0
 def getRecorded(self, descending=True):
     """
     Returns a list of Program objects for recorded shows on the backend.
     """
     for prog in self._request('Dvr/GetRecorded', Descending=descending)\
                 .readJSON()['ProgramList']['Programs']:
         yield Program.fromJSON(prog, self.db)
Exemple #5
0
 def getCurrentRecording(self, recorder):
     """
     Returns a Program object for the current recorders recording.
     """
     res = self.backendCommand(
         'QUERY_RECORDER ' +
         BACKEND_SEP.join([str(recorder), 'GET_CURRENT_RECORDING']))
     return Program(res.split(BACKEND_SEP), db=self.db)
Exemple #6
0
 def getProgramDetails(self, chanid, starttime):
     """
     Returns a Program object for the matching show.
     """
     starttime = datetime.duck(starttime)
     args = {'ChanId': chanid, 'StartTime': starttime.utcisoformat()}
     return Program.fromJSON(
             self._request('Guide/GetProgramDetails', **args)\
                 .readJSON()['Program'],
             db=self.db)
Exemple #7
0
 def getProgramDetails(self, chanid, starttime):
     """
     Returns a Program object for the matching show.
     """
     starttime = datetime.duck(starttime)
     args = {'ChanId': chanid, 'StartTime': starttime.isoformat()}
     return Program.fromJSON(
             self._request('Guide/GetProgramDetails', **args)\
                 .readJSON()['Program'],
             db=self.db)
Exemple #8
0
 def getProgram(self):
     """Recorded.getProgram() -> Program object"""
     return Program.fromRecorded(self)
Exemple #9
0
 def getProgram(self):
     """Recorded.getProgram() -> Program object"""
     return Program.fromRecorded(self)