}
String uri = this.tree.getOntModel().expandPrefix(
":" + nextToken.term());
if (type.equals(OntologyElementTree.ONTCLASS)) {
OntClass cls = this.tree.getOntModel().getOntClass(uri);
ExtendedIterator it = cls.listSuperClasses();
while (it.hasNext()) {
offer(nextToken, ((OntClass) it.next()).getLocalName(),
tree.getActualWeight(Weights.ONTCLASS_SUPERCLASS));
}
it = cls.listSubClasses();
while (it.hasNext()) {
offer(nextToken, ((OntClass) it.next()).getLocalName(),
tree.getActualWeight(Weights.ONTCLASS_SUBCLASS));
}
for (DatatypeProperty dp : JenaUtil.getDatatypeProperties(cls,
false)) {
offer(
nextToken,
dp.getLocalName(),
tree
.getActualWeight(Weights.ONTCLASS_DECLARED_PROPERTY));
}
for (ObjectProperty op : JenaUtil.getObjectProperties(cls,
false)) {
offer(
nextToken,
op.getLocalName(),
tree
.getActualWeight(Weights.ONTCLASS_DECLARED_PROPERTY));
}
} else if (type.equals(OntologyElementTree.INDIVIDUAL)) {
Individual ind = this.tree.getOntModel().getIndividual(uri);
ExtendedIterator it = ind.listOntClasses(true);
while (it.hasNext()) {
OntClass cls = (OntClass) it.next();
offer(nextToken, cls.getLocalName(), tree
.getActualWeight(Weights.INDIVIDUAL_CLASS));
for (DatatypeProperty dp : JenaUtil.getDatatypeProperties(