public String getComment() { Node node = getNode(); if (node != null) { OntResource subject = node.getSubject(); if (subject != null) { OntResource defnode = subject.getIsDefinedBy(); if (defnode != null) { return node.toString() + " (" + ProfileModel.label(defnode) + ")"; } } return node.toString(); } else return "Nothing selected in outline"; }
public void doubleClick(DoubleClickEvent event) { IStructuredSelection selection = (IStructuredSelection) event.getSelection(); Node node = (Node) selection.getFirstElement(); OntResource subject = node.getSubject(); if (outline != null) outline.drillTo(subject); }
public OntResource getSubject() { Node node = getNode(); if (node != null) return node.getSubject(); else return null; }