eric7/Documentation/Source/eric7.Plugins.UiExtensionPlugins.Translator.TranslatorEngines.DeepLEngine.html

branch
eric7
changeset 8372
e0227a7c850e
child 8596
d64760b2da50
equal deleted inserted replaced
8371:d6062691d424 8372:e0227a7c850e
1 <!DOCTYPE html>
2 <html><head>
3 <title>eric7.Plugins.UiExtensionPlugins.Translator.TranslatorEngines.DeepLEngine</title>
4 <meta charset="UTF-8">
5 <style>
6 body {
7 background: #EDECE6;
8 margin: 0em 1em 10em 1em;
9 color: black;
10 }
11
12 h1 { color: white; background: #85774A; }
13 h2 { color: white; background: #85774A; }
14 h3 { color: white; background: #9D936E; }
15 h4 { color: white; background: #9D936E; }
16
17 a { color: #BA6D36; }
18
19 </style>
20 </head>
21 <body>
22 <a NAME="top" ID="top"></a>
23 <h1>eric7.Plugins.UiExtensionPlugins.Translator.TranslatorEngines.DeepLEngine</h1>
24
25 <p>
26 Module implementing the DeepL translation engine.
27 </p>
28 <h3>Global Attributes</h3>
29
30 <table>
31 <tr><td>None</td></tr>
32 </table>
33 <h3>Classes</h3>
34
35 <table>
36
37 <tr>
38 <td><a href="#DeepLEngine">DeepLEngine</a></td>
39 <td>Class implementing the translation engine for the DeepL translation service.</td>
40 </tr>
41 </table>
42 <h3>Functions</h3>
43
44 <table>
45 <tr><td>None</td></tr>
46 </table>
47 <hr />
48 <hr />
49 <a NAME="DeepLEngine" ID="DeepLEngine"></a>
50 <h2>DeepLEngine</h2>
51
52 <p>
53 Class implementing the translation engine for the DeepL
54 translation service.
55 </p>
56 <h3>Derived from</h3>
57 TranslationEngine
58 <h3>Class Attributes</h3>
59
60 <table>
61 <tr><td>MaxTranslationTextLen</td></tr><tr><td>TranslatorUrl</td></tr>
62 </table>
63 <h3>Class Methods</h3>
64
65 <table>
66 <tr><td>None</td></tr>
67 </table>
68 <h3>Methods</h3>
69
70 <table>
71
72 <tr>
73 <td><a href="#DeepLEngine.__init__">DeepLEngine</a></td>
74 <td>Constructor</td>
75 </tr>
76 <tr>
77 <td><a href="#DeepLEngine.engineName">engineName</a></td>
78 <td>Public method to return the name of the engine.</td>
79 </tr>
80 <tr>
81 <td><a href="#DeepLEngine.getTranslation">getTranslation</a></td>
82 <td>Public method to translate the given text.</td>
83 </tr>
84 <tr>
85 <td><a href="#DeepLEngine.supportedLanguages">supportedLanguages</a></td>
86 <td>Public method to get the supported languages.</td>
87 </tr>
88 </table>
89 <h3>Static Methods</h3>
90
91 <table>
92 <tr><td>None</td></tr>
93 </table>
94
95 <a NAME="DeepLEngine.__init__" ID="DeepLEngine.__init__"></a>
96 <h4>DeepLEngine (Constructor)</h4>
97 <b>DeepLEngine</b>(<i>plugin, parent=None</i>)
98
99 <p>
100 Constructor
101 </p>
102 <dl>
103
104 <dt><i>plugin</i> (TranslatorPlugin)</dt>
105 <dd>
106 reference to the plugin object
107 </dd>
108 <dt><i>parent</i> (QObject)</dt>
109 <dd>
110 reference to the parent object
111 </dd>
112 </dl>
113 <a NAME="DeepLEngine.engineName" ID="DeepLEngine.engineName"></a>
114 <h4>DeepLEngine.engineName</h4>
115 <b>engineName</b>(<i></i>)
116
117 <p>
118 Public method to return the name of the engine.
119 </p>
120 <dl>
121 <dt>Return:</dt>
122 <dd>
123 engine name
124 </dd>
125 </dl>
126 <dl>
127 <dt>Return Type:</dt>
128 <dd>
129 str
130 </dd>
131 </dl>
132 <a NAME="DeepLEngine.getTranslation" ID="DeepLEngine.getTranslation"></a>
133 <h4>DeepLEngine.getTranslation</h4>
134 <b>getTranslation</b>(<i>requestObject, text, originalLanguage, translationLanguage</i>)
135
136 <p>
137 Public method to translate the given text.
138 </p>
139 <dl>
140
141 <dt><i>requestObject</i></dt>
142 <dd>
143 reference to the request object
144 (TranslatorRequest)
145 </dd>
146 <dt><i>text</i></dt>
147 <dd>
148 text to be translated (string)
149 </dd>
150 <dt><i>originalLanguage</i></dt>
151 <dd>
152 language code of the original (string)
153 </dd>
154 <dt><i>translationLanguage</i></dt>
155 <dd>
156 language code of the translation (string)
157 </dd>
158 </dl>
159 <dl>
160 <dt>Return:</dt>
161 <dd>
162 tuple of translated text (string) and flag indicating
163 success (boolean)
164 </dd>
165 </dl>
166 <a NAME="DeepLEngine.supportedLanguages" ID="DeepLEngine.supportedLanguages"></a>
167 <h4>DeepLEngine.supportedLanguages</h4>
168 <b>supportedLanguages</b>(<i></i>)
169
170 <p>
171 Public method to get the supported languages.
172 </p>
173 <dl>
174 <dt>Return:</dt>
175 <dd>
176 list of supported language codes
177 </dd>
178 </dl>
179 <dl>
180 <dt>Return Type:</dt>
181 <dd>
182 list of str
183 </dd>
184 </dl>
185 <div align="right"><a href="#top">Up</a></div>
186 <hr />
187 </body></html>

eric ide

mercurial