eric6/Documentation/Source/eric6.Plugins.UiExtensionPlugins.Translator.TranslatorEngines.GoogleV1Engine.html

changeset 7273
391d6b7b1eff
parent 6942
2602857055c5
child 7989
a21d673a8f99
equal deleted inserted replaced
7272:1779dc278077 7273:391d6b7b1eff
16 16
17 a { color: #BA6D36; } 17 a { color: #BA6D36; }
18 18
19 </style> 19 </style>
20 </head> 20 </head>
21 <body><a NAME="top" ID="top"></a> 21 <body>
22 <a NAME="top" ID="top"></a>
22 <h1>eric6.Plugins.UiExtensionPlugins.Translator.TranslatorEngines.GoogleV1Engine</h1> 23 <h1>eric6.Plugins.UiExtensionPlugins.Translator.TranslatorEngines.GoogleV1Engine</h1>
24
23 <p> 25 <p>
24 Module implementing the Google V1 translation engine. 26 Module implementing the Google V1 translation engine.
25 </p> 27 </p>
26 <h3>Global Attributes</h3> 28 <h3>Global Attributes</h3>
29
27 <table> 30 <table>
28 <tr><td>None</td></tr> 31 <tr><td>None</td></tr>
29 </table> 32 </table>
30 <h3>Classes</h3> 33 <h3>Classes</h3>
31 <table> 34
35 <table>
36
32 <tr> 37 <tr>
33 <td><a href="#GoogleV1Engine">GoogleV1Engine</a></td> 38 <td><a href="#GoogleV1Engine">GoogleV1Engine</a></td>
34 <td>Class implementing the translation engine for the old Google translation service.</td> 39 <td>Class implementing the translation engine for the old Google translation service.</td>
35 </tr> 40 </tr>
36 </table> 41 </table>
37 <h3>Functions</h3> 42 <h3>Functions</h3>
38 <table> 43
39 <tr><td>None</td></tr> 44 <table>
40 </table> 45 <tr><td>None</td></tr>
41 <hr /><hr /> 46 </table>
47 <hr />
48 <hr />
42 <a NAME="GoogleV1Engine" ID="GoogleV1Engine"></a> 49 <a NAME="GoogleV1Engine" ID="GoogleV1Engine"></a>
43 <h2>GoogleV1Engine</h2> 50 <h2>GoogleV1Engine</h2>
51
44 <p> 52 <p>
45 Class implementing the translation engine for the old Google 53 Class implementing the translation engine for the old Google
46 translation service. 54 translation service.
47 </p> 55 </p>
48 <h3>Derived from</h3> 56 <h3>Derived from</h3>
49 TranslationEngine 57 TranslationEngine
50 <h3>Class Attributes</h3> 58 <h3>Class Attributes</h3>
59
51 <table> 60 <table>
52 <tr><td>TextToSpeechLimit</td></tr><tr><td>TextToSpeechUrl</td></tr><tr><td>TranslatorUrl</td></tr> 61 <tr><td>TextToSpeechLimit</td></tr><tr><td>TextToSpeechUrl</td></tr><tr><td>TranslatorUrl</td></tr>
53 </table> 62 </table>
54 <h3>Class Methods</h3> 63 <h3>Class Methods</h3>
64
55 <table> 65 <table>
56 <tr><td>None</td></tr> 66 <tr><td>None</td></tr>
57 </table> 67 </table>
58 <h3>Methods</h3> 68 <h3>Methods</h3>
59 <table> 69
70 <table>
71
60 <tr> 72 <tr>
61 <td><a href="#GoogleV1Engine.__init__">GoogleV1Engine</a></td> 73 <td><a href="#GoogleV1Engine.__init__">GoogleV1Engine</a></td>
62 <td>Constructor</td> 74 <td>Constructor</td>
63 </tr><tr> 75 </tr>
76 <tr>
64 <td><a href="#GoogleV1Engine.engineName">engineName</a></td> 77 <td><a href="#GoogleV1Engine.engineName">engineName</a></td>
65 <td>Public method to return the name of the engine.</td> 78 <td>Public method to return the name of the engine.</td>
66 </tr><tr> 79 </tr>
80 <tr>
67 <td><a href="#GoogleV1Engine.getTextToSpeechData">getTextToSpeechData</a></td> 81 <td><a href="#GoogleV1Engine.getTextToSpeechData">getTextToSpeechData</a></td>
68 <td>Public method to pronounce the given text.</td> 82 <td>Public method to pronounce the given text.</td>
69 </tr><tr> 83 </tr>
84 <tr>
70 <td><a href="#GoogleV1Engine.getTranslation">getTranslation</a></td> 85 <td><a href="#GoogleV1Engine.getTranslation">getTranslation</a></td>
71 <td>Public method to translate the given text.</td> 86 <td>Public method to translate the given text.</td>
72 </tr><tr> 87 </tr>
88 <tr>
73 <td><a href="#GoogleV1Engine.hasTTS">hasTTS</a></td> 89 <td><a href="#GoogleV1Engine.hasTTS">hasTTS</a></td>
74 <td>Public method indicating the Text-to-Speech capability.</td> 90 <td>Public method indicating the Text-to-Speech capability.</td>
75 </tr><tr> 91 </tr>
92 <tr>
76 <td><a href="#GoogleV1Engine.supportedLanguages">supportedLanguages</a></td> 93 <td><a href="#GoogleV1Engine.supportedLanguages">supportedLanguages</a></td>
77 <td>Public method to get the supported languages.</td> 94 <td>Public method to get the supported languages.</td>
78 </tr> 95 </tr>
79 </table> 96 </table>
80 <h3>Static Methods</h3> 97 <h3>Static Methods</h3>
81 <table> 98
82 <tr><td>None</td></tr> 99 <table>
83 </table> 100 <tr><td>None</td></tr>
101 </table>
102
84 <a NAME="GoogleV1Engine.__init__" ID="GoogleV1Engine.__init__"></a> 103 <a NAME="GoogleV1Engine.__init__" ID="GoogleV1Engine.__init__"></a>
85 <h4>GoogleV1Engine (Constructor)</h4> 104 <h4>GoogleV1Engine (Constructor)</h4>
86 <b>GoogleV1Engine</b>(<i>plugin, parent=None</i>) 105 <b>GoogleV1Engine</b>(<i>plugin, parent=None</i>)
106
87 <p> 107 <p>
88 Constructor 108 Constructor
89 </p><dl> 109 </p>
110 <dl>
111
90 <dt><i>plugin</i></dt> 112 <dt><i>plugin</i></dt>
91 <dd> 113 <dd>
92 reference to the plugin object (TranslatorPlugin) 114 reference to the plugin object (TranslatorPlugin)
93 </dd><dt><i>parent</i></dt> 115 </dd>
116 <dt><i>parent</i></dt>
94 <dd> 117 <dd>
95 reference to the parent object (QObject) 118 reference to the parent object (QObject)
96 </dd> 119 </dd>
97 </dl><a NAME="GoogleV1Engine.engineName" ID="GoogleV1Engine.engineName"></a> 120 </dl>
121 <a NAME="GoogleV1Engine.engineName" ID="GoogleV1Engine.engineName"></a>
98 <h4>GoogleV1Engine.engineName</h4> 122 <h4>GoogleV1Engine.engineName</h4>
99 <b>engineName</b>(<i></i>) 123 <b>engineName</b>(<i></i>)
124
100 <p> 125 <p>
101 Public method to return the name of the engine. 126 Public method to return the name of the engine.
102 </p><dl> 127 </p>
128 <dl>
103 <dt>Returns:</dt> 129 <dt>Returns:</dt>
104 <dd> 130 <dd>
105 engine name (string) 131 engine name (string)
106 </dd> 132 </dd>
107 </dl><a NAME="GoogleV1Engine.getTextToSpeechData" ID="GoogleV1Engine.getTextToSpeechData"></a> 133 </dl>
134 <a NAME="GoogleV1Engine.getTextToSpeechData" ID="GoogleV1Engine.getTextToSpeechData"></a>
108 <h4>GoogleV1Engine.getTextToSpeechData</h4> 135 <h4>GoogleV1Engine.getTextToSpeechData</h4>
109 <b>getTextToSpeechData</b>(<i>requestObject, text, language</i>) 136 <b>getTextToSpeechData</b>(<i>requestObject, text, language</i>)
137
110 <p> 138 <p>
111 Public method to pronounce the given text. 139 Public method to pronounce the given text.
112 </p><dl> 140 </p>
141 <dl>
142
113 <dt><i>requestObject</i></dt> 143 <dt><i>requestObject</i></dt>
114 <dd> 144 <dd>
115 reference to the request object 145 reference to the request object
116 (TranslatorRequest) 146 (TranslatorRequest)
117 </dd><dt><i>text</i></dt> 147 </dd>
148 <dt><i>text</i></dt>
118 <dd> 149 <dd>
119 text to be pronounced (string) 150 text to be pronounced (string)
120 </dd><dt><i>language</i></dt> 151 </dd>
152 <dt><i>language</i></dt>
121 <dd> 153 <dd>
122 language code of the text (string) 154 language code of the text (string)
123 </dd> 155 </dd>
124 </dl><dl> 156 </dl>
157 <dl>
125 <dt>Returns:</dt> 158 <dt>Returns:</dt>
126 <dd> 159 <dd>
127 tuple with pronounce data (QByteArray) or error string (string) 160 tuple with pronounce data (QByteArray) or error string (string)
128 and success flag (boolean) 161 and success flag (boolean)
129 </dd> 162 </dd>
130 </dl><a NAME="GoogleV1Engine.getTranslation" ID="GoogleV1Engine.getTranslation"></a> 163 </dl>
164 <a NAME="GoogleV1Engine.getTranslation" ID="GoogleV1Engine.getTranslation"></a>
131 <h4>GoogleV1Engine.getTranslation</h4> 165 <h4>GoogleV1Engine.getTranslation</h4>
132 <b>getTranslation</b>(<i>requestObject, text, originalLanguage, translationLanguage</i>) 166 <b>getTranslation</b>(<i>requestObject, text, originalLanguage, translationLanguage</i>)
167
133 <p> 168 <p>
134 Public method to translate the given text. 169 Public method to translate the given text.
135 </p><dl> 170 </p>
171 <dl>
172
136 <dt><i>requestObject</i></dt> 173 <dt><i>requestObject</i></dt>
137 <dd> 174 <dd>
138 reference to the request object 175 reference to the request object
139 (TranslatorRequest) 176 (TranslatorRequest)
140 </dd><dt><i>text</i></dt> 177 </dd>
178 <dt><i>text</i></dt>
141 <dd> 179 <dd>
142 text to be translated (string) 180 text to be translated (string)
143 </dd><dt><i>originalLanguage</i></dt> 181 </dd>
182 <dt><i>originalLanguage</i></dt>
144 <dd> 183 <dd>
145 language code of the original (string) 184 language code of the original (string)
146 </dd><dt><i>translationLanguage</i></dt> 185 </dd>
186 <dt><i>translationLanguage</i></dt>
147 <dd> 187 <dd>
148 language code of the translation (string) 188 language code of the translation (string)
149 </dd> 189 </dd>
150 </dl><dl> 190 </dl>
191 <dl>
151 <dt>Returns:</dt> 192 <dt>Returns:</dt>
152 <dd> 193 <dd>
153 tuple of translated text (string) and flag indicating 194 tuple of translated text (string) and flag indicating
154 success (boolean) 195 success (boolean)
155 </dd> 196 </dd>
156 </dl><a NAME="GoogleV1Engine.hasTTS" ID="GoogleV1Engine.hasTTS"></a> 197 </dl>
198 <a NAME="GoogleV1Engine.hasTTS" ID="GoogleV1Engine.hasTTS"></a>
157 <h4>GoogleV1Engine.hasTTS</h4> 199 <h4>GoogleV1Engine.hasTTS</h4>
158 <b>hasTTS</b>(<i></i>) 200 <b>hasTTS</b>(<i></i>)
201
159 <p> 202 <p>
160 Public method indicating the Text-to-Speech capability. 203 Public method indicating the Text-to-Speech capability.
161 </p><dl> 204 </p>
205 <dl>
162 <dt>Returns:</dt> 206 <dt>Returns:</dt>
163 <dd> 207 <dd>
164 flag indicating the Text-to-Speech capability (boolean) 208 flag indicating the Text-to-Speech capability (boolean)
165 </dd> 209 </dd>
166 </dl><a NAME="GoogleV1Engine.supportedLanguages" ID="GoogleV1Engine.supportedLanguages"></a> 210 </dl>
211 <a NAME="GoogleV1Engine.supportedLanguages" ID="GoogleV1Engine.supportedLanguages"></a>
167 <h4>GoogleV1Engine.supportedLanguages</h4> 212 <h4>GoogleV1Engine.supportedLanguages</h4>
168 <b>supportedLanguages</b>(<i></i>) 213 <b>supportedLanguages</b>(<i></i>)
214
169 <p> 215 <p>
170 Public method to get the supported languages. 216 Public method to get the supported languages.
171 </p><dl> 217 </p>
218 <dl>
172 <dt>Returns:</dt> 219 <dt>Returns:</dt>
173 <dd> 220 <dd>
174 list of supported language codes (list of string) 221 list of supported language codes (list of string)
175 </dd> 222 </dd>
176 </dl> 223 </dl>

eric ide

mercurial