}
}
protected void find() {
FindKeyDialog dialog = new FindKeyDialog(shell, iconImage);
FindInfo info = (FindInfo) dialog.open();
if (info != null) {
TreeItem treeItem;
ContainerKeyInfo cinfo = new ContainerKeyInfo();
if (itemsSelected[0] instanceof TreeItem) {
treeItem = (TreeItem) itemsSelected[0];
} else {
treeItem = getTreeItemByTableItem((TableItem) itemsSelected[0]);
}
parseContainer(treeItem, cinfo);
NodeType searchFrom = (NodeType) treeItem.getData(NODE_TYPE);
Set<Node> nodes = service2.find(searchFrom, cinfo.getId(),
cinfo.getDb(), cinfo.getContainerStr(),
info.getSearchNodeType(), info.getPattern(),
info.isForward());
if (!nodes.isEmpty()) {
Node node = nodes.iterator().next();
TreeItem selected = gotoDBContainer(node.getId(), node.getDb(),
node.getKey(), true, true);
history.add(selected);
btnBackward.setEnabled(true);
btnForward.setEnabled(false);
fBuffer = new FindBuffer(node, searchFrom, cinfo.getId(),
cinfo.getDb(), cinfo.getContainerStr(),
info.getSearchNodeType(), info.getPattern());
} else {
MessageDialog.openInformation(shell,
i18nFile.getText(I18nFile.FINDRESULTS),
i18nFile.getText(I18nFile.NOFOUND));
}