use of org.jkiss.dbeaver.model.navigator.DBNProject in project dbeaver by serge-rider.
the class DatabaseBrowserView method getRootNode.
@Override
public DBNNode getRootNode() {
String secondaryId = getViewSite().getSecondaryId();
if (!CommonUtils.isEmpty(secondaryId)) {
try {
return getNodeFromSecondaryId(secondaryId);
} catch (DBException e) {
DBWorkbench.getPlatformUI().showError("Open database browser", "Can't find database navigator node", e);
}
}
DBNProject projectNode = getModel().getRoot().getProjectNode(DBWorkbench.getPlatform().getWorkspace().getActiveProject());
return projectNode == null ? new DBNEmptyNode() : projectNode.getDatabases();
}
Aggregations