private void ImportInitialAssignment(InitialAssignment initialAssignment, Model model) { var symbol = initialAssignment.getSymbol(); if (IsParameter(symbol)) { var parameter = GetParameter(symbol); SetPSV(initialAssignment.getMath(), parameter, String.Empty); return; } if (IsContainerSizeParameter(symbol)) { var sizeParameter = GetContainerSizeParameter(symbol); SetPSV(initialAssignment.getMath(), sizeParameter, symbol); return; } if (IsSpeciesAssignment(symbol)) { DoSpeciesAssignment(symbol, initialAssignment.getMath(), isInitialAssignment: true); } CheckSpeciesReferences(initialAssignment.getId(), symbol, model); }
public void test_InitialAssignment_setSymbol2() { string id = "e1"; int i = E.setSymbol(id); assertTrue(i == libsbml.LIBSBML_OPERATION_SUCCESS); assertTrue((id == E.getSymbol())); assertEquals(true, E.isSetSymbol()); i = E.setSymbol(""); assertTrue(i == libsbml.LIBSBML_OPERATION_SUCCESS); assertEquals(false, E.isSetSymbol()); }
public void test_InitialAssignment_create() { assertTrue(IA.getTypeCode() == libsbml.SBML_INITIAL_ASSIGNMENT); assertTrue(IA.getMetaId() == ""); assertTrue(IA.getNotes() == null); assertTrue(IA.getAnnotation() == null); assertTrue(IA.getSymbol() == ""); assertTrue(IA.getMath() == null); }