當前位置: 首頁>>代碼示例>>C#>>正文


C# SBMLDocument.getError方法代碼示例

本文整理匯總了C#中libsbml.SBMLDocument.getError方法的典型用法代碼示例。如果您正苦於以下問題:C# SBMLDocument.getError方法的具體用法?C# SBMLDocument.getError怎麽用?C# SBMLDocument.getError使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在libsbml.SBMLDocument的用法示例。


在下文中一共展示了SBMLDocument.getError方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: test_internal_consistency_check_99902

 public void test_internal_consistency_check_99902()
 {
     SBMLDocument d = new SBMLDocument(2,4);
       long errors;
       Compartment c = new Compartment(2,4);
       d.setLevelAndVersion(1,2,false);
       Model m = d.createModel();
       c.setCompartmentType("hh");
       c.setId("c");
       m.addCompartment(c);
       errors = d.checkInternalConsistency();
       assertTrue( errors == 1 );
       assertTrue( d.getError(0).getErrorId() == 10103 );
       d = null;
 }
開發者ID:mgaldzic,項目名稱:copasi_api,代碼行數:15,代碼來源:TestInternalConsistencyChecks.cs

示例2: test_WriteSBML_error

 public void test_WriteSBML_error()
 {
     SBMLDocument d = new SBMLDocument();
       SBMLWriter w = new SBMLWriter();
       assertEquals( false, w.writeSBML(d, "/tmp/impossible/path/should/fail") );
       assertTrue( d.getNumErrors() == 1 );
       assertTrue( d.getError(0).getErrorId() == libsbml.XMLFileUnwritable );
       d = null;
       w = null;
 }
開發者ID:mgaldzic,項目名稱:copasi_api,代碼行數:10,代碼來源:TestWriteSBML.cs

示例3: test_internal_consistency_check_99911_model

 public void test_internal_consistency_check_99911_model()
 {
     SBMLDocument d = new SBMLDocument(2,4);
       long errors;
       d.setLevelAndVersion(2,1,false);
       Model m = new Model(2,4);
       m.setSBOTerm(2);
       d.setModel(m);
       errors = d.checkInternalConsistency();
       assertTrue( errors == 1 );
       assertTrue( d.getError(0).getErrorId() == 20201 );
       d = null;
 }
開發者ID:mgaldzic,項目名稱:copasi_api,代碼行數:13,代碼來源:TestInternalConsistencyChecks.cs

示例4: test_internal_consistency_check_99904_model

 public void test_internal_consistency_check_99904_model()
 {
     SBMLDocument d = new SBMLDocument(2,4);
       long errors;
       d.setLevelAndVersion(1,2,false);
       Model m = new Model(2,4);
       Compartment c = m.createCompartment();
       c.setId("cc");
       m.setMetaId("mmm");
       d.setModel(m);
       errors = d.checkInternalConsistency();
       assertTrue( errors == 1 );
       assertTrue( d.getError(0).getErrorId() == 20201 );
       d = null;
 }
開發者ID:mgaldzic,項目名稱:copasi_api,代碼行數:15,代碼來源:TestInternalConsistencyChecks.cs


注:本文中的libsbml.SBMLDocument.getError方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。