summaryrefslogtreecommitdiffstats
path: root/docs/plugins/crypter_plugin.rst
diff options
context:
space:
mode:
authorGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2012-01-29 20:09:11 +0100
committerGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2012-01-29 20:09:11 +0100
commit180a9ee57a6f4eaa5f4bdd7a272057231f6a5c88 (patch)
tree2c9f71dbe7122552aec0460344f2d4722df1f176 /docs/plugins/crypter_plugin.rst
parentclosed #523 (diff)
downloadpyload-180a9ee57a6f4eaa5f4bdd7a272057231f6a5c88.tar.xz
doc for base plugin
Diffstat (limited to 'docs/plugins/crypter_plugin.rst')
-rw-r--r--docs/plugins/crypter_plugin.rst20
1 files changed, 20 insertions, 0 deletions
diff --git a/docs/plugins/crypter_plugin.rst b/docs/plugins/crypter_plugin.rst
index d910ec412..639d58abf 100644
--- a/docs/plugins/crypter_plugin.rst
+++ b/docs/plugins/crypter_plugin.rst
@@ -3,3 +3,23 @@
Crypter - Extract links from pages
==================================
+What about Decrypter and Container plugins?
+Well, they work nearly the same, only that the function they have to provide is named ``decrypt``
+
+Example: ::
+
+ from module.plugin.Crypter import Crypter
+
+ class MyFileCrypter(Crypter):
+ """
+ plugin code
+ """
+ def decrypt(self, pyfile):
+
+ urls = ["http://get.pyload.org/src", "http://get.pyload.org/debian", "http://get.pyload.org/win"]
+
+ self.packages.append(("pyLoad packages", urls, "pyLoad packages")) # urls list of urls
+
+They can access all the methods from :class:`Plugin <module.plugins.Plugin.Plugin>`, but the important thing is they
+have to append all packages they parsed to the `self.packages` list. Simply append tuples with `(name, urls, folder)`,
+where urls is the list of urls contained in the packages. Thats all of your work, pyLoad will know what to do with them.