OWLGraphWrapperEdgesAdvanced extends OWLGraphWrapperEdgesExtended implements Closeable { public Set<String> getOnlyInTaxon(OWLObject x, List<String> sargs) { Set<OWLClass> classes = getOnlyInTaxonSvfClasses(x); if (classes.isEmpty() == false) { Set<String> ids = new HashSet<String>(); for(OWLClass cls : classes) { ids.add(getIdentifier(cls)); } return ids; } return Collections.emptySet(); } protected  OWLGraphWrapperEdgesAdvanced(OWLOntology ontology); protected  OWLGraphWrapperEdgesAdvanced(String iri); void setEdgesAdvancedCacheSize(int size); long getCurrentEdgesAdvancedCacheSize(); synchronized void addPropertyForMaterialization(OWLObjectProperty p); synchronized void addPropertiesForMaterialization(Iterable<OWLObjectProperty> properties); synchronized void addPropertyIdsForMaterialization(Iterable<String> propertyIds); @Override synchronized void close(); Set<OWLObjectProperty> relationshipIDsToPropertySet(List<String> relation_ids); String classifyRelationship(OWLGraphEdge owlGraphEdge, OWLObject edgeDirector, Set<? extends OWLPropertyExpression> props); OWLShuntGraph addStepwiseAncestorsToShuntGraph(OWLObject x, OWLShuntGraph g, List<String> rel_ids); OWLShuntGraph addTransitiveAncestorsToShuntGraph(OWLObject x, OWLShuntGraph g, List<String> rel_ids); OWLShuntGraph addDirectDescendentsToShuntGraph(OWLObject x, OWLShuntGraph g, List<String> rel_ids); OWLShuntGraph getSegmentShuntGraph(OWLObject x, List<String> rel_ids); OWLShuntGraph getLineageShuntGraph(OWLObject x, List<String> rel_ids); String getSegmentShuntGraphJSON(OWLObject x, List<String> sargs); String getLineageShuntGraphJSON(OWLObject x, List<String> sargs); Map<String,String> getRelationClosureMap(OWLObject c, final List<String> relation_ids); Map<String,String> getRelationClosureMapEngine(OWLObject obj, List<String> relation_ids); @Deprecated Map<String,String> getIsaPartofClosureMap(OWLObject c); @Deprecated List<String> getIsaPartofIDClosure(OWLObject c); @Deprecated List<String> getIsaPartofIDClosure(OWLObject c, List<String> sargs); List<String> getRelationIDClosure(OWLObject c, List<String> relation_ids); @Deprecated List<String> getIsaPartofLabelClosure(OWLObject c); @Deprecated List<String> getIsaPartofLabelClosure(OWLObject c, List<String> sargs); List<String> getRelationLabelClosure(OWLObject c, List<String> relation_ids); @Deprecated String[] getSubClassesNames(OWLClass cls); String categorizeNamespace(OWLObject c, Map<String, Object> configuration); String categorizeObject(OWLNamedObject named,  Map<String,String> idspaceMappings, 
			Set<String> useNamespace, boolean useFallback); String getDummyString(OWLObject c, List<String> sargs); List<String> getDummyStrings(OWLObject c, List<String> sargs); Set<String> getOnlyInTaxon(OWLObject x, List<String> sargs); Set<String> getOnlyInTaxonLabels(OWLObject x, List<String> sargs); Map<String, String> getOnlyInTaxonLabelMap(OWLObject x, List<String> sargs); Set<String> getOnlyInTaxonClosure(OWLObject x, List<String> relation_ids); Set<String> getOnlyInTaxonClosureLabels(OWLObject x, List<String> relation_ids); OWLShuntGraph getNeighbors(OWLObject x, List<String> sargs); String getNeighborsJSON(OWLObject x, List<String> sargs); String getNeighborsLimitedJSON(OWLObject x, List<String> sargs); OWLShuntGraph getNeighborsLimited(OWLObject x, int edgeLimit); OWLShuntGraph getNeighbors(OWLObject x);  }
@Test public void testGetOnlyInTaxon() throws Exception { OWLGraphWrapper graph = getGraph("graph/explainConstraints.owl"); OWLClass c1 = graph.getOWLClass(IRI.create("http: Set<String> taxon1 = graph.getOnlyInTaxon(c1, Collections.<String>emptyList()); assertEquals(1, taxon1.size()); assertEquals("NCBITaxon:1", taxon1.iterator().next()); OWLClass c2 = graph.getOWLClass(IRI.create("http: Set<String> taxon2 = graph.getOnlyInTaxon(c2, Collections.<String>emptyList()); assertEquals(1, taxon2.size()); assertEquals("NCBITaxon:2", taxon2.iterator().next()); Set<String> closure = graph.getOnlyInTaxonClosure(c2, Collections.<String>emptyList()); assertEquals(2, closure.size()); assertTrue(closure.contains("NCBITaxon:1")); assertTrue(closure.contains("NCBITaxon:2")); OWLClass c3 = graph.getOWLClass(IRI.create("http: Set<String> taxon3 = graph.getOnlyInTaxon(c3, Collections.<String>emptyList()); assertEquals(0, taxon3.size()); }