Documentation/Source/eric6.DebugClients.Python2.DebugVariables.html

changeset 5173
632257ad7337
child 5191
b7471cf89b07
equal deleted inserted replaced
5172:f35c7e0db572 5173:632257ad7337
1 <!DOCTYPE html>
2 <html><head>
3 <title>eric6.DebugClients.Python2.DebugVariables</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><a NAME="top" ID="top"></a>
22 <h1>eric6.DebugClients.Python2.DebugVariables</h1>
23 <p>
24 Module implementing classes and functions to dump variable contents.
25 </p>
26 <h3>Global Attributes</h3>
27 <table>
28 <tr><td>MaxItemsToHandle</td></tr><tr><td>TooLargeAttribute</td></tr><tr><td>TooLargeMessage</td></tr><tr><td>_TypeMap</td></tr><tr><td>defaultResolver</td></tr><tr><td>dictResolver</td></tr><tr><td>listResolver</td></tr><tr><td>setResolver</td></tr>
29 </table>
30 <h3>Classes</h3>
31 <table>
32 <tr>
33 <td><a href="#BaseResolver">BaseResolver</a></td>
34 <td>Base class of the resolver class tree.</td>
35 </tr><tr>
36 <td><a href="#DefaultResolver">DefaultResolver</a></td>
37 <td>Class used to resolve the default way.</td>
38 </tr><tr>
39 <td><a href="#DictResolver">DictResolver</a></td>
40 <td>Class used to resolve from a dictionary.</td>
41 </tr><tr>
42 <td><a href="#ListResolver">ListResolver</a></td>
43 <td>Class used to resolve from a tuple or list.</td>
44 </tr><tr>
45 <td><a href="#SetResolver">SetResolver</a></td>
46 <td>Class used to resolve from a set or frozenset.</td>
47 </tr>
48 </table>
49 <h3>Functions</h3>
50 <table>
51 <tr>
52 <td><a href="#_initTypeMap">_initTypeMap</a></td>
53 <td>Protected function to initialize the type map.</td>
54 </tr><tr>
55 <td><a href="#getType">getType</a></td>
56 <td>Public method to get the type information for an object.</td>
57 </tr>
58 </table>
59 <hr /><hr />
60 <a NAME="BaseResolver" ID="BaseResolver"></a>
61 <h2>BaseResolver</h2>
62 <p>
63 Base class of the resolver class tree.
64 </p>
65 <h3>Derived from</h3>
66 object
67 <h3>Class Attributes</h3>
68 <table>
69 <tr><td>None</td></tr>
70 </table>
71 <h3>Class Methods</h3>
72 <table>
73 <tr><td>None</td></tr>
74 </table>
75 <h3>Methods</h3>
76 <table>
77 <tr>
78 <td><a href="#BaseResolver.getDictionary">getDictionary</a></td>
79 <td>Public method to get the attributes of a variable as a dictionary.</td>
80 </tr><tr>
81 <td><a href="#BaseResolver.resolve">resolve</a></td>
82 <td>Public method to get an attribute from a variable.</td>
83 </tr>
84 </table>
85 <h3>Static Methods</h3>
86 <table>
87 <tr><td>None</td></tr>
88 </table>
89 <a NAME="BaseResolver.getDictionary" ID="BaseResolver.getDictionary"></a>
90 <h4>BaseResolver.getDictionary</h4>
91 <b>getDictionary</b>(<i>var</i>)
92 <p>
93 Public method to get the attributes of a variable as a dictionary.
94 </p><dl>
95 <dt><i>var</i> (any)</dt>
96 <dd>
97 variable to be converted
98 </dd>
99 </dl><dl>
100 <dt>Returns:</dt>
101 <dd>
102 dictionary containing the variable attributes
103 </dd>
104 </dl><dl>
105 <dt>Return Type:</dt>
106 <dd>
107 dict
108 </dd>
109 </dl><dl>
110 <dt>Raises <b>NotImplementedError</b>:</dt>
111 <dd>
112 raised to indicate a missing
113 implementation
114 </dd>
115 </dl><a NAME="BaseResolver.resolve" ID="BaseResolver.resolve"></a>
116 <h4>BaseResolver.resolve</h4>
117 <b>resolve</b>(<i>var, attribute</i>)
118 <p>
119 Public method to get an attribute from a variable.
120 </p><dl>
121 <dt><i>var</i> (any)</dt>
122 <dd>
123 variable to extract an attribute or value from
124 </dd><dt><i>attribute</i> (str)</dt>
125 <dd>
126 name of the attribute to extract
127 </dd>
128 </dl><dl>
129 <dt>Returns:</dt>
130 <dd>
131 value of the attribute
132 </dd>
133 </dl><dl>
134 <dt>Return Type:</dt>
135 <dd>
136 any
137 </dd>
138 </dl><dl>
139 <dt>Raises <b>NotImplementedError</b>:</dt>
140 <dd>
141 raised to indicate a missing
142 implementation
143 </dd>
144 </dl>
145 <div align="right"><a href="#top">Up</a></div>
146 <hr /><hr />
147 <a NAME="DefaultResolver" ID="DefaultResolver"></a>
148 <h2>DefaultResolver</h2>
149 <p>
150 Class used to resolve the default way.
151 </p>
152 <h3>Derived from</h3>
153 BaseResolver
154 <h3>Class Attributes</h3>
155 <table>
156 <tr><td>None</td></tr>
157 </table>
158 <h3>Class Methods</h3>
159 <table>
160 <tr><td>None</td></tr>
161 </table>
162 <h3>Methods</h3>
163 <table>
164 <tr>
165 <td><a href="#DefaultResolver.getDictionary">getDictionary</a></td>
166 <td>Public method to get the attributes of a variable as a dictionary.</td>
167 </tr><tr>
168 <td><a href="#DefaultResolver.resolve">resolve</a></td>
169 <td>Public method to get an attribute from a variable.</td>
170 </tr>
171 </table>
172 <h3>Static Methods</h3>
173 <table>
174 <tr><td>None</td></tr>
175 </table>
176 <a NAME="DefaultResolver.getDictionary" ID="DefaultResolver.getDictionary"></a>
177 <h4>DefaultResolver.getDictionary</h4>
178 <b>getDictionary</b>(<i>var</i>)
179 <p>
180 Public method to get the attributes of a variable as a dictionary.
181 </p><dl>
182 <dt><i>var</i> (any)</dt>
183 <dd>
184 variable to be converted
185 </dd>
186 </dl><dl>
187 <dt>Returns:</dt>
188 <dd>
189 dictionary containing the variable attributes
190 </dd>
191 </dl><dl>
192 <dt>Return Type:</dt>
193 <dd>
194 dict
195 </dd>
196 </dl><a NAME="DefaultResolver.resolve" ID="DefaultResolver.resolve"></a>
197 <h4>DefaultResolver.resolve</h4>
198 <b>resolve</b>(<i>var, attribute</i>)
199 <p>
200 Public method to get an attribute from a variable.
201 </p><dl>
202 <dt><i>var</i> (any)</dt>
203 <dd>
204 variable to extract an attribute or value from
205 </dd><dt><i>attribute</i> (str)</dt>
206 <dd>
207 name of the attribute to extract
208 </dd>
209 </dl><dl>
210 <dt>Returns:</dt>
211 <dd>
212 value of the attribute
213 </dd>
214 </dl><dl>
215 <dt>Return Type:</dt>
216 <dd>
217 any
218 </dd>
219 </dl>
220 <div align="right"><a href="#top">Up</a></div>
221 <hr /><hr />
222 <a NAME="DictResolver" ID="DictResolver"></a>
223 <h2>DictResolver</h2>
224 <p>
225 Class used to resolve from a dictionary.
226 </p>
227 <h3>Derived from</h3>
228 BaseResolver
229 <h3>Class Attributes</h3>
230 <table>
231 <tr><td>None</td></tr>
232 </table>
233 <h3>Class Methods</h3>
234 <table>
235 <tr><td>None</td></tr>
236 </table>
237 <h3>Methods</h3>
238 <table>
239 <tr>
240 <td><a href="#DictResolver.__keyToStr">__keyToStr</a></td>
241 <td>Private method to get a string representation for a key.</td>
242 </tr><tr>
243 <td><a href="#DictResolver.getDictionary">getDictionary</a></td>
244 <td>Public method to get the attributes of a variable as a dictionary.</td>
245 </tr><tr>
246 <td><a href="#DictResolver.resolve">resolve</a></td>
247 <td>Public method to get an attribute from a variable.</td>
248 </tr>
249 </table>
250 <h3>Static Methods</h3>
251 <table>
252 <tr><td>None</td></tr>
253 </table>
254 <a NAME="DictResolver.__keyToStr" ID="DictResolver.__keyToStr"></a>
255 <h4>DictResolver.__keyToStr</h4>
256 <b>__keyToStr</b>(<i>key</i>)
257 <p>
258 Private method to get a string representation for a key.
259 </p><dl>
260 <dt><i>key</i> (any)</dt>
261 <dd>
262 key to be converted
263 </dd>
264 </dl><dl>
265 <dt>Returns:</dt>
266 <dd>
267 string representation of the given key
268 </dd>
269 </dl><dl>
270 <dt>Return Type:</dt>
271 <dd>
272 str
273 </dd>
274 </dl><a NAME="DictResolver.getDictionary" ID="DictResolver.getDictionary"></a>
275 <h4>DictResolver.getDictionary</h4>
276 <b>getDictionary</b>(<i>var</i>)
277 <p>
278 Public method to get the attributes of a variable as a dictionary.
279 </p><dl>
280 <dt><i>var</i> (any)</dt>
281 <dd>
282 variable to be converted
283 </dd>
284 </dl><dl>
285 <dt>Returns:</dt>
286 <dd>
287 dictionary containing the variable attributes
288 </dd>
289 </dl><dl>
290 <dt>Return Type:</dt>
291 <dd>
292 dict
293 </dd>
294 </dl><a NAME="DictResolver.resolve" ID="DictResolver.resolve"></a>
295 <h4>DictResolver.resolve</h4>
296 <b>resolve</b>(<i>var, attribute</i>)
297 <p>
298 Public method to get an attribute from a variable.
299 </p><dl>
300 <dt><i>var</i> (dict)</dt>
301 <dd>
302 variable to extract an attribute or value from
303 </dd><dt><i>attribute</i> (str)</dt>
304 <dd>
305 name of the attribute to extract
306 </dd>
307 </dl><dl>
308 <dt>Returns:</dt>
309 <dd>
310 value of the attribute
311 </dd>
312 </dl><dl>
313 <dt>Return Type:</dt>
314 <dd>
315 any
316 </dd>
317 </dl>
318 <div align="right"><a href="#top">Up</a></div>
319 <hr /><hr />
320 <a NAME="ListResolver" ID="ListResolver"></a>
321 <h2>ListResolver</h2>
322 <p>
323 Class used to resolve from a tuple or list.
324 </p>
325 <h3>Derived from</h3>
326 BaseResolver
327 <h3>Class Attributes</h3>
328 <table>
329 <tr><td>None</td></tr>
330 </table>
331 <h3>Class Methods</h3>
332 <table>
333 <tr><td>None</td></tr>
334 </table>
335 <h3>Methods</h3>
336 <table>
337 <tr>
338 <td><a href="#ListResolver.getDictionary">getDictionary</a></td>
339 <td>Public method to get the attributes of a variable as a dictionary.</td>
340 </tr><tr>
341 <td><a href="#ListResolver.resolve">resolve</a></td>
342 <td>Public method to get an attribute from a variable.</td>
343 </tr>
344 </table>
345 <h3>Static Methods</h3>
346 <table>
347 <tr><td>None</td></tr>
348 </table>
349 <a NAME="ListResolver.getDictionary" ID="ListResolver.getDictionary"></a>
350 <h4>ListResolver.getDictionary</h4>
351 <b>getDictionary</b>(<i>var</i>)
352 <p>
353 Public method to get the attributes of a variable as a dictionary.
354 </p><dl>
355 <dt><i>var</i> (any)</dt>
356 <dd>
357 variable to be converted
358 </dd>
359 </dl><dl>
360 <dt>Returns:</dt>
361 <dd>
362 dictionary containing the variable attributes
363 </dd>
364 </dl><dl>
365 <dt>Return Type:</dt>
366 <dd>
367 dict
368 </dd>
369 </dl><a NAME="ListResolver.resolve" ID="ListResolver.resolve"></a>
370 <h4>ListResolver.resolve</h4>
371 <b>resolve</b>(<i>var, attribute</i>)
372 <p>
373 Public method to get an attribute from a variable.
374 </p><dl>
375 <dt><i>var</i> (tuple or list)</dt>
376 <dd>
377 variable to extract an attribute or value from
378 </dd><dt><i>attribute</i> (str)</dt>
379 <dd>
380 name of the attribute to extract
381 </dd>
382 </dl><dl>
383 <dt>Returns:</dt>
384 <dd>
385 value of the attribute
386 </dd>
387 </dl><dl>
388 <dt>Return Type:</dt>
389 <dd>
390 any
391 </dd>
392 </dl>
393 <div align="right"><a href="#top">Up</a></div>
394 <hr /><hr />
395 <a NAME="SetResolver" ID="SetResolver"></a>
396 <h2>SetResolver</h2>
397 <p>
398 Class used to resolve from a set or frozenset.
399 </p>
400 <h3>Derived from</h3>
401 BaseResolver
402 <h3>Class Attributes</h3>
403 <table>
404 <tr><td>None</td></tr>
405 </table>
406 <h3>Class Methods</h3>
407 <table>
408 <tr><td>None</td></tr>
409 </table>
410 <h3>Methods</h3>
411 <table>
412 <tr>
413 <td><a href="#SetResolver.getDictionary">getDictionary</a></td>
414 <td>Public method to get the attributes of a variable as a dictionary.</td>
415 </tr><tr>
416 <td><a href="#SetResolver.resolve">resolve</a></td>
417 <td>Public method to get an attribute from a variable.</td>
418 </tr>
419 </table>
420 <h3>Static Methods</h3>
421 <table>
422 <tr><td>None</td></tr>
423 </table>
424 <a NAME="SetResolver.getDictionary" ID="SetResolver.getDictionary"></a>
425 <h4>SetResolver.getDictionary</h4>
426 <b>getDictionary</b>(<i>var</i>)
427 <p>
428 Public method to get the attributes of a variable as a dictionary.
429 </p><dl>
430 <dt><i>var</i> (any)</dt>
431 <dd>
432 variable to be converted
433 </dd>
434 </dl><dl>
435 <dt>Returns:</dt>
436 <dd>
437 dictionary containing the variable attributes
438 </dd>
439 </dl><dl>
440 <dt>Return Type:</dt>
441 <dd>
442 dict
443 </dd>
444 </dl><a NAME="SetResolver.resolve" ID="SetResolver.resolve"></a>
445 <h4>SetResolver.resolve</h4>
446 <b>resolve</b>(<i>var, attribute</i>)
447 <p>
448 Public method to get an attribute from a variable.
449 </p><dl>
450 <dt><i>var</i> (tuple or list)</dt>
451 <dd>
452 variable to extract an attribute or value from
453 </dd><dt><i>attribute</i> (str)</dt>
454 <dd>
455 id of the value to extract
456 </dd>
457 </dl><dl>
458 <dt>Returns:</dt>
459 <dd>
460 value of the attribute
461 </dd>
462 </dl><dl>
463 <dt>Return Type:</dt>
464 <dd>
465 any
466 </dd>
467 </dl>
468 <div align="right"><a href="#top">Up</a></div>
469 <hr /><hr />
470 <a NAME="_initTypeMap" ID="_initTypeMap"></a>
471 <h2>_initTypeMap</h2>
472 <b>_initTypeMap</b>(<i></i>)
473 <p>
474 Protected function to initialize the type map.
475 </p>
476 <div align="right"><a href="#top">Up</a></div>
477 <hr /><hr />
478 <a NAME="getType" ID="getType"></a>
479 <h2>getType</h2>
480 <b>getType</b>(<i>obj</i>)
481 <p>
482 Public method to get the type information for an object.
483 </p><dl>
484 <dt><i>obj</i> (any)</dt>
485 <dd>
486 object to get type information for
487 </dd>
488 </dl><dl>
489 <dt>Returns:</dt>
490 <dd>
491 tuple containing the type, type name, type string and resolver
492 </dd>
493 </dl><dl>
494 <dt>Return Type:</dt>
495 <dd>
496 tuple of type, str, str, BaseResolver
497 </dd>
498 </dl>
499 <div align="right"><a href="#top">Up</a></div>
500 <hr />
501 </body></html>

eric ide

mercurial