From 7f618aa3a7886ddc942f7a83a297233b5c39c921 Mon Sep 17 00:00:00 2001 From: Seoester Date: Thu, 30 May 2013 16:18:45 +0200 Subject: Recreated StreamcloudEu plugin using XFileSharingPro --- module/plugins/hoster/StreamcloudEu.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 module/plugins/hoster/StreamcloudEu.py (limited to 'module/plugins/hoster/StreamcloudEu.py') diff --git a/module/plugins/hoster/StreamcloudEu.py b/module/plugins/hoster/StreamcloudEu.py new file mode 100644 index 000000000..eee9b5d67 --- /dev/null +++ b/module/plugins/hoster/StreamcloudEu.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +from module.plugins.hoster.XFileSharingPro import XFileSharingPro, create_getInfo +import re + +class StreamcloudEu(XFileSharingPro): + __name__ = "StreamcloudEu" + __type__ = "hoster" + __pattern__ = r"https?://(www\.)?streamcloud\.eu/" + __version__ = "0.01" + __description__ = """Streamcloud.eu hoster plugin""" + __author_name__ = ("seoester") + __author_mail__ = ("seoester@googlemail.com") + + HOSTER_NAME = "streamcloud.eu" + DIRECT_LINK_PATTERN = r'file: "(https?://stor\d+\.streamcloud.eu:?\d*/.*/video\.mp4)",' + + def getDownloadLink(self): + found = re.search(self.DIRECT_LINK_PATTERN, self.html, re.S) + if found: + return found.group(1) + + return XFileSharingPro.getDownloadLink(self) -- cgit v1.2.3 From ec7645ffe3fe97db9f6d2efb249df47c624a418c Mon Sep 17 00:00:00 2001 From: Seoester Date: Thu, 30 May 2013 16:27:18 +0200 Subject: StreamcloudEu plugin: MultiDL enabled --- module/plugins/hoster/StreamcloudEu.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'module/plugins/hoster/StreamcloudEu.py') diff --git a/module/plugins/hoster/StreamcloudEu.py b/module/plugins/hoster/StreamcloudEu.py index eee9b5d67..a041d917c 100644 --- a/module/plugins/hoster/StreamcloudEu.py +++ b/module/plugins/hoster/StreamcloudEu.py @@ -14,9 +14,13 @@ class StreamcloudEu(XFileSharingPro): HOSTER_NAME = "streamcloud.eu" DIRECT_LINK_PATTERN = r'file: "(https?://stor\d+\.streamcloud.eu:?\d*/.*/video\.mp4)",' + def setup(self): + XFileSharingPro.setup(self) + self.multiDL = True + def getDownloadLink(self): found = re.search(self.DIRECT_LINK_PATTERN, self.html, re.S) if found: - return found.group(1) + return found.group(1) return XFileSharingPro.getDownloadLink(self) -- cgit v1.2.3 From d274fc9e0b3ff69b336eda724d77b01853f5fc2a Mon Sep 17 00:00:00 2001 From: Seoester Date: Thu, 30 May 2013 22:42:46 +0200 Subject: Improved DIRECT_LINK_PATTERN --- module/plugins/hoster/StreamcloudEu.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/hoster/StreamcloudEu.py') diff --git a/module/plugins/hoster/StreamcloudEu.py b/module/plugins/hoster/StreamcloudEu.py index a041d917c..3636dd029 100644 --- a/module/plugins/hoster/StreamcloudEu.py +++ b/module/plugins/hoster/StreamcloudEu.py @@ -12,7 +12,7 @@ class StreamcloudEu(XFileSharingPro): __author_mail__ = ("seoester@googlemail.com") HOSTER_NAME = "streamcloud.eu" - DIRECT_LINK_PATTERN = r'file: "(https?://stor\d+\.streamcloud.eu:?\d*/.*/video\.mp4)",' + DIRECT_LINK_PATTERN = r'file: "(https?://(stor|cdn)\d+\.streamcloud.eu:?\d*/.*/video\.mp4)",' def setup(self): XFileSharingPro.setup(self) -- cgit v1.2.3 From acb54e231e3fbe7c943f2fed222b91b8c4be0dff Mon Sep 17 00:00:00 2001 From: Seoester Date: Mon, 3 Jun 2013 17:47:00 +0200 Subject: More accurate regular expressions --- module/plugins/hoster/StreamcloudEu.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'module/plugins/hoster/StreamcloudEu.py') diff --git a/module/plugins/hoster/StreamcloudEu.py b/module/plugins/hoster/StreamcloudEu.py index 3636dd029..9c45e83d7 100644 --- a/module/plugins/hoster/StreamcloudEu.py +++ b/module/plugins/hoster/StreamcloudEu.py @@ -5,14 +5,14 @@ import re class StreamcloudEu(XFileSharingPro): __name__ = "StreamcloudEu" __type__ = "hoster" - __pattern__ = r"https?://(www\.)?streamcloud\.eu/" + __pattern__ = r"http://(www\.)?streamcloud\.eu/\S+" __version__ = "0.01" __description__ = """Streamcloud.eu hoster plugin""" __author_name__ = ("seoester") __author_mail__ = ("seoester@googlemail.com") HOSTER_NAME = "streamcloud.eu" - DIRECT_LINK_PATTERN = r'file: "(https?://(stor|cdn)\d+\.streamcloud.eu:?\d*/.*/video\.mp4)",' + DIRECT_LINK_PATTERN = r'file: "(http://(stor|cdn)\d+\.streamcloud.eu:?\d*/.*/video\.mp4)",' def setup(self): XFileSharingPro.setup(self) -- cgit v1.2.3 From 50466c97f81a9ef567f4c6397304891fb3d390b6 Mon Sep 17 00:00:00 2001 From: Seoester Date: Mon, 3 Jun 2013 20:26:31 +0200 Subject: Added create_getInfo call --- module/plugins/hoster/StreamcloudEu.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'module/plugins/hoster/StreamcloudEu.py') diff --git a/module/plugins/hoster/StreamcloudEu.py b/module/plugins/hoster/StreamcloudEu.py index 9c45e83d7..705bc4bb5 100644 --- a/module/plugins/hoster/StreamcloudEu.py +++ b/module/plugins/hoster/StreamcloudEu.py @@ -24,3 +24,5 @@ class StreamcloudEu(XFileSharingPro): return found.group(1) return XFileSharingPro.getDownloadLink(self) + +getInfo = create_getInfo(StreamcloudEu) -- cgit v1.2.3 From 3c75929ef6240e260f97e335ac23fc8275f03b48 Mon Sep 17 00:00:00 2001 From: Seoester Date: Mon, 3 Jun 2013 21:22:57 +0200 Subject: super() function used --- module/plugins/hoster/StreamcloudEu.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'module/plugins/hoster/StreamcloudEu.py') diff --git a/module/plugins/hoster/StreamcloudEu.py b/module/plugins/hoster/StreamcloudEu.py index 705bc4bb5..9e7c61ccc 100644 --- a/module/plugins/hoster/StreamcloudEu.py +++ b/module/plugins/hoster/StreamcloudEu.py @@ -15,7 +15,7 @@ class StreamcloudEu(XFileSharingPro): DIRECT_LINK_PATTERN = r'file: "(http://(stor|cdn)\d+\.streamcloud.eu:?\d*/.*/video\.mp4)",' def setup(self): - XFileSharingPro.setup(self) + super(XFileSharingPro, self).setup() self.multiDL = True def getDownloadLink(self): @@ -23,6 +23,6 @@ class StreamcloudEu(XFileSharingPro): if found: return found.group(1) - return XFileSharingPro.getDownloadLink(self) + return super(XFileSharingPro, self).getDownloadLink() getInfo = create_getInfo(StreamcloudEu) -- cgit v1.2.3