eric6/Helpviewer/WebPlugins/WebPluginInterface.py

changeset 7220
5cf645f6daab
parent 7218
eaf2cf171f3a
parent 7211
1c97f3142fa8
child 7221
0485ccdf7877
equal deleted inserted replaced
7218:eaf2cf171f3a 7220:5cf645f6daab
1 # -*- coding: utf-8 -*-
2
3 # Copyright (c) 2012 - 2019 Detlev Offenbach <detlev@die-offenbachs.de>
4 #
5
6 """
7 Module implementing the web plug-in interface.
8 """
9
10
11 from __future__ import unicode_literals
12
13
14 class WebPluginInterface(object):
15 """
16 Class implementing the web plug-in interface.
17 """
18 def metaPlugin(self):
19 """
20 Public method to create a meta plug-in object containing plug-in info.
21
22 @return meta plug-in object (QWebPluginFactory.Plugin)
23 @exception NotImplementedError raised to indicate that this method
24 must be implemented by subclasses
25 """
26 raise NotImplementedError
27
28 def create(self, mimeType, url, argumentNames, argumentValues):
29 """
30 Public method to create a plug-in instance for the given data.
31
32 @param mimeType MIME type for the plug-in (string)
33 @param url URL for the plug-in (QUrl)
34 @param argumentNames list of argument names (list of strings)
35 @param argumentValues list of argument values (list of strings)
36 @return reference to the created object (QWidget)
37 @exception NotImplementedError raised to indicate that this method
38 must be implemented by subclasses
39 """
40 raise NotImplementedError
41
42 def configure(self):
43 """
44 Public method to configure the plug-in.
45
46 @exception NotImplementedError raised to indicate that this method
47 must be implemented by subclasses
48 """
49 raise NotImplementedError
50
51 def isAnonymous(self):
52 """
53 Public method to indicate an anonymous plug-in.
54
55 @return flag indicating anonymous state (boolean)
56 """
57 return False

eric ide

mercurial