public IProperty retrieveProperty(SemanticType t) { IProperty ret = null; IOntology o = knowledgeRepository.retrieveOntology(t.getConceptSpace()); if (o != null) ret = o.getProperty(t.getLocalName()); return ret; }
/* (non-Javadoc) * @see org.integratedmodelling.thinklab.IKnowledgeBase#getPropertyFromURI(java.lang.String) */ public IProperty getPropertyFromURI(String uri) { IProperty ret = null; String[] ss = uri.split("#"); if (ss.length != 2) return ret; IOntology o = null; try { String csp = getConceptSpaceFromURI(ss[0] + "#"); if (csp == null) return ret; o = knowledgeRepository.retrieveOntology(csp); if (o != null) ret = o.getProperty(ss[1]); } catch (ThinklabResourceNotFoundException e) { } return ret; }