diff --git a/src/main/java/org/lemsml/jlems/core/type/dynamics/Dynamics.java b/src/main/java/org/lemsml/jlems/core/type/dynamics/Dynamics.java index 61fb70f..a44b5fa 100644 --- a/src/main/java/org/lemsml/jlems/core/type/dynamics/Dynamics.java +++ b/src/main/java/org/lemsml/jlems/core/type/dynamics/Dynamics.java @@ -20,6 +20,7 @@ import org.lemsml.jlems.core.run.EventAction; import org.lemsml.jlems.core.run.KScheme; import org.lemsml.jlems.core.run.StateType; +import org.lemsml.jlems.core.run.RuntimeError; import org.lemsml.jlems.core.sim.ContentError; import org.lemsml.jlems.core.type.Component; import org.lemsml.jlems.core.type.ComponentType; @@ -525,7 +526,7 @@ public Valued getValued(String select) throws ContentError { - public void checkEquations(HashMap cdimHM) throws ContentError { + public void checkEquations(HashMap cdimHM) throws ContentError, RuntimeError { HashMap dimHM = new HashMap(); @@ -559,7 +560,8 @@ public void checkEquations(HashMap cdimHM) throws ContentEr try { dimHM.put(dv.getName(), dv.getDimensionality(dimHM)); } catch (ContentError ce) { - E.error("Checking " + dv + " in " + r_type + " " + ce.getMessage()); + throw new RuntimeError("Checking " + dv + " in " + r_type + " " + ce.getMessage()); + } } @@ -567,7 +569,7 @@ public void checkEquations(HashMap cdimHM) throws ContentEr try { dimHM.put(cdv.getName(), cdv.getDimensionality(dimHM)); } catch (ContentError ce) { - E.error("Checking " + cdv + " in " + r_type + " " + ce.getMessage()); + throw new RuntimeError("Checking " + cdv + " in " + r_type + " " + ce.getMessage()); } }