/** * @param pid * @param annotation * @param description * @param elementOf * @param ofType * @param evidence * @return * @see net.sourceforge.ondex.core.ONDEXGraph#createConcept(java.lang.String, * java.lang.String, java.lang.String, * net.sourceforge.ondex.core.DataSource, * net.sourceforge.ondex.core.ConceptClass, java.util.Collection) */ public ONDEXConcept createConcept(String pid, String annotation, String description, DataSource elementOf, ConceptClass ofType, Collection<EvidenceType> evidence) { return og.createConcept(pid, annotation, description, elementOf, ofType, evidence); }
/** * Creates a new ONDEXConcept with the given pid, DataSource and * ConceptClass. Adds the new ONDEXConcept to the list of Concepts of this * graph and returns it. * * @param pid * PARSER ID of the new ONDEXConcept * @param elementOf * DataSource of the new ONDEXConcept * @param ofType * ConceptClass of the new ONDEXConcept * @param evidence * evidence types * @return new ONDEXConcept * @throws NullValueException * if any parameter is null. * @throws UnsupportedOperationException * for read-only graphs */ public ONDEXConcept createConcept(String id, DataSource elementOf, ConceptClass ofType, Collection<EvidenceType> evidence) throws NullValueException, UnsupportedOperationException { return g.createConcept(id, "", "", elementOf, ofType, evidence); }
/** * Creates a new ONDEXConcept with the given pid, annotation, DataSource and * ConceptClass. Adds the new ONDEXConcept to the list of Concepts of this * graph and returns it. * * @param pid * PARSER ID of the new ONDEXConcept * @param annotation * relevant annotation of the new ONDEXConcept * @param elementOf * DataSource of the new ONDEXConcept * @param ofType * ConceptClass of the new ONDEXConcept * @param evidence * evidence types * @return new ONDEXConcept * @throws NullValueException * if any parameter is null. * @throws UnsupportedOperationException * for read-only graphs */ public ONDEXConcept createConcept(String id, String annotation, DataSource elementOf, ConceptClass ofType, Collection<EvidenceType> evidence) throws NullValueException, UnsupportedOperationException { return g.createConcept(id, annotation, "", elementOf, ofType, evidence); }
List<EvidenceType> v = new ArrayList<EvidenceType>(); v.add(evidencetype); return g.createConcept(id, "", "", elementOf, ofType, v);
List<EvidenceType> v = new ArrayList<EvidenceType>(); v.add(evidencetype); return g.createConcept(id, annotation, "", elementOf, ofType, v);
List<EvidenceType> v = new ArrayList<EvidenceType>(); v.add(evidencetype); return g.createConcept(id, annotation, description, elementOf, ofType, v);
ONDEXConcept c = og.createConcept(pid, annotation, description, dataSource, cc, evidences); idMapping.put(id, c.getId());
/** * Clone concept with having a new DataSource. * * @param oldC * old ONDEXConcept * @param newDataSource * new DataSource to use * @return new ONDEXConcept */ public ONDEXConcept clone(ONDEXConcept oldC, DataSource newDataSource) { // first clone concept with new DataSource ONDEXConcept newC = graph.createConcept(oldC.getPID(), oldC.getAnnotation(), oldC.getDescription(), newDataSource, oldC.getOfType(), oldC.getEvidence()); // copies everything else copyEverythingElse(oldC, newC); return newC; }
/** * Clone concept with having a new PID. * * @param oldC * old ONDEXConcept * @param newPID * new PID to use * @return new ONDEXConcept */ public ONDEXConcept clone(ONDEXConcept oldC, String newPID) { // first clone concept with new PID ONDEXConcept newC = graph.createConcept(newPID, oldC.getAnnotation(), oldC.getDescription(), oldC.getElementOf(), oldC.getOfType(), oldC.getEvidence()); // copies everything else copyEverythingElse(oldC, newC); return newC; }
/** * Clone concept with having a new ConceptClass. * * @param oldC * old ONDEXConcept * @param newCC * new ConceptClass to use * @return new ONDEXConcept */ public ONDEXConcept clone(ONDEXConcept oldC, ConceptClass newCC) { // first clone concept with new ConceptClass ONDEXConcept newC = graph.createConcept(oldC.getPID(), oldC.getAnnotation(), oldC.getDescription(), oldC.getElementOf(), newCC, oldC.getEvidence()); // copies everything else copyEverythingElse(oldC, newC); return newC; }
ONDEXConcept conceptContext = graph.createConcept("Clique", "Clique of " + nodesInClique + " nodes", "", dataSource, clique_cc, evidences);
ONDEXConcept newConcept = graph.createConcept( toString(sortedPIDsConcat), toString(annotations), toString(descriptions), newDataSource, newConceptClass,
ConceptClass newCC = nomd.getConceptClass(cc.getId()); ONDEXConcept newConcept = newGraph.createConcept(pid, anno, desc, newDataSource, newCC, ets);