|
1 <?xml version="1.0" encoding="utf-8"?> |
|
2 <!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' |
|
3 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'> |
|
4 <html><head> |
|
5 <title>eric5.SqlBrowser.SqlConnectionWidget</title> |
|
6 <style> |
|
7 b'body {\n background:white;\n margin: 0em 1em 10em 1em;\n color: black;\n}\n\nh1 { color: white; background: #4FA4FF; }\nh2 { color: white; background: #4FA4FF; }\nh3 { color: white; background: #00557F; }\nh4 { color: white; background: #00557F; }\n \na { color: #AA5500; }\n' |
|
8 </style> |
|
9 </head> |
|
10 <body><a NAME="top" ID="top"></a> |
|
11 <h1>eric5.SqlBrowser.SqlConnectionWidget</h1> |
|
12 <p> |
|
13 Module implementing a widget showing the SQL connections. |
|
14 </p> |
|
15 <h3>Global Attributes</h3> |
|
16 <table> |
|
17 <tr><td>None</td></tr> |
|
18 </table> |
|
19 <h3>Classes</h3> |
|
20 <table> |
|
21 <tr> |
|
22 <td><a href="#SqlConnectionWidget">SqlConnectionWidget</a></td> |
|
23 <td>Class implementing a widget showing the SQL connections.</td> |
|
24 </tr> |
|
25 </table> |
|
26 <h3>Functions</h3> |
|
27 <table> |
|
28 <tr><td>None</td></tr> |
|
29 </table> |
|
30 <hr /><hr /> |
|
31 <a NAME="SqlConnectionWidget" ID="SqlConnectionWidget"></a> |
|
32 <h2>SqlConnectionWidget</h2> |
|
33 <p> |
|
34 Class implementing a widget showing the SQL connections. |
|
35 </p><h4>Signals</h4> |
|
36 <dl> |
|
37 <dt>cleared()</dt> |
|
38 <dd> |
|
39 emitted after the connection tree has been cleared |
|
40 </dd><dt>schemaRequested(QString)</dt> |
|
41 <dd> |
|
42 emitted when the schema display is requested |
|
43 </dd><dt>tableActivated(QString)</dt> |
|
44 <dd> |
|
45 emitted after the entry for a table has been activated |
|
46 </dd> |
|
47 </dl> |
|
48 <h3>Derived from</h3> |
|
49 QWidget |
|
50 <h3>Class Attributes</h3> |
|
51 <table> |
|
52 <tr><td>None</td></tr> |
|
53 </table> |
|
54 <h3>Methods</h3> |
|
55 <table> |
|
56 <tr> |
|
57 <td><a href="#SqlConnectionWidget.__init__">SqlConnectionWidget</a></td> |
|
58 <td>Constructor</td> |
|
59 </tr><tr> |
|
60 <td><a href="#SqlConnectionWidget.__currentItemChanged">__currentItemChanged</a></td> |
|
61 <td>Private slot handling a change of the current item.</td> |
|
62 </tr><tr> |
|
63 <td><a href="#SqlConnectionWidget.__dbCaption">__dbCaption</a></td> |
|
64 <td>Private method to assemble a string for the caption.</td> |
|
65 </tr><tr> |
|
66 <td><a href="#SqlConnectionWidget.__itemActivated">__itemActivated</a></td> |
|
67 <td>Private slot handling the activation of an item.</td> |
|
68 </tr><tr> |
|
69 <td><a href="#SqlConnectionWidget.__setActive">__setActive</a></td> |
|
70 <td>Private slot to set an item to active.</td> |
|
71 </tr><tr> |
|
72 <td><a href="#SqlConnectionWidget.__setBold">__setBold</a></td> |
|
73 <td>Private slot to set the font to bold.</td> |
|
74 </tr><tr> |
|
75 <td><a href="#SqlConnectionWidget.currentDatabase">currentDatabase</a></td> |
|
76 <td>Public method to get the current database.</td> |
|
77 </tr><tr> |
|
78 <td><a href="#SqlConnectionWidget.refresh">refresh</a></td> |
|
79 <td>Public slot to refresh the connection tree.</td> |
|
80 </tr><tr> |
|
81 <td><a href="#SqlConnectionWidget.showSchema">showSchema</a></td> |
|
82 <td>Public slot to show schema data of a database.</td> |
|
83 </tr> |
|
84 </table> |
|
85 <a NAME="SqlConnectionWidget.__init__" ID="SqlConnectionWidget.__init__"></a> |
|
86 <h4>SqlConnectionWidget (Constructor)</h4> |
|
87 <b>SqlConnectionWidget</b>(<i>parent = None</i>) |
|
88 <p> |
|
89 Constructor |
|
90 </p><dl> |
|
91 <dt><i>parent</i></dt> |
|
92 <dd> |
|
93 reference to the parent widget (QWidget) |
|
94 </dd> |
|
95 </dl><a NAME="SqlConnectionWidget.__currentItemChanged" ID="SqlConnectionWidget.__currentItemChanged"></a> |
|
96 <h4>SqlConnectionWidget.__currentItemChanged</h4> |
|
97 <b>__currentItemChanged</b>(<i>current, previous</i>) |
|
98 <p> |
|
99 Private slot handling a change of the current item. |
|
100 </p><dl> |
|
101 <dt><i>current</i></dt> |
|
102 <dd> |
|
103 reference to the new current item (QTreeWidgetItem) |
|
104 </dd><dt><i>previous</i></dt> |
|
105 <dd> |
|
106 reference to the previous current item (QTreeWidgetItem) |
|
107 </dd> |
|
108 </dl><a NAME="SqlConnectionWidget.__dbCaption" ID="SqlConnectionWidget.__dbCaption"></a> |
|
109 <h4>SqlConnectionWidget.__dbCaption</h4> |
|
110 <b>__dbCaption</b>(<i>db</i>) |
|
111 <p> |
|
112 Private method to assemble a string for the caption. |
|
113 </p><dl> |
|
114 <dt><i>db</i></dt> |
|
115 <dd> |
|
116 reference to the database object (QSqlDatabase) |
|
117 </dd> |
|
118 </dl><dl> |
|
119 <dt>Returns:</dt> |
|
120 <dd> |
|
121 caption string (string) |
|
122 </dd> |
|
123 </dl><a NAME="SqlConnectionWidget.__itemActivated" ID="SqlConnectionWidget.__itemActivated"></a> |
|
124 <h4>SqlConnectionWidget.__itemActivated</h4> |
|
125 <b>__itemActivated</b>(<i>itm, column</i>) |
|
126 <p> |
|
127 Private slot handling the activation of an item. |
|
128 </p><dl> |
|
129 <dt><i>itm</i></dt> |
|
130 <dd> |
|
131 reference to the item (QTreeWidgetItem) |
|
132 </dd><dt><i>column</i></dt> |
|
133 <dd> |
|
134 column that was activated (integer) |
|
135 </dd> |
|
136 </dl><a NAME="SqlConnectionWidget.__setActive" ID="SqlConnectionWidget.__setActive"></a> |
|
137 <h4>SqlConnectionWidget.__setActive</h4> |
|
138 <b>__setActive</b>(<i>itm</i>) |
|
139 <p> |
|
140 Private slot to set an item to active. |
|
141 </p><dl> |
|
142 <dt><i>itm</i></dt> |
|
143 <dd> |
|
144 reference to the item to set as the active item (QTreeWidgetItem) |
|
145 </dd> |
|
146 </dl><a NAME="SqlConnectionWidget.__setBold" ID="SqlConnectionWidget.__setBold"></a> |
|
147 <h4>SqlConnectionWidget.__setBold</h4> |
|
148 <b>__setBold</b>(<i>itm, bold</i>) |
|
149 <p> |
|
150 Private slot to set the font to bold. |
|
151 </p><dl> |
|
152 <dt><i>itm</i></dt> |
|
153 <dd> |
|
154 reference to the item to be changed (QTreeWidgetItem) |
|
155 </dd><dt><i>bold</i></dt> |
|
156 <dd> |
|
157 flag indicating bold (boolean) |
|
158 </dd> |
|
159 </dl><a NAME="SqlConnectionWidget.currentDatabase" ID="SqlConnectionWidget.currentDatabase"></a> |
|
160 <h4>SqlConnectionWidget.currentDatabase</h4> |
|
161 <b>currentDatabase</b>(<i></i>) |
|
162 <p> |
|
163 Public method to get the current database. |
|
164 </p><dl> |
|
165 <dt>Returns:</dt> |
|
166 <dd> |
|
167 reference to the current database (QSqlDatabase) |
|
168 </dd> |
|
169 </dl><a NAME="SqlConnectionWidget.refresh" ID="SqlConnectionWidget.refresh"></a> |
|
170 <h4>SqlConnectionWidget.refresh</h4> |
|
171 <b>refresh</b>(<i></i>) |
|
172 <p> |
|
173 Public slot to refresh the connection tree. |
|
174 </p><a NAME="SqlConnectionWidget.showSchema" ID="SqlConnectionWidget.showSchema"></a> |
|
175 <h4>SqlConnectionWidget.showSchema</h4> |
|
176 <b>showSchema</b>(<i></i>) |
|
177 <p> |
|
178 Public slot to show schema data of a database. |
|
179 </p> |
|
180 <div align="right"><a href="#top">Up</a></div> |
|
181 <hr /> |
|
182 </body></html> |