summaryrefslogtreecommitdiffstats
path: root/module/plugins/hooks
diff options
context:
space:
mode:
authorGravatar synweap15 <shamdog+github@gmail.com> 2014-07-08 20:03:27 +0200
committerGravatar synweap15 <shamdog+github@gmail.com> 2014-07-08 20:03:27 +0200
commit2404538888ced4e6964df55823d0514b1c0ba685 (patch)
tree5a8c1dd97f1582615d84577b976b8be524637efb /module/plugins/hooks
parent[Oboom] new hoster and account (diff)
downloadpyload-2404538888ced4e6964df55823d0514b1c0ba685.tar.xz
rapideo.pl files added
Diffstat (limited to 'module/plugins/hooks')
-rw-r--r--module/plugins/hooks/RapideoPl.py38
1 files changed, 38 insertions, 0 deletions
diff --git a/module/plugins/hooks/RapideoPl.py b/module/plugins/hooks/RapideoPl.py
new file mode 100644
index 000000000..5d7673826
--- /dev/null
+++ b/module/plugins/hooks/RapideoPl.py
@@ -0,0 +1,38 @@
+# !/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+"""
+@author: Pawel W. <dev@rapideo.pl>
+"""
+from module.plugins.internal.MultiHoster import MultiHoster
+from module.network.RequestFactory import getURL
+
+try:
+ from json import loads
+except ImportError:
+ from simplejson import loads
+
+class RapideoPl(MultiHoster):
+ __name__ = "RapideoPl"
+ __version__ = "0.01"
+ __type__ = "hook"
+
+ __config__ = [("activated", "bool", "Activated", "False"),
+ ("hosterListMode", "all;listed;unlisted", "Use for hosters (if supported):", "all"),
+ ("hosterList", "str", "Hoster list (comma separated)", ""),
+ ("unloadFailing", "bool", "Try standard download if download fails", "False"),
+ ("interval", "int", "Reload supported hosts interval in hours (0 to disable)", "24")]
+
+ __description__ = "Rapideo.pl hook"
+ __author_name__ = ("goddie")
+ __author_mail__ = ("dev@rapideo.pl")
+
+ def getHoster(self):
+
+ hostings = loads(getURL("https://www.rapideo.pl/clipboard.php?json=3").strip())
+ return [domain for row in hostings for domain in row["domains"] if row["sdownload"] == "0"]
+
+ def getHosterCached(self):
+ return self.getHoster()
+
+