Exemple #1
0
 def make_stream(cls, settings):
     stream = cls()
     stream._settings = settings
     stream.visible = False
     stream.input = InputUrls(urls=[InputUrl(id=InputUrl.generate_id())])
     stream.output = OutputUrls(urls=[OutputUrl(id=OutputUrl.generate_id(), uri=constants.DEFAULT_TEST_URL)])
     return stream
Exemple #2
0
 def make_stream(cls, settings):
     stream = cls()
     stream._settings = settings
     stream.input = InputUrls(urls=[InputUrl(id=InputUrl.generate_id())])
     stream.output = OutputUrls(
         urls=[OutputUrl(id=OutputUrl.generate_id())])
     return stream
Exemple #3
0
    def get_data(self) -> InputUrls:
        urls = InputUrls()
        for url in self.data['urls']:
            input = InputUrl(url['id'], url['uri'], url['user_agent'],
                             url['stream_link'], url['proxy'])
            urls.urls.append(input)

        return urls
Exemple #4
0
 def make_stream(cls, settings):
     stream = cls()
     stream.visible = False
     stream._settings = settings
     stream.input = InputUrls(urls=[InputUrl(id=InputUrl.generate_id())])
     return stream