Search in sources :

Example 1 with Simulation

use of org.jlibsedml.Simulation in project vcell by virtualcell.

the class KisaoIDValidator method validate.

/**
 * Validates the syntax of the KiSAO identifier for uniform time course descriptions.
 * @see org.jlibsedml.validation.ISedMLValidator#validate()
 */
public List<SedMLError> validate() {
    List<SedMLError> errs = new ArrayList<SedMLError>();
    for (Simulation sim : sims) {
        String kisaoID = sim.getAlgorithm().getKisaoID();
        if (KisaoOntology.getInstance().getTermById(kisaoID) == null) {
            int line = getLineNumberOfError(SEDMLTags.SIMUL_UTC_KIND, sim);
            errs.add(new SedMLError(line, " The supplied KisaoID [" + kisaoID + "] for simulation [" + sim.getId() + "]  is not a recognized KISAO identifier.\n" + " Identifiers should be the format 'KISAO:0000001' ", SedMLError.ERROR_SEVERITY.WARNING));
        }
    }
    return errs;
}
Also used : SedMLError(org.jlibsedml.SedMLError) Simulation(org.jlibsedml.Simulation) ArrayList(java.util.ArrayList)

Aggregations

ArrayList (java.util.ArrayList)1 SedMLError (org.jlibsedml.SedMLError)1 Simulation (org.jlibsedml.Simulation)1