233 |
tree.SetPyData(node, self) |
tree.SetPyData(node, self) |
234 |
|
|
235 |
class ConnectionNode(Node): |
class ConnectionNode(Node): |
236 |
|
|
237 |
|
# TODO: This method works with the datasource cleanup |
238 |
|
def __REWRITE__expand(self): |
239 |
|
self.expanded = 1 |
240 |
|
connection = self.navigator.connections.getConnection(self.connection, login=1) |
241 |
|
|
242 |
|
schemaTypes = connection.introspector.types[:] |
243 |
|
|
244 |
|
if not schemaTypes: |
245 |
|
return |
246 |
|
|
247 |
|
schemaTypes.sort() |
248 |
|
for schema, name, keep in schemaTypes: |
249 |
|
if keep: |
250 |
|
SchemaTypeNode(self.navigator, self.tree, self.node, |
251 |
|
introspector=connection.introspector, type=schema, name=name) |
252 |
|
|
253 |
|
return |
254 |
|
|
255 |
def expand(self): |
def expand(self): |
256 |
self.expanded = 1 |
self.expanded = 1 |
257 |
connections = self.navigator.connections |
connections = self.navigator.connections |
266 |
for schema, name, keep in schemaTypes: |
for schema, name, keep in schemaTypes: |
267 |
if keep: |
if keep: |
268 |
SchemaTypeNode(self.navigator, self.tree, self.node, |
SchemaTypeNode(self.navigator, self.tree, self.node, |
269 |
dataObject=dataObject, type=schema, name=name) |
introspector=dataObject, type=schema, name=name) |
270 |
|
|
271 |
return |
return |
272 |
|
|
289 |
def expand(self): |
def expand(self): |
290 |
self.expanded = 1 |
self.expanded = 1 |
291 |
tree = self.tree |
tree = self.tree |
292 |
schemas = self.dataObject.getSchemaList(self.type) |
schemas = self.introspector.getSchemaList(self.type) |
293 |
if not schemas: |
if not schemas: |
294 |
return |
return |
295 |
schemas.sort() |
schemas.sort() |