You can subscribe to this list here.
| 2008 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(121) |
Aug
(343) |
Sep
(98) |
Oct
(55) |
Nov
(158) |
Dec
(219) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2009 |
Jan
(278) |
Feb
(170) |
Mar
(286) |
Apr
(32) |
May
(83) |
Jun
(140) |
Jul
(212) |
Aug
(242) |
Sep
(52) |
Oct
(29) |
Nov
(132) |
Dec
(259) |
| 2010 |
Jan
(251) |
Feb
(147) |
Mar
(76) |
Apr
(140) |
May
(43) |
Jun
(66) |
Jul
(273) |
Aug
(205) |
Sep
(260) |
Oct
(100) |
Nov
(58) |
Dec
(264) |
| 2011 |
Jan
(219) |
Feb
(344) |
Mar
(320) |
Apr
(334) |
May
(125) |
Jun
(131) |
Jul
(195) |
Aug
(155) |
Sep
(55) |
Oct
(261) |
Nov
(286) |
Dec
(216) |
| 2012 |
Jan
(188) |
Feb
(177) |
Mar
(39) |
Apr
(179) |
May
(148) |
Jun
(43) |
Jul
(229) |
Aug
(104) |
Sep
(76) |
Oct
(82) |
Nov
(93) |
Dec
(180) |
| 2013 |
Jan
(323) |
Feb
(335) |
Mar
(35) |
Apr
(220) |
May
(238) |
Jun
(122) |
Jul
(316) |
Aug
(73) |
Sep
(135) |
Oct
(515) |
Nov
(320) |
Dec
(185) |
| 2014 |
Jan
(81) |
Feb
(146) |
Mar
(337) |
Apr
(234) |
May
(112) |
Jun
(239) |
Jul
(323) |
Aug
(123) |
Sep
(83) |
Oct
(285) |
Nov
(321) |
Dec
(96) |
| 2015 |
Jan
(77) |
Feb
(79) |
Mar
(124) |
Apr
(71) |
May
(35) |
Jun
(45) |
Jul
(77) |
Aug
(44) |
Sep
(22) |
Oct
(84) |
Nov
(120) |
Dec
(37) |
| 2016 |
Jan
(38) |
Feb
(74) |
Mar
(242) |
Apr
(153) |
May
(59) |
Jun
(44) |
Jul
(67) |
Aug
(74) |
Sep
(150) |
Oct
(35) |
Nov
(69) |
Dec
(43) |
| 2017 |
Jan
(43) |
Feb
(9) |
Mar
(274) |
Apr
(40) |
May
(81) |
Jun
(81) |
Jul
(87) |
Aug
(46) |
Sep
(98) |
Oct
(50) |
Nov
(220) |
Dec
(66) |
| 2018 |
Jan
(110) |
Feb
(22) |
Mar
(20) |
Apr
(147) |
May
(148) |
Jun
(30) |
Jul
(83) |
Aug
(63) |
Sep
(40) |
Oct
(53) |
Nov
(51) |
Dec
(104) |
| 2019 |
Jan
(14) |
Feb
(81) |
Mar
(80) |
Apr
(102) |
May
(16) |
Jun
(5) |
Jul
(34) |
Aug
(24) |
Sep
(9) |
Oct
(12) |
Nov
(42) |
Dec
(76) |
| 2020 |
Jan
(15) |
Feb
(11) |
Mar
(12) |
Apr
(7) |
May
(6) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2021 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2022 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(5) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
1
(4) |
2
(4) |
3
(18) |
4
(2) |
5
(2) |
|
6
|
7
(17) |
8
(19) |
9
(55) |
10
(12) |
11
(10) |
12
(11) |
|
13
(8) |
14
(24) |
15
(18) |
16
(4) |
17
(9) |
18
(17) |
19
(7) |
|
20
(1) |
21
(30) |
22
(18) |
23
(10) |
24
(18) |
25
(8) |
26
(7) |
|
27
(5) |
28
(6) |
|
|
|
|
|
|
From: <sar...@us...> - 2011-02-28 14:30:21
|
Revision: 13071
http://sbml.svn.sourceforge.net/sbml/?rev=13071&view=rev
Author: sarahkeating
Date: 2011-02-28 14:30:15 +0000 (Mon, 28 Feb 2011)
Log Message:
-----------
64 bit version
Modified Paths:
--------------
trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win64.iss
Modified: trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win64.iss
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win64.iss 2011-02-28 14:27:33 UTC (rev 13070)
+++ trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win64.iss 2011-02-28 14:30:15 UTC (rev 13071)
@@ -9,11 +9,11 @@
AppPublisherURL=http://sbml.org
AppSupportURL=http://sbml.org
AppUpdatesURL=http://sbml.org
-DefaultDirName={pf}\SBML\matlab-libSBML-4.3.0-libxml2-x86
+DefaultDirName={pf}\SBML\matlab-libSBML-4.3.0-libxml2-x64
DefaultGroupName=matlab-libSBML
DisableProgramGroupPage=yes
OutputDir=.\Output
-OutputBaseFilename=matlab-libSBML-4.3.0-win-libxml2-x86
+OutputBaseFilename=matlab-libSBML-4.3.0-win-libxml2-x64
WizardSmallImageFile=..\graphics\libsbml-installer-mini-logo.bmp
WizardImageFile=..\graphics\libsbml-installer-graphic.bmp
UsePreviousAppDir=no
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <sar...@us...> - 2011-02-28 14:27:40
|
Revision: 13070
http://sbml.svn.sourceforge.net/sbml/?rev=13070&view=rev
Author: sarahkeating
Date: 2011-02-28 14:27:33 +0000 (Mon, 28 Feb 2011)
Log Message:
-----------
64 bit version
Added Paths:
-----------
trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win64.iss
Added: trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win64.iss
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win64.iss (rev 0)
+++ trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win64.iss 2011-02-28 14:27:33 UTC (rev 13070)
@@ -0,0 +1,173 @@
+; Version No is currently 4.3.0
+; Check before use
+
+
+[Setup]
+AppName=libSBML-matlab
+AppVerName=libSBML-matlab 4.3.0
+AppPublisher=SBML Team
+AppPublisherURL=http://sbml.org
+AppSupportURL=http://sbml.org
+AppUpdatesURL=http://sbml.org
+DefaultDirName={pf}\SBML\matlab-libSBML-4.3.0-libxml2-x86
+DefaultGroupName=matlab-libSBML
+DisableProgramGroupPage=yes
+OutputDir=.\Output
+OutputBaseFilename=matlab-libSBML-4.3.0-win-libxml2-x86
+WizardSmallImageFile=..\graphics\libsbml-installer-mini-logo.bmp
+WizardImageFile=..\graphics\libsbml-installer-graphic.bmp
+UsePreviousAppDir=no
+Compression=lzma
+SolidCompression=yes
+ArchitecturesInstallIn64BitMode=x64
+
+[Languages]
+Name: english; MessagesFile: compiler:Default.isl
+
+[Files]
+Source: C:\libsbml\dev\utilities\win_installer\matlab\libsbml-matlab\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs
+
+[Registry]
+;Root: HKCU; Subkey: Software\SBML; Flags: uninsdeletekeyifempty
+;Root: HKCU; Subkey: Software\SBML\libSBML; Flags: uninsdeletekey
+;Root: HKLM; Subkey: Software\SBML; Flags: uninsdeletekeyifempty
+;Root: HKLM; Subkey: Software\SBML\libSBML; Flags: uninsdeletekey
+;Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: Version; ValueData: 4.3.0
+;Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: InstallPath; ValueData: {app}
+
+[Code]
+var
+ URLLabel: TNewStaticText;
+ AboutButton, CancelButton: TButton;
+
+ MatlabPresent: Boolean;
+ MatlabVersion: String;
+ MatlabRoot: String;
+
+function GetRunMatlab(Param: String): String;
+begin
+ Result:= MatlabRoot;
+end;
+
+
+{function to return matlab root directory}
+function GetMatlabRoot(S : String): String;
+var
+ Names: TArrayOfString;
+ Root:String;
+ Number: Longint;
+ Key: String;
+
+begin
+ RegGetSubKeyNames(HKLM, 'Software\Mathworks\MATLAB', Names);
+
+ {deals with possible multiple installations of Matlab
+ and choses most recent }
+ Number := GetArrayLength(Names);
+ if Number = 0 then begin
+ Root := '';
+ MatlabPresent := False;
+ end else begin
+ Key := '';
+ Key := Key + 'Software\Mathworks\MATLAB\';
+ Key := Key + Names[Number-1];
+ RegQueryStringValue(HKLM, Key, 'MATLABROOT', Root);
+ MatlabPresent := True;
+ MatlabVersion := Names[Number-1];
+ end;
+
+ Result := Root;
+end;
+
+
+{functions to activate buttons and url on screen}
+procedure AboutButtonOnClick(Sender: TObject);
+begin
+
+{*********************************************************************************************************
+ The text for this message box is what the user will see if they click the About button during installation
+
+ Feel free to alter it to taste but beware it must all be on one line.
+
+ Note: it includes a version number
+**********************************************************************************************************}
+ MsgBox('This setup installs the Windows version of the MATLAB binding of libSBML 4.3.0 built using the libxml2 2.7.3 XML Parser library. All the necessary libraries are included. The source code is available as a separate download.', mbInformation, mb_Ok);
+ end;
+
+
+{send to url}
+procedure URLLabelOnClick(Sender: TObject);
+var
+ Dummy: Integer;
+begin
+ ShellExec('open', 'http://www.sbml.org', '', '', SW_SHOW, ewNoWait, Dummy);
+end;
+
+procedure InitializeWizard;
+begin
+ MatlabRoot := GetMatlabRoot('');
+ MatlabRoot := MatlabRoot + 'bin\matlab.exe';
+
+ {add an about button and a url to all pages}
+ {need a cancel button to locate other}
+ CancelButton := WizardForm.CancelButton;
+
+ AboutButton := TButton.Create(WizardForm);
+ AboutButton.Left := WizardForm.ClientWidth - CancelButton.Left - CancelButton.Width;
+ AboutButton.Top := CancelButton.Top;
+ AboutButton.Width := CancelButton.Width;
+ AboutButton.Height := CancelButton.Height;
+ AboutButton.Caption := '&About...';
+ AboutButton.OnClick := @AboutButtonOnClick;
+ AboutButton.Parent := WizardForm;
+
+
+ URLLabel := TNewStaticText.Create(WizardForm);
+ URLLabel.Top := AboutButton.Top + AboutButton.Height - URLLabel.Height - 2;
+ URLLabel.Left := AboutButton.Left + AboutButton.Width + 20;
+ URLLabel.Caption := 'www.sbml.org';
+ URLLabel.Font.Style := URLLabel.Font.Style + [fsUnderLine];
+ URLLabel.Font.Color := clBlue;
+ URLLabel.Cursor := crHand;
+ URLLabel.OnClick := @URLLabelOnClick;
+ URLLabel.Parent := WizardForm;
+
+
+end;
+
+function ShouldSkipPage(PageID: Integer): Boolean;
+begin
+ { Skip pages that shouldn't be shown }
+ Result := False;
+end;
+
+function NextButtonClick(CurPageID: Integer): Boolean;
+
+begin
+ { Validate certain pages before allowing the user to proceed }
+ if CurPageID = wpWelcome then begin
+ Result := True;
+ end else begin
+ Result := True;
+ end;
+end;
+
+function UpdateReadyMemo(Space, NewLine, MemoUserInfoInfo, MemoDirInfo, MemoTypeInfo, MemoComponentsInfo, MemoGroupInfo, MemoTasksInfo: String): String;
+var
+ S: String;
+begin
+ { Fill the 'Ready Memo' with the normal settings and the custom settings }
+ S := '';
+ S := S + MemoDirInfo + NewLine;
+ S := S + NewLine;
+
+
+
+ Result:= S;
+end;
+
+[Run]
+
+
+Filename: "{app}\install\install.bat"; Parameters: """{code:GetRunMatlab}"""
+
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <sar...@us...> - 2011-02-28 14:19:25
|
Revision: 13069
http://sbml.svn.sourceforge.net/sbml/?rev=13069&view=rev
Author: sarahkeating
Date: 2011-02-28 14:19:17 +0000 (Mon, 28 Feb 2011)
Log Message:
-----------
initial import of files to create an independent installer for matlab
Added Paths:
-----------
trunk/libsbml/dev/utilities/win_installer/matlab/
trunk/libsbml/dev/utilities/win_installer/matlab/Uninstall_libSBML_matlab.bat
trunk/libsbml/dev/utilities/win_installer/matlab/createInstallFiles.bat
trunk/libsbml/dev/utilities/win_installer/matlab/install/
trunk/libsbml/dev/utilities/win_installer/matlab/install/install.bat
trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win32.iss
Added: trunk/libsbml/dev/utilities/win_installer/matlab/Uninstall_libSBML_matlab.bat
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/matlab/Uninstall_libSBML_matlab.bat (rev 0)
+++ trunk/libsbml/dev/utilities/win_installer/matlab/Uninstall_libSBML_matlab.bat 2011-02-28 14:19:17 UTC (rev 13069)
@@ -0,0 +1 @@
+unins000.exe
Added: trunk/libsbml/dev/utilities/win_installer/matlab/createInstallFiles.bat
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/matlab/createInstallFiles.bat (rev 0)
+++ trunk/libsbml/dev/utilities/win_installer/matlab/createInstallFiles.bat 2011-02-28 14:19:17 UTC (rev 13069)
@@ -0,0 +1,60 @@
+rmdir /S libsbml-matlab
+
+mkdir libsbml-matlab
+cd libsbml-matlab
+
+rem copy files
+
+copy ..\..\..\..\..\AUTHORS.txt AUTHORS.txt
+copy ..\..\..\..\..\COPYING.txt COPYING.txt
+copy ..\..\..\..\..\FUNDING.txt FUNDING.txt
+copy ..\..\..\..\..\VERSION.txt VERSION.txt
+copy ..\..\..\..\..\COPYING.html COPYING.html
+copy ..\Uninstall_libSBML_matlab.bat Uninstall_libSBML_matlab.bat
+
+rem make new directories
+
+mkdir matlab
+mkdir install
+
+rem matlab directory
+
+cd matlab
+copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.m TranslateSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.c TranslateSBML.c
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.m OutputSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.c OutputSBML.c
+copy ..\..\..\..\..\..\src\bindings\matlab\Contents.m Contents.m
+copy ..\..\..\..\..\..\src\bindings\matlab\CheckAndConvert.m CheckAndConvert.m
+copy ..\..\..\..\..\..\src\bindings\matlab\isoctave.m isoctave.m
+copy ..\..\..\..\..\..\src\bindings\matlab\ConvertFormulaToMathML.m ConvertFormulaToMathML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\isSBML_Model.m isSBML_Model.m
+copy ..\..\..\..\..\..\src\bindings\matlab\buildSBML.m buildSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\installSBML.m installSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\test.xml test.xml
+
+REM these need to find the static matlab builds
+
+copy ..\..\..\friday-25\libSBML-4.3.0-win32\libSBML-4.3.0-win32\bindings\matlab\TranslateSBML.mexw32 TranslateSBML.mexw32
+copy ..\..\..\friday-25\libSBML-4.3.0-win32\libSBML-4.3.0-win32\bindings\matlab\OutputSBML.mexw32 OutputSBML.mexw32
+
+cd ..
+
+cd install
+copy ..\..\install\install.bat install.bat
+cd ..
+
+
+cd C:\libsbml_trunk\dev\utilities\win_installer\matlab
+
+
+
+
+
+
+
+
+
+
+
+
Added: trunk/libsbml/dev/utilities/win_installer/matlab/install/install.bat
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/matlab/install/install.bat (rev 0)
+++ trunk/libsbml/dev/utilities/win_installer/matlab/install/install.bat 2011-02-28 14:19:17 UTC (rev 13069)
@@ -0,0 +1,3 @@
+cd ..
+cd matlab
+%1 -r installSBML
Added: trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win32.iss
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win32.iss (rev 0)
+++ trunk/libsbml/dev/utilities/win_installer/matlab/install_matlab_libsbml_script_xml_win32.iss 2011-02-28 14:19:17 UTC (rev 13069)
@@ -0,0 +1,172 @@
+; Version No is currently 4.3.0
+; Check before use
+
+
+[Setup]
+AppName=libSBML-matlab
+AppVerName=libSBML-matlab 4.3.0
+AppPublisher=SBML Team
+AppPublisherURL=http://sbml.org
+AppSupportURL=http://sbml.org
+AppUpdatesURL=http://sbml.org
+DefaultDirName={pf}\SBML\matlab-libSBML-4.3.0-libxml2-x86
+DefaultGroupName=matlab-libSBML
+DisableProgramGroupPage=yes
+OutputDir=.\Output
+OutputBaseFilename=matlab-libSBML-4.3.0-win-libxml2-x86
+WizardSmallImageFile=..\graphics\libsbml-installer-mini-logo.bmp
+WizardImageFile=..\graphics\libsbml-installer-graphic.bmp
+UsePreviousAppDir=no
+Compression=lzma
+SolidCompression=yes
+
+[Languages]
+Name: english; MessagesFile: compiler:Default.isl
+
+[Files]
+Source: C:\libsbml_trunk\dev\utilities\win_installer\matlab\libsbml-matlab\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs
+
+[Registry]
+;Root: HKCU; Subkey: Software\SBML; Flags: uninsdeletekeyifempty
+;Root: HKCU; Subkey: Software\SBML\libSBML; Flags: uninsdeletekey
+;Root: HKLM; Subkey: Software\SBML; Flags: uninsdeletekeyifempty
+;Root: HKLM; Subkey: Software\SBML\libSBML; Flags: uninsdeletekey
+;Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: Version; ValueData: 4.3.0
+;Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: InstallPath; ValueData: {app}
+
+[Code]
+var
+ URLLabel: TNewStaticText;
+ AboutButton, CancelButton: TButton;
+
+ MatlabPresent: Boolean;
+ MatlabVersion: String;
+ MatlabRoot: String;
+
+function GetRunMatlab(Param: String): String;
+begin
+ Result:= MatlabRoot;
+end;
+
+
+{function to return matlab root directory}
+function GetMatlabRoot(S : String): String;
+var
+ Names: TArrayOfString;
+ Root:String;
+ Number: Longint;
+ Key: String;
+
+begin
+ RegGetSubKeyNames(HKLM, 'Software\Mathworks\MATLAB', Names);
+
+ {deals with possible multiple installations of Matlab
+ and choses most recent }
+ Number := GetArrayLength(Names);
+ if Number = 0 then begin
+ Root := '';
+ MatlabPresent := False;
+ end else begin
+ Key := '';
+ Key := Key + 'Software\Mathworks\MATLAB\';
+ Key := Key + Names[Number-1];
+ RegQueryStringValue(HKLM, Key, 'MATLABROOT', Root);
+ MatlabPresent := True;
+ MatlabVersion := Names[Number-1];
+ end;
+
+ Result := Root;
+end;
+
+
+{functions to activate buttons and url on screen}
+procedure AboutButtonOnClick(Sender: TObject);
+begin
+
+{*********************************************************************************************************
+ The text for this message box is what the user will see if they click the About button during installation
+
+ Feel free to alter it to taste but beware it must all be on one line.
+
+ Note: it includes a version number
+**********************************************************************************************************}
+ MsgBox('This setup installs the Windows version of the MATLAB binding of libSBML 4.3.0 built using the libxml2 2.7.3 XML Parser library. All the necessary libraries are included. The source code is available as a separate download.', mbInformation, mb_Ok);
+ end;
+
+
+{send to url}
+procedure URLLabelOnClick(Sender: TObject);
+var
+ Dummy: Integer;
+begin
+ ShellExec('open', 'http://www.sbml.org', '', '', SW_SHOW, ewNoWait, Dummy);
+end;
+
+procedure InitializeWizard;
+begin
+ MatlabRoot := GetMatlabRoot('');
+ MatlabRoot := MatlabRoot + 'bin\matlab.exe';
+
+ {add an about button and a url to all pages}
+ {need a cancel button to locate other}
+ CancelButton := WizardForm.CancelButton;
+
+ AboutButton := TButton.Create(WizardForm);
+ AboutButton.Left := WizardForm.ClientWidth - CancelButton.Left - CancelButton.Width;
+ AboutButton.Top := CancelButton.Top;
+ AboutButton.Width := CancelButton.Width;
+ AboutButton.Height := CancelButton.Height;
+ AboutButton.Caption := '&About...';
+ AboutButton.OnClick := @AboutButtonOnClick;
+ AboutButton.Parent := WizardForm;
+
+
+ URLLabel := TNewStaticText.Create(WizardForm);
+ URLLabel.Top := AboutButton.Top + AboutButton.Height - URLLabel.Height - 2;
+ URLLabel.Left := AboutButton.Left + AboutButton.Width + 20;
+ URLLabel.Caption := 'www.sbml.org';
+ URLLabel.Font.Style := URLLabel.Font.Style + [fsUnderLine];
+ URLLabel.Font.Color := clBlue;
+ URLLabel.Cursor := crHand;
+ URLLabel.OnClick := @URLLabelOnClick;
+ URLLabel.Parent := WizardForm;
+
+
+end;
+
+function ShouldSkipPage(PageID: Integer): Boolean;
+begin
+ { Skip pages that shouldn't be shown }
+ Result := False;
+end;
+
+function NextButtonClick(CurPageID: Integer): Boolean;
+
+begin
+ { Validate certain pages before allowing the user to proceed }
+ if CurPageID = wpWelcome then begin
+ Result := True;
+ end else begin
+ Result := True;
+ end;
+end;
+
+function UpdateReadyMemo(Space, NewLine, MemoUserInfoInfo, MemoDirInfo, MemoTypeInfo, MemoComponentsInfo, MemoGroupInfo, MemoTasksInfo: String): String;
+var
+ S: String;
+begin
+ { Fill the 'Ready Memo' with the normal settings and the custom settings }
+ S := '';
+ S := S + MemoDirInfo + NewLine;
+ S := S + NewLine;
+
+
+
+ Result:= S;
+end;
+
+[Run]
+
+
+Filename: "{app}\install\install.bat"; Parameters: """{code:GetRunMatlab}"""
+
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-28 00:51:16
|
Revision: 13068
http://sbml.svn.sourceforge.net/sbml/?rev=13068&view=rev
Author: fbergmann
Date: 2011-02-28 00:51:10 +0000 (Mon, 28 Feb 2011)
Log Message:
-----------
- fixed typo
Modified Paths:
--------------
trunk/libsbml/CMakeLists.txt
Modified: trunk/libsbml/CMakeLists.txt
===================================================================
--- trunk/libsbml/CMakeLists.txt 2011-02-28 00:45:47 UTC (rev 13067)
+++ trunk/libsbml/CMakeLists.txt 2011-02-28 00:51:10 UTC (rev 13068)
@@ -533,7 +533,7 @@
file(GLOB WIN32_BINARIES ${CMAKE_SOURCE_DIR}/dependencies/bin/*.dll)
install(FILES ${WIN32_BINARIES} DESTINATION bin)
file(GLOB WIN32_DEPENDENCIES ${CMAKE_SOURCE_DIR}/dependencies/lib/*.lib)
- install(FILES ${WIN32_BINARIES} DESTINATION lib)
+ install(FILES ${WIN32_DEPENDENCIES} DESTINATION lib)
elseif(CYGWIN)
add_definitions(-DCYGWIN)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-28 00:45:53
|
Revision: 13067
http://sbml.svn.sourceforge.net/sbml/?rev=13067&view=rev
Author: fbergmann
Date: 2011-02-28 00:45:47 +0000 (Mon, 28 Feb 2011)
Log Message:
-----------
- allow testrunner to be compiled with .net 2.0 clr
Modified Paths:
--------------
trunk/libsbml/src/bindings/csharp/TestRunner.cs
Modified: trunk/libsbml/src/bindings/csharp/TestRunner.cs
===================================================================
--- trunk/libsbml/src/bindings/csharp/TestRunner.cs 2011-02-28 00:41:51 UTC (rev 13066)
+++ trunk/libsbml/src/bindings/csharp/TestRunner.cs 2011-02-28 00:45:47 UTC (rev 13067)
@@ -213,7 +213,7 @@
{
if (_errors == null || _errors.Count == 0) return;
- foreach (var item in _errors)
+ foreach (ErrorDetails item in _errors)
{
Console.WriteLine();
Console.WriteLine();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-28 00:41:58
|
Revision: 13066
http://sbml.svn.sourceforge.net/sbml/?rev=13066&view=rev
Author: fbergmann
Date: 2011-02-28 00:41:51 +0000 (Mon, 28 Feb 2011)
Log Message:
-----------
- install dependencies
Modified Paths:
--------------
trunk/libsbml/CMakeLists.txt
Modified: trunk/libsbml/CMakeLists.txt
===================================================================
--- trunk/libsbml/CMakeLists.txt 2011-02-27 23:44:54 UTC (rev 13065)
+++ trunk/libsbml/CMakeLists.txt 2011-02-28 00:41:51 UTC (rev 13066)
@@ -531,7 +531,9 @@
endif(WITH_STATIC_RUNTIME)
file(GLOB WIN32_BINARIES ${CMAKE_SOURCE_DIR}/dependencies/bin/*.dll)
- INSTALL(FILES ${WIN32_BINARIES} DESTINATION bin)
+ install(FILES ${WIN32_BINARIES} DESTINATION bin)
+ file(GLOB WIN32_DEPENDENCIES ${CMAKE_SOURCE_DIR}/dependencies/lib/*.lib)
+ install(FILES ${WIN32_BINARIES} DESTINATION lib)
elseif(CYGWIN)
add_definitions(-DCYGWIN)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-27 23:45:01
|
Revision: 13065
http://sbml.svn.sourceforge.net/sbml/?rev=13065&view=rev
Author: fbergmann
Date: 2011-02-27 23:44:54 +0000 (Sun, 27 Feb 2011)
Log Message:
-----------
- SWIGTYPE_p_std__string is no longer exposed
Modified Paths:
--------------
trunk/libsbml/win/msvc7/common/csharp/CSharp_cspDLL.csproj
trunk/libsbml/win/msvc8/common/csharp/CSharp_cspDLL.csproj
trunk/libsbml/win/msvc9/common/csharp/CSharp_cspDLL.csproj
Modified: trunk/libsbml/win/msvc7/common/csharp/CSharp_cspDLL.csproj
===================================================================
--- trunk/libsbml/win/msvc7/common/csharp/CSharp_cspDLL.csproj 2011-02-27 05:53:08 UTC (rev 13064)
+++ trunk/libsbml/win/msvc7/common/csharp/CSharp_cspDLL.csproj 2011-02-27 23:44:54 UTC (rev 13065)
@@ -519,11 +519,6 @@
BuildAction = "Compile"
/>
<File
- RelPath = "csharp-files-win\SWIGTYPE_p_std__string.cs"
- SubType = "Code"
- BuildAction = "Compile"
- />
- <File
RelPath = "csharp-files-win\TextGlyph.cs"
SubType = "Code"
BuildAction = "Compile"
Modified: trunk/libsbml/win/msvc8/common/csharp/CSharp_cspDLL.csproj
===================================================================
--- trunk/libsbml/win/msvc8/common/csharp/CSharp_cspDLL.csproj 2011-02-27 05:53:08 UTC (rev 13064)
+++ trunk/libsbml/win/msvc8/common/csharp/CSharp_cspDLL.csproj 2011-02-27 23:44:54 UTC (rev 13065)
@@ -347,9 +347,6 @@
<Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\SWIGTYPE_p_std__ostream.cs">
<SubType>Code</SubType>
</Compile>
- <Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\SWIGTYPE_p_std__string.cs">
- <SubType>Code</SubType>
- </Compile>
<Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\TextGlyph.cs">
<SubType>Code</SubType>
</Compile>
Modified: trunk/libsbml/win/msvc9/common/csharp/CSharp_cspDLL.csproj
===================================================================
--- trunk/libsbml/win/msvc9/common/csharp/CSharp_cspDLL.csproj 2011-02-27 05:53:08 UTC (rev 13064)
+++ trunk/libsbml/win/msvc9/common/csharp/CSharp_cspDLL.csproj 2011-02-27 23:44:54 UTC (rev 13065)
@@ -348,9 +348,6 @@
<Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\SWIGTYPE_p_std__ostream.cs">
<SubType>Code</SubType>
</Compile>
- <Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\SWIGTYPE_p_std__string.cs">
- <SubType>Code</SubType>
- </Compile>
<Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\TextGlyph.cs">
<SubType>Code</SubType>
</Compile>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <mh...@us...> - 2011-02-27 05:53:15
|
Revision: 13064
http://sbml.svn.sourceforge.net/sbml/?rev=13064&view=rev
Author: mhucka
Date: 2011-02-27 05:53:08 +0000 (Sun, 27 Feb 2011)
Log Message:
-----------
Added code examples for python.
Modified Paths:
--------------
trunk/libsbml/src/sbml/Model.h
trunk/libsbml/src/sbml/SBMLNamespaces.h
trunk/libsbml/src/xml/XMLNode.h
Modified: trunk/libsbml/src/sbml/Model.h
===================================================================
--- trunk/libsbml/src/sbml/Model.h 2011-02-27 05:16:27 UTC (rev 13063)
+++ trunk/libsbml/src/sbml/Model.h 2011-02-27 05:53:08 UTC (rev 13064)
@@ -118,7 +118,7 @@
// of the object attached to the model (as expected).
Model* model = sbmlDoc->createModel();
-model->setId("BestModelEver");
+model->setId("BestModelEver");
// Create a Species object inside the Model and set its identifier.
// Similar to the lines above, this call returns a pointer to the Species
@@ -126,7 +126,7 @@
// of the object attached to the model (as expected).
Species *sp = model->createSpecies();
-sp->setId("MySpecies");
+sp->setId("MySpecies");
@endverbatim
* @endif@if java
@verbatim
@@ -137,7 +137,9 @@
// Create a Model object inside the SBMLDocument object and set
// its identifier. The call returns a pointer to the Model object
// created, and methods called on that object affect the attributes
-// of the object attached to the model (as expected).
+// of the object attached to the model (as expected). Note that
+// the call to setId() returns a status code, and a real program
+// should check this status code to make sure everything went okay.
Model model = sbmlDoc.createModel();
model.setId("BestModelEver");
@@ -145,67 +147,49 @@
// Create a Species object inside the Model and set its identifier.
// Similar to the lines above, this call returns a pointer to the Species
// object created, and methods called on that object affect the attributes
-// of the object attached to the model (as expected).
+// of the object attached to the model (as expected). Note that, like
+// with Model, the call to setId() returns a status code, and a real program
+// should check this status code to make sure everything went okay.
Species sp = model.createSpecies();
sp.setId("BestSpeciesEver");
@endverbatim
+ * @endif@if python
+@verbatim
+# Create an SBMLDocument object in Level 3 Version 1 format:
+
+sbmlDoc = SBMLDocument(3, 1)
+
+# Create a Model object inside the SBMLDocument object and set
+# its identifier. The call to setId() returns a status code
+# to indicate whether the assignment was successful. Code 0
+# means success; see the documentation for Model's setId() for
+# more information.
+
+model = sbmlDoc.createModel()
+model.setId("BestModelEver")
+
+# Create a Species object inside the Model and set its identifier.
+# Again, the setId() returns a status code to indicate whether the
+# assignment was successful. Code 0 means success; see the
+# documentation for Specie's setId() for more information.
+
+sp = model.createSpecies()
+sp.setId("BestSpeciesEver")
+@endverbatim
* @endif
*
* The <code>create<span
* class="placeholder"><em>Object</em></span>()</code> methods return a
* pointer to the object created, but they also add the object to the
* relevant list of object instances contained in the parent. (These lists
- * become the <code><listOf<i>Object</i>s></code> elements in the
+ * become the <code><listOf<span
+ * class="placeholder"><em>Object</em></span>s></code> elements in the
* finished XML rendition of SBML.) In the example above,
* Model::createSpecies() adds the created species directly to the
* <code><listOfSpecies<i></i>></code> list in the model. Subsequently,
* methods called on the species change the species in the model (which is
* what is expected in most situations).
- *
- * By contrast, the other main way of creating an object and adding it to a
- * parent makes a @em copy of the object, and requires more care on the
- * part of the caller. Here is an example of this alternative approach: @if clike
- * @verbatim
-// Create a Species object and add it to the model.
-// This uses the Species class constructor:
-
-Species *newsp = Species("BestSpeciesEver");
-model->addSpecies(newsp); // Warning! This makes a COPY inside 'model'.
-
-// addSpecies(...) copies the object, with the result that
-// 'newsp' still refers to the original. The following may not
-// do what is expected:
-
-newsp->setId("NewId"); // Warning -- doesn't change the species in 'model'!
-
-// If 'newsp' object is not going to be used further, it needs
-// to be deleted to avoid a memory leak.
-
-delete newsp;
-@endverbatim
- * @endif@if java
-@verbatim
-// Create a Species object and add it to the model.
-// This uses the Species class constructor:
-
-Species newsp = Species("BestSpeciesEver");
-model.addSpecies(newsp); // Warning! This makes a COPY inside 'model'.
-
-// addSpecies(...) copies the object, with the result that
-// 'newsp' still refers to the original. The following may not
-// do what is expected:
-
-newsp.setId("NewId"); // Warning -- doesn't change the species in 'model'!
-@endverbatim
- * @endif
- *
- * The key point of the example above is that, because the
- * @if java Model::addSpecies(Species s)@else Model::addSpecies()@endif
- * call makes a copy of the object handed to it, care is needed
- * @if clike both when attempting to make changes to the object, and when
- * the original object is no longer needed.@else when attempting to make
- * changes to the object.@endif
*
* @section checking Consistency and adherence to SBML specifications
*
Modified: trunk/libsbml/src/sbml/SBMLNamespaces.h
===================================================================
--- trunk/libsbml/src/sbml/SBMLNamespaces.h 2011-02-27 05:16:27 UTC (rev 13063)
+++ trunk/libsbml/src/sbml/SBMLNamespaces.h 2011-02-27 05:53:08 UTC (rev 13064)
@@ -278,6 +278,23 @@
// Handle another truly exceptional situation.
}
@endverbatim
+ * @endif@if python
+@verbatim
+sbmlDoc = SBMLDocument(3, 1)
+if sbmlDoc == None:
+ # Do something to handle exceptional situation. Candidate
+ # causes include invalid combinations of SBML Level and Version
+ # (impossible if hardwired as given here), running out of memory, and
+ # unknown system exceptions.
+
+namespaces = sbmlDoc.getNamespaces()
+if namespaces == None:
+ # Do something to handle exceptional situation.
+
+status = namespaces.add("http://www.w3.org/1999/xhtml", "html")
+if status != LIBSBML_OPERATION_SUCCESS:
+ # Do something to handle exceptional situation.
+@endverbatim
* @endif
*
* @param xmlns the XML namespaces to be added.
Modified: trunk/libsbml/src/xml/XMLNode.h
===================================================================
--- trunk/libsbml/src/xml/XMLNode.h 2011-02-27 05:16:27 UTC (rev 13063)
+++ trunk/libsbml/src/xml/XMLNode.h 2011-02-27 05:53:08 UTC (rev 13064)
@@ -125,8 +125,19 @@
...
}
@endverbatim
+ * @endif@if python
+@verbatim
+xn = XMLNode.convertStringToXMLNode("<p></p>")
+if xn == None:
+ # Do something to handle exceptional situation.
+
+elif xn.isEOF():
+ # Node is a dummy node.
+
+else:
+ # None is not a dummy node.
+@endverbatim
* @endif
- *
*/
#ifndef XMLNode_h
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <mh...@us...> - 2011-02-27 05:16:36
|
Revision: 13063
http://sbml.svn.sourceforge.net/sbml/?rev=13063&view=rev
Author: mhucka
Date: 2011-02-27 05:16:27 +0000 (Sun, 27 Feb 2011)
Log Message:
-----------
Improved handling of conditional documentation sections
for different languages. Now using @else inside @if...@endif, after having
modified swigdoc.py to make it work.
Modified Paths:
--------------
trunk/libsbml/src/annotation/CVTerm.h
trunk/libsbml/src/annotation/RDFAnnotation.h
trunk/libsbml/src/math/ASTNode.h
trunk/libsbml/src/math/FormulaFormatter.h
trunk/libsbml/src/math/FormulaParser.h
trunk/libsbml/src/sbml/Compartment.h
trunk/libsbml/src/sbml/CompartmentType.h
trunk/libsbml/src/sbml/InitialAssignment.h
trunk/libsbml/src/sbml/KineticLaw.h
trunk/libsbml/src/sbml/LocalParameter.h
trunk/libsbml/src/sbml/Model.h
trunk/libsbml/src/sbml/Parameter.h
trunk/libsbml/src/sbml/Rule.h
trunk/libsbml/src/sbml/SBMLDocument.h
trunk/libsbml/src/sbml/SBMLError.h
trunk/libsbml/src/sbml/SBMLErrorLog.h
trunk/libsbml/src/sbml/SBMLNamespaces.h
trunk/libsbml/src/sbml/SBMLReader.h
trunk/libsbml/src/sbml/SBMLWriter.h
trunk/libsbml/src/sbml/SBase.h
trunk/libsbml/src/sbml/Species.h
trunk/libsbml/src/sbml/SpeciesReference.h
trunk/libsbml/src/sbml/SpeciesType.h
trunk/libsbml/src/sbml/Unit.h
trunk/libsbml/src/sbml/UnitDefinition.h
trunk/libsbml/src/xml/XMLError.h
trunk/libsbml/src/xml/XMLErrorLog.h
trunk/libsbml/src/xml/XMLNamespaces.h
trunk/libsbml/src/xml/XMLNode.h
trunk/libsbml/src/xml/XMLToken.h
Modified: trunk/libsbml/src/annotation/CVTerm.h
===================================================================
--- trunk/libsbml/src/annotation/CVTerm.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/annotation/CVTerm.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -55,34 +55,34 @@
* such as Species, Compartment, etc. The following template illustrates
* the different parts of SBML annotations in XML form:
*
-<div class="fragment">
-<<span style="background-color: #bbb">SBML_ELEMENT</span> <span style="background-color: #d0eed0">+++</span> metaid="<span style="border-bottom: 1px solid black">meta id</span>" <span style="background-color: #d0eed0">+++</span>><br>
- <span style="background-color: #d0eed0">+++</span><br>
- <annotation><br>
- <span style="background-color: #d0eed0">+++</span><br>
- <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"<br>
- xmlns:dc="http://purl.org/dc/elements/1.1/"<br>
- xmlns:dcterm="http://purl.org/dc/terms/"<br>
- xmlns:vcard="http://www.w3.org/2001/vcard-rdf/3.0#"<br>
- xmlns:bqbiol="http://biomodels.net/biology-qualifiers/"<br>
- xmlns:bqmodel="http://biomodels.net/model-qualifiers/" ><br>
- <rdf:Description rdf:about="#<span style="border-bottom: 1px solid black">meta id</span>"><br>
- <span style="background-color: #ddd; border-bottom: 2px dotted #888">HISTORY</span><br>
- <<span style="background-color: #bbb">RELATION_ELEMENT</span>><br>
- <rdf:Bag><br>
- <rdf:li rdf:resource="<span style="background-color: #d0d0ee">URI</span>" /><br>
- <span style="background-color: #edd">...</span><br>
- </rdf:Bag><br>
- </<span style="background-color: #bbb">RELATION_ELEMENT</span>><br>
- <span style="background-color: #edd">...</span><br>
- </rdf:Description><br>
- <span style="background-color: #d0eed0">+++</span><br>
- </rdf:RDF><br>
- <span style="background-color: #d0eed0">+++</span><br>
- </annotation><br>
- <span style="background-color: #d0eed0">+++</span><br>
-</<span style="background-color: #bbb">SBML_ELEMENT</span>><br>
-</div>
+ <div class="fragment">
+ <<span style="background-color: #bbb">SBML_ELEMENT</span> <span style="background-color: #d0eed0">+++</span> metaid="<span style="border-bottom: 1px solid black">meta id</span>" <span style="background-color: #d0eed0">+++</span>><br>
+ <span style="background-color: #d0eed0">+++</span><br>
+ <annotation><br>
+ <span style="background-color: #d0eed0">+++</span><br>
+ <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"<br>
+ xmlns:dc="http://purl.org/dc/elements/1.1/"<br>
+ xmlns:dcterm="http://purl.org/dc/terms/"<br>
+ xmlns:vcard="http://www.w3.org/2001/vcard-rdf/3.0#"<br>
+ xmlns:bqbiol="http://biomodels.net/biology-qualifiers/"<br>
+ xmlns:bqmodel="http://biomodels.net/model-qualifiers/" ><br>
+ <rdf:Description rdf:about="#<span style="border-bottom: 1px solid black">meta id</span>"><br>
+ <span style="background-color: #e0e0e0; border-bottom: 2px dotted #888">HISTORY</span><br>
+ <<span style="background-color: #bbb">RELATION_ELEMENT</span>><br>
+ <rdf:Bag><br>
+ <rdf:li rdf:resource="<span style="background-color: #d0d0ee">URI</span>" /><br>
+ <span style="background-color: #edd">...</span><br>
+ </rdf:Bag><br>
+ </<span style="background-color: #bbb">RELATION_ELEMENT</span>><br>
+ <span style="background-color: #edd">...</span><br>
+ </rdf:Description><br>
+ <span style="background-color: #d0eed0">+++</span><br>
+ </rdf:RDF><br>
+ <span style="background-color: #d0eed0">+++</span><br>
+ </annotation><br>
+ <span style="background-color: #d0eed0">+++</span><br>
+ </<span style="background-color: #bbb">SBML_ELEMENT</span>><br>
+ </div>
*
* In the template above, the placeholder
* <span class="code" style="background-color: #bbb">SBML_ELEMENT</span> stands for
@@ -99,7 +99,7 @@
* <span class="code" style="background-color: #edd">...</span>
* are placeholders for zero or more elements of the same form as the
* immediately preceding element. The optional content
- * <span class="code" style="background-color: #ddd; border-bottom: 2px dotted #888">HISTORY</span>
+ * <span class="code" style="background-color: #e0e0e0; border-bottom: 2px dotted #888">HISTORY</span>
* is a creation and modification history; in libSBML, this is stored
* using ModelHistory objects.
*
@@ -226,8 +226,7 @@
/**
* Creates an empty CVTerm, optionally with the given
- * @if clike #QualifierType_t@endif@if java qualifier type code@endif value
- * @p type.
+ * @if clike #QualifierType_t value@else qualifier@endif @p type.
*
* The SBML Level 2 and Level 3 specifications define a simple
* format for annotating models when (a) referring to controlled
@@ -253,8 +252,8 @@
* an explicit value for @p type is not given, this method defaults to
* using @link QualifierType_t#UNKNOWN_QUALIFIER
* UNKNOWN_QUALIFIER@endlink. The
- * @if clike #QualifierType_t@endif@if java qualifier type code@endif
- * type value can be set later using the
+ * @if clike #QualifierType_t value@else qualifier type@endif
+ * can be set later using the
* CVTerm::setQualifierType(@if java int type@endif) method.
*
* Different BioModels.net qualifier elements encode different types of
@@ -263,7 +262,7 @@
* qualifiers web page</a> for an explanation of the meaning of these
* different qualifiers.
*
- * @param type a @if clike #QualifierType_t@endif@if java qualifier type code@endif value
+ * @param type a @if clike #QualifierType_t value@else qualifier type@endif
*
* @if notcpp @docnote @htmlinclude warn-default-args-in-docs.html @endif
*/
@@ -337,7 +336,7 @@
/**
- * Returns the qualifier type code for this CVTerm object.
+ * Returns the qualifier type of this CVTerm object.
*
* @htmlinclude cvterm-common-description-text.html
*
@@ -363,8 +362,8 @@
* the @em other two methods to call to find out the specific
* relationship.
*
- * @return the @if clike #QualifierType_t@endif@if java qualifier type code@endif value of this object or
- * @link QualifierType_t#UNKNOWN_QUALIFIER UNKNOWN_QUALIFIER@endlink
+ * @return the @if clike #QualifierType_t value@else qualifier type@endif
+ * of this object or @link QualifierType_t#UNKNOWN_QUALIFIER UNKNOWN_QUALIFIER@endlink
* (the default).
*
* @see getResources()
@@ -375,7 +374,7 @@
/**
- * Returns the model qualifier type code for this CVTerm object.
+ * Returns the model qualifier type of this CVTerm object.
*
* @htmlinclude cvterm-common-description-text.html
*
@@ -399,15 +398,15 @@
* unknown by libSBML and reported as
* @link ModelQualifierType_t#BQM_UNKNOWN BQM_UNKNOWN@endlink.
*
- * @return the @if clike #ModelQualifierType_t@endif@if java model qualifier type code@endif value of this object or
- * @link ModelQualifierType_t#BQM_UNKNOWN BQM_UNKNOWN@endlink
+ * @return the @if clike #ModelQualifierType_t value@else model qualifier type@endif
+ * of this object or @link ModelQualifierType_t#BQM_UNKNOWN BQM_UNKNOWN@endlink
* (the default).
*/
ModelQualifierType_t getModelQualifierType();
/**
- * Returns the biological qualifier type code for this CVTerm object.
+ * Returns the biological qualifier type of this CVTerm object.
*
* @htmlinclude cvterm-common-description-text.html
*
@@ -440,8 +439,8 @@
* unknown by libSBML and reported as
* @link BiolQualifierType_t#BQB_UNKNOWN BQB_UNKNOWN@endlink.
*
- * @return the @if clike #BiolQualifierType_t@endif@if java biology qualifier type code@endif value of this object or
- * @link BiolQualifierType_t#BQB_UNKNOWN BQB_UNKNOWN@endlink
+ * @return the @if clike #BiolQualifierType_t value@else biology qualifier type@endif
+ * of this object or @link BiolQualifierType_t#BQB_UNKNOWN BQB_UNKNOWN@endlink
* (the default).
*/
BiolQualifierType_t getBiologicalQualifierType();
@@ -545,11 +544,11 @@
/**
- * Sets the @if clike #QualifierType_t@endif@if java qualifier type code@endif value of this CVTerm object.
+ * Sets the @if clike #QualifierType_t@else qualifier code@endif of this
+ * CVTerm object.
*
- * @param type the @if clike #QualifierType_t@endif@if java qualifier type code@endif type value
- * function. The possible values
- * returned by this function are:
+ * @param type the @if clike #QualifierType_t value@else qualifier type@endif.
+ * The possible values returned by this function are:
* @li @link OperationReturnValues_t#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS@endlink
*
* @see getQualifierType()
@@ -558,13 +557,13 @@
/**
- * Sets the @if clike #ModelQualifierType_t@endif@if java model qualifier type code@endif value of this CVTerm object.
+ * Sets the @if clike #ModelQualifierType_t value@else model qualifier type@endif
+ * of this CVTerm object.
*
- * @param type the @if clike #ModelQualifierType_t@endif@if java model qualifier type code@endif value
+ * @param type the @if clike #ModelQualifierType_t value@else model qualifier type@endif
*
* @return integer value indicating success/failure of the
- * function. The possible values
- * returned by this function are:
+ * function. The possible values returned by this function are:
* @li @link OperationReturnValues_t#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS@endlink
* @li @link OperationReturnValues_t#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE@endlink
*
@@ -580,19 +579,19 @@
/**
- * Sets the @if clike #BiolQualifierType_t@endif@if java biology qualifier type code@endif of this CVTerm object.
+ * Sets the @if clike #BiolQualifierType_t value@else biology qualifier type@endif
+ * of this CVTerm object.
*
- * @param type the @if clike #BiolQualifierType_t@endif@if java biology qualifier type code@endif value
+ * @param type the @if clike #BiolQualifierType_t value@else biology qualifier type@endif.
*
* @return integer value indicating success/failure of the
- * function. The possible values
- * returned by this function are:
+ * function. The possible values returned by this function are:
* @li @link OperationReturnValues_t#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS@endlink
* @li @link OperationReturnValues_t#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE@endlink
*
* @note If the Qualifier Type of this object is not
* @link QualifierType_t#BIOLOGICAL_QUALIFIER BIOLOGICAL_QUALIFIER@endlink,
- * then the @if clike #BiolQualifierType_t@endif@if java biology qualifier type code@endif value will default
+ * then the @if clike #BiolQualifierType_t value@else biology qualifier type@endif will default
* to @link BiolQualifierType_t#BQB_UNKNOWN BQB_UNKNOWN@endlink.
*
* @see getQualifierType()
@@ -620,18 +619,18 @@
* together identified uniquely using a URI. The following template
* illustrates the structure:
*
-<DIV class="fragment">
-<rdf:Description rdf:about="#<span style="border-bottom: 1px solid black">meta id</span>"><br>
- <span style="background-color: #ddd; border-bottom: 2px dotted #888">HISTORY</span><br>
- <<span style="background-color: #bbb">RELATION_ELEMENT</span>><br>
- <rdf:Bag><br>
- <rdf:li rdf:resource="<span style="background-color: #d0d0ee">resource URI</span>" /><br>
- <span style="background-color: #edd">...</span><br>
- </rdf:Bag><br>
- </<span style="background-color: #bbb">RELATION_ELEMENT</span>><br>
- <span style="background-color: #edd">...</span><br>
-</rdf:Description><br>
-</div>
+ <DIV class="fragment">
+ <rdf:Description rdf:about="#<span style="border-bottom: 1px solid black">meta id</span>"><br>
+ <span style="background-color: #e0e0e0; border-bottom: 2px dotted #888">HISTORY</span><br>
+ <<span style="background-color: #bbb">RELATION_ELEMENT</span>><br>
+ <rdf:Bag><br>
+ <rdf:li rdf:resource="<span style="background-color: #d0d0ee">resource URI</span>" /><br>
+ <span style="background-color: #edd">...</span><br>
+ </rdf:Bag><br>
+ </<span style="background-color: #bbb">RELATION_ELEMENT</span>><br>
+ <span style="background-color: #edd">...</span><br>
+ </rdf:Description><br>
+ </div>
*
* In the template above, the placeholder <span class="code"
* style="border-bottom: 1px solid black">meta id</span> stands for the
Modified: trunk/libsbml/src/annotation/RDFAnnotation.h
===================================================================
--- trunk/libsbml/src/annotation/RDFAnnotation.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/annotation/RDFAnnotation.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -44,7 +44,7 @@
* RDF-based annotations attached to a given SBML
* <code><annotation></code> element are read by RDFAnnotationParser
* and converted into a list of CVTerm objects. There
- * are different versions of the main method, @if clike RDFAnnotationParser::parseRDFAnnotation(const XMLNode *annotation, %List *CVTerms) @endif@if java RDFAnnotationParser::parseRDFAnnotation(const XMLNode *annotation, CVTermList *CVTerms) @endif
+ * are different versions of the main method, @if clike RDFAnnotationParser::parseRDFAnnotation(const XMLNode *annotation, %List *CVTerms) @else RDFAnnotationParser::parseRDFAnnotation(const XMLNode *annotation, CVTermList *CVTerms) @endif
* and RDFAnnotationParser::parseRDFAnnotation(const XMLNode *annotation),
* used depending on whether the annotation in question concerns the MIRIAM
* model history or other MIRIAM resource annotations. A special object
@@ -128,7 +128,7 @@
int success; // Status code variable, used below.
XMLNode *RDF = createRDFAnnotation(); // Create RDF annotation XML structure.
-success = RDF->addChild(content); // Put some content into it.
+success = RDF->addChild(...content...); // Put some content into it.
... // Check "success" return code value.
XMLNode *ann = createAnnotation(); // Create <annotation> container.
@@ -138,12 +138,12 @@
success = sbmlObject->setAnnotation(ann); // Set object's annotation to what we built.
... // Check "success" return code value.
@endverbatim
-@endif@if java
+ * @endif@if java
@verbatim
int success; // Status code variable, used below.
XMLNode RDF = createRDFAnnotation(); // Create RDF annotation XML structure.
-success = RDF.addChild(content); // Put some content into it.
+success = RDF.addChild(...content...); // Put some content into it.
... // Check "success" return code value.
XMLNode ann = createAnnotation(); // Create <annotation> container.
@@ -153,7 +153,20 @@
success = sbmlObject.setAnnotation(ann); // Set object's annotation to what we built.
... // Check "success" return code value.
@endverbatim
-@endif
+ * @endif@if python
+@verbatim
+RDF = RDFAnnotationParser.createRDFAnnotation() # Create RDF annotation XML structure.
+success = RDF.addChild(...content...) # Put some content into it.
+... # Check "success" return code value.
+
+annot = RDFAnnotationParser.createAnnotation() # Create <annotation> container.
+success = annot.addChild(RDF) # Put the RDF annotation into it.
+... # Check "success" return code value.
+
+success = sbmlObject.setAnnotation(annot) # Set object's annotation to what we built.
+... # Check "success" return code value.
+@endverbatim
+ * @endif
* The SBML specification contains more information about the format of
* annotations. We urge readers to consult Section 6 of the SBML
* Level 2 (Versions 2–4) and SBML Level 3 specification
@@ -185,7 +198,7 @@
*
* Note that this does not create the containing SBML
* <code><annotation></code> element; the method
- * @if clike createAnnotation()@endif@if java RDFAnnotationParser::createAnnotation()@endif
+ * @if clike createAnnotation()@else RDFAnnotationParser::createAnnotation()@endif
* is available for creating the container.
*
* @return a pointer to an XMLNode
@@ -233,7 +246,7 @@
* Note that this method does @em not create a complete annotation or
* even an RDF element; it only creates the "Description" portion. Callers
* will need to use other methods such as
- * @if clike createRDFAnnotation()@endif@if java RDFAnnotationParser::createRDFAnnotation()@endif
+ * @if clike createRDFAnnotation()@else RDFAnnotationParser::createRDFAnnotation()@endif
* to create the rest of the structure for an annotation.
*
* @param object the object to which the "Description" refers
@@ -252,7 +265,7 @@
*
* This essentially takes the given SBML object, reads out the CVTerm objects
* attached to it, calls
- * @if clike createRDFDescription()@endif@if java RDFAnnotationParser::createRDFDescription(SBase object)@endif
+ * @if clike createRDFDescription()@else RDFAnnotationParser::createRDFDescription(SBase object)@endif
* to create an RDF "Description" element to hold the terms and adds
* each term with appropriate qualifiers.
*
@@ -269,13 +282,13 @@
* around it.
*
* This essentially takes the given SBML object, calls
- * @if clike RDFAnnotationParser::createCVTerms()@endif@if java RDFAnnotationParser::createCVTerms(SBase object)@endif
+ * @if clike RDFAnnotationParser::createCVTerms()@else RDFAnnotationParser::createCVTerms(SBase object)@endif
* to read out the CVTerm objects
* attached to it, calls
- * @if clike createRDFAnnotation()@endif@if java RDFAnnotationParser::createRDFAnnotation()@endif
+ * @if clike createRDFAnnotation()@else RDFAnnotationParser::createRDFAnnotation()@endif
* to create an RDF
* annotation to hold the terms, and finally calls
- * @if clike createAnnotation()@endif@if java RDFAnnotationParser::createAnnotation()@endif
+ * @if clike createAnnotation()@else RDFAnnotationParser::createAnnotation()@endif
* to wrap the result as an SBML <code><annotation></code> element.
*
* @param object the SBML object to start from
Modified: trunk/libsbml/src/math/ASTNode.h
===================================================================
--- trunk/libsbml/src/math/ASTNode.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/math/ASTNode.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -80,7 +80,7 @@
*
*
* @if clike <h3><a class="anchor" name="ASTNodeType_t">
- * ASTNodeType_t</a></h3> @endif@if java <h3><a class="anchor"
+ * ASTNodeType_t</a></h3> @else <h3><a class="anchor"
* name="ASTNodeType_t">The set of possible %ASTNode types</a></h3> @endif
*
* @if clike Every ASTNode has an associated type code to indicate,
@@ -89,7 +89,7 @@
* @link ASTNode.h::ASTNodeType_t ASTNodeType_t@endlink. The list of
* possible types is quite long, because it covers all the mathematical
* functions that are permitted in SBML. The values are shown in the
- * following table: @endif@if java Every ASTNode has an associated
+ * following table: @else Every ASTNode has an associated
* type code to indicate, for example, whether it holds a number or stands for
* an arithmetic operator. The type is recorded as a value drawn from a
* set of static integer constants defined in the class {@link
@@ -142,8 +142,8 @@
*
* <h3><a class="anchor" name="math-convert">Converting between ASTs and text strings</a></h3>
*
- * The text-string form of mathematical formulas produced by @if clike SBML_formulaToString()@endif@if java <code><a href="libsbml.html#formulaToString(org.sbml.libsbml.ASTNode)">libsbml.formulaToString()</a></code>@endif and
- * read by @if clike SBML_parseFormula()@endif@if java <code><a href="libsbml.html#parseFormula(java.lang.String)">libsbml.parseFormula()</a></code>@endif
+ * The text-string form of mathematical formulas produced by @if clike SBML_formulaToString()@else <code><a href="libsbml.html#formulaToString(org.sbml.libsbml.ASTNode)">libsbml.formulaToString()</a></code>@endif and
+ * read by @if clike SBML_parseFormula()@else <code><a href="libsbml.html#parseFormula(java.lang.String)">libsbml.parseFormula()</a></code>@endif
* are simple C-inspired infix notation taken from SBML Level 1. A
* formula in this text-string form can be handed to a program that
* understands SBML Level 1 mathematical expressions, or used as part
@@ -386,10 +386,10 @@
* AST_UNKNOWN@endlink. If the type isn't supplied when caling this
* constructor, the caller should set the node type to something else as
* soon as possible using
- * @if clike setType()@endif@if java ASTNode::setType(int)@endif.
+ * @if clike setType()@else ASTNode::setType(int)@endif.
*
* @param type an optional
- * @if clike @link #ASTNodeType_t ASTNodeType_t@endlink@endif@if java type@endif
+ * @if clike @link #ASTNodeType_t ASTNodeType_t@endlink@else type@endif
* code indicating the type of node to create.
*
* @if notcpp @docnote @htmlinclude warn-default-args-in-docs.html @endif
@@ -503,7 +503,7 @@
* render the representation invalid. Callers need to be careful to use
* this method in the context of other operations to create complete and
* correct formulas. The method
- * @if clike isWellFormedASTNode()@endif@if java ASTNode::isWellFormedASTNode()@endif
+ * @if clike isWellFormedASTNode()@else ASTNode::isWellFormedASTNode()@endif
* may also be useful for checking the results of node modifications.
*
* @see prependChild(ASTNode* child)
@@ -631,7 +631,7 @@
*
* @return the nth child of this ASTNode or @c NULL if this node has no nth
* child (<code>n > </code>
- * @if clike getNumChildren()@endif@if java ASTNode::getNumChildren()@endif
+ * @if clike getNumChildren()@else ASTNode::getNumChildren()@endif
* <code>- 1</code>).
*/
LIBSBML_EXTERN
@@ -642,7 +642,7 @@
* Get the left child of this node.
*
* @return the left child of this ASTNode. This is equivalent to calling
- * @if clike getChild()@endif@if java ASTNode::getChild(unsigned int)@endif
+ * @if clike getChild()@else ASTNode::getChild(unsigned int)@endif
* with an argument of @c 0.
*/
LIBSBML_EXTERN
@@ -654,7 +654,7 @@
*
* @return the right child of this ASTNode, or @c NULL if this node has no
* right child. If
- * @if clike getNumChildren()@endif@if java ASTNode::getNumChildren()@endif
+ * @if clike getNumChildren()@else ASTNode::getNumChildren()@endif
* <code>> 1</code>, then this is equivalent to:
* @code
* getChild( getNumChildren() - 1 );
@@ -721,7 +721,7 @@
*
* @return the nth annotation of this ASTNode, or @c NULL if this node has
* no nth annotation (<code>n ></code>
- * @if clike getNumChildren()@endif@if java ASTNode::getNumChildren()@endif
+ * @if clike getNumChildren()@else ASTNode::getNumChildren()@endif
* <code>- 1</code>).
*
* @see ASTNode::addSemanticsAnnotation(XMLNode* sAnnotation)
@@ -789,7 +789,7 @@
/**
* Get the value of this node as a single character. This function
* should be called only when
- * @if clike getType()@endif@if java ASTNode::getType()@endif returns
+ * @if clike getType()@else ASTNode::getType()@endif returns
* @link ASTNodeType_t#AST_PLUS AST_PLUS@endlink,
* @link ASTNodeType_t#AST_MINUS AST_MINUS@endlink,
* @link ASTNodeType_t#AST_TIMES AST_TIMES@endlink,
@@ -805,7 +805,7 @@
/**
* Get the value of this node as an integer. This function should be
* called only when
- * @if clike getType()@endif@if java ASTNode::getType()@endif
+ * @if clike getType()@else ASTNode::getType()@endif
* <code>== @link ASTNodeType_t#AST_INTEGER AST_INTEGER@endlink</code>.
*
* @return the value of this ASTNode as a (<code>long</code>) integer.
@@ -817,9 +817,9 @@
/**
* Get the value of this node as a string. This function may be called
* on nodes that (1) are not operators, i.e., nodes for which
- * @if clike isOperator()@endif@if java ASTNode::isOperator()@endif
+ * @if clike isOperator()@else ASTNode::isOperator()@endif
* returns @c false, and (2) are not numbers, i.e.,
- * @if clike isNumber()@endif@if java ASTNode::isNumber()@endif returns @c false.
+ * @if clike isNumber()@else ASTNode::isNumber()@endif returns @c false.
*
* @return the value of this ASTNode as a string.
*/
@@ -830,7 +830,7 @@
/**
* Get the value of the numerator of this node. This function should be
* called only when
- * @if clike getType()@endif@if java ASTNode::getType()@endif
+ * @if clike getType()@else ASTNode::getType()@endif
* <code>== @link ASTNodeType_t#AST_RATIONAL AST_RATIONAL@endlink</code>.
*
* @return the value of the numerator of this ASTNode.
@@ -842,7 +842,7 @@
/**
* Get the value of the denominator of this node. This function should
* be called only when
- * @if clike getType()@endif@if java ASTNode::getType()@endif
+ * @if clike getType()@else ASTNode::getType()@endif
* <code>== @link ASTNodeType_t#AST_RATIONAL AST_RATIONAL@endlink</code>.
*
* @return the value of the denominator of this ASTNode.
@@ -854,7 +854,7 @@
/**
* Get the real-numbered value of this node. This function
* should be called only when
- * @if clike isReal()@endif@if java ASTNode::isReal()@endif
+ * @if clike isReal()@else ASTNode::isReal()@endif
* <code>== true</code>.
*
* This function performs the necessary arithmetic if the node type is
@@ -870,13 +870,13 @@
/**
* Get the mantissa value of this node. This function should be called
- * only when @if clike getType()@endif@if java ASTNode::getType()@endif
+ * only when @if clike getType()@else ASTNode::getType()@endif
* returns @link ASTNodeType_t#AST_REAL_E AST_REAL_E@endlink
* or @link ASTNodeType_t#AST_REAL AST_REAL@endlink.
- * If @if clike getType()@endif@if java ASTNode::getType()@endif
+ * If @if clike getType()@else ASTNode::getType()@endif
* returns @link ASTNodeType_t#AST_REAL AST_REAL@endlink,
* this method is identical to
- * @if clike getReal()@endif@if java ASTNode::getReal()@endif.
+ * @if clike getReal()@else ASTNode::getReal()@endif.
*
* @return the value of the mantissa of this ASTNode.
*/
@@ -887,7 +887,7 @@
/**
* Get the exponent value of this ASTNode. This function should be
* called only when
- * @if clike getType()@endif@if java ASTNode::getType()@endif
+ * @if clike getType()@else ASTNode::getType()@endif
* returns @link ASTNodeType_t#AST_REAL_E AST_REAL_E@endlink
* or @link ASTNodeType_t#AST_REAL AST_REAL@endlink.
*
@@ -1158,7 +1158,7 @@
*
* For numbers, unary minus nodes can be "collapsed" by negating the
* number. In fact,
- * @if clike SBML_parseFormula()@endif@if java <code><a href="libsbml.html#parseFormula(java.lang.String)">libsbml.parseFormula()</a></code>@endif does this during its parsing process.
+ * @if clike SBML_parseFormula()@else <code><a href="libsbml.html#parseFormula(java.lang.String)">libsbml.parseFormula()</a></code>@endif does this during its parsing process.
* However, unary minus nodes for symbols
* (@link ASTNodeType_t#AST_NAME AST_NAME@endlink) cannot
* be "collapsed", so this predicate function is necessary.
@@ -1242,9 +1242,9 @@
* As a side-effect, this ASTNode object's type will be reset to
* @link ASTNodeType_t#AST_NAME AST_NAME@endlink if (and <em>only
* if</em>) the ASTNode was previously an operator (
- * @if clike isOperator()@endif@if java ASTNode::isOperator()@endif
+ * @if clike isOperator()@else ASTNode::isOperator()@endif
* <code>== true</code>), number (
- * @if clike isNumber()@endif@if java ASTNode::isNumber()@endif
+ * @if clike isNumber()@else ASTNode::isNumber()@endif
* <code>== true</code>), or unknown.
* This allows names to be set for @link ASTNodeType_t#AST_FUNCTION
* AST_FUNCTION@endlink nodes and the like.
@@ -1363,7 +1363,7 @@
* The units will be set @em only if this ASTNode object represents a
* MathML <code><cn></code> element, i.e., represents a number.
* Callers may use
- * @if clike isNumber()@endif@if java ASTNode::isNumber()@endif
+ * @if clike isNumber()@else ASTNode::isNumber()@endif
* to inquire whether the node is of that type.
*
* @htmlinclude about-sbml-units-attrib.html
Modified: trunk/libsbml/src/math/FormulaFormatter.h
===================================================================
--- trunk/libsbml/src/math/FormulaFormatter.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/math/FormulaFormatter.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -51,7 +51,7 @@
* this text-string form therefore can be handed to a program that
* understands SBML Level 1 mathematical expressions, or used as part
* of a formula translation system. The syntax is described in detail in
- * the documentation for ASTNode. @endif@if java The text-string form of
+ * the documentation for ASTNode. @else The text-string form of
* mathematical formulas produced by <code><a
* href="libsbml.html#formulaToString(org.sbml.libsbml.ASTNode)">
* libsbml.formulaToString()</a></code> and read by
Modified: trunk/libsbml/src/math/FormulaParser.h
===================================================================
--- trunk/libsbml/src/math/FormulaParser.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/math/FormulaParser.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -52,7 +52,7 @@
* this text-string form therefore can be handed to a program that
* understands SBML Level 1 mathematical expressions, or used as part
* of a formula translation system. The syntax is described in detail in
- * the documentation for ASTNode. @endif@if java The text-string form of
+ * the documentation for ASTNode. @else The text-string form of
* mathematical formulas produced by <code><a
* href="libsbml.html">libsbml.formulaToString()</a></code> and read by
* <code><a href="libsbml.html">libsbml.parseFormula()</a></code> are
Modified: trunk/libsbml/src/sbml/Compartment.h
===================================================================
--- trunk/libsbml/src/sbml/Compartment.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/sbml/Compartment.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -376,8 +376,7 @@
* (identifier) attribute of a Compartment is required to have a value.
* Thus, callers are cautioned to assign a value after calling this
* constructor. Setting the identifier can be accomplished using the
- * method
- * @if clike setId()@endif@if python setId()@endif@if java Compartment::setId(String id)@endif.
+ * method @if java Compartment::setId(String id)@else setId()@endif.
*
* @param sbmlns an SBMLNamespaces object.
*
@@ -522,14 +521,14 @@
* Get the size of this Compartment.
*
* This method is identical to
- * @if clike getVolume()@endif@if python getVolume()@endif@if java Compartment::getVolume()@endif.
+ * @if java Compartment::getVolume()@else getVolume()@endif.
* In SBML Level 1, compartments are always three-dimensional
* constructs and only have volumes, whereas in SBML Level 2,
* compartments may be other than three-dimensional and therefore the
* "volume" attribute is named "size" in Level 2. LibSBML provides
* both
- * @if clike getSize()@endif@if python getSize()@endif@if java Compartment::getSize()@endif and
- * @if clike getVolume()@endif@if python getVolume()@endif@if java Compartment::getVolume()@endif for
+ * @if java Compartment::getSize()@else getSize()@endif and
+ * @if java Compartment::getVolume()@else getVolume()@endif for
* easier compatibility between SBML Levels.
*
* @return the value of the "size" attribute ("volume" in Level 1) of
@@ -545,14 +544,14 @@
* Get the volume of this Compartment.
*
* This method is identical to
- * @if clike getSize()@endif@if python getSize()@endif@if java Compartment::getSize()@endif. In
+ * @if java Compartment::getSize()@else getSize()@endif. In
* SBML Level 1, compartments are always three-dimensional
* constructs and only have volumes, whereas in SBML Level 2,
* compartments may be other than three-dimensional and therefore the
* "volume" attribute is named "size" in Level 2. LibSBML provides
* both
- * @if clike getSize()@endif@if python getSize()@endif@if java Compartment::getSize()@endif and
- * @if clike getVolume()@endif@if python getVolume()@endif@if java Compartment::getVolume()@endif
+ * @if java Compartment::getSize()@else getSize()@endif and
+ * @if java Compartment::getVolume()@else getVolume()@endif
* for easier compatibility between SBML Levels.
*
* @return the value of the "volume" attribute ("size" in Level 2) of
@@ -581,7 +580,7 @@
* @note @htmlinclude unassigned-units-are-not-a-default.html
*
* @see isSetUnits()
- * @see @if clike setUnits()@endif@if python setUnits()@endif@if java Compartment::setUnits(String sid)@endif
+ * @see @if java Compartment::setUnits(String sid)@else setUnits()@endif
* @see getSize()
*/
const std::string& getUnits () const;
@@ -647,14 +646,12 @@
* Compartment's "size" attribute is set.
*
* This method is similar but not identical to
- * @if clike isSetVolume()@endif@if python isSetVolume()@endif@if java Compartment::isSetVolume()@endif. The latter
+ * @if java Compartment::isSetVolume()@else isSetVolume()@endif. The latter
* should be used in the context of SBML Level 1 models instead of
- * @if clike isSetSize()@endif@if python isSetSize()@endif@if java Compartment::isSetSize()@endif
- * because
- * @if clike isSetVolume()@endif@if python isSetVolume()@endif@if java Compartment::isSetVolume()@endif
- * performs extra processing to take
- * into account the difference in default values between SBML Levels 1
- * and 2.
+ * @if java Compartment::isSetSize()@else isSetSize()@endif
+ * because @if java Compartment::isSetVolume()@else isSetVolume()@endif
+ * performs extra processing to take into account the difference in
+ * default values between SBML Levels 1 and 2.
*
* @return @c true if the "size" attribute ("volume" in Level 2) of
* this Compartment is set, @c false otherwise.
@@ -670,7 +667,7 @@
* "volume" attribute is set.
*
* This method is similar but not identical to
- * @if clike isSetSize()@endif@if python isSetSize()@endif@if java Compartment::isSetSize()@endif. The latter
+ * @if java Compartment::isSetSize()@else isSetSize()@endif. The latter
* should not be used in the context of SBML Level 1 models because this
* method performs extra processing to take into account
* the difference in default values between SBML Levels 1 and 2.
@@ -687,7 +684,7 @@
* therefore may or may not be set.
*
* @see isSetSize()
- * @see @if clike setVolume()@endif@if python setVolume()@endif@if java Compartment::setVolume(double value)@endif
+ * @see @if java Compartment::setVolume(double value)@else setVolume()@endif
*/
bool isSetVolume () const;
@@ -831,7 +828,7 @@
* Compartment.
*
* This method is identical to
- * @if clike setVolume()@endif@if python setVolume()@endif@if java Compartment::setVolume(double value)@endif
+ * @if java Compartment::setVolume(double value)@else setVolume()@endif
* and is provided for compatibility between
* SBML Level 1 and Level 2.
*
@@ -855,7 +852,7 @@
* Compartment.
*
* This method is identical to
- * @if clike setVolume()@endif@if python setVolume()@endif@if java Compartment::setVolume(double value)@endif
+ * @if java Compartment::setVolume(double value)@else setVolume()@endif
* and is provided for compatibility between SBML Level 1 and
* Level 2.
*
@@ -1050,7 +1047,7 @@
*
* Note that unit declarations for Compartment objects are specified in
* terms of the @em identifier of a unit (e.g., using
- * @if clike setUnits()@endif@if python setUnits()@endif@if java Compartment::setUnits(String sid)@endif), but
+ * @if java Compartment::setUnits(String sid)@else setUnits()@endif), but
* @em this method returns a UnitDefinition object, not a unit
* identifier. It does this by constructing an appropriate
* UnitDefinition. For SBML Level 2 models, it will do this even
Modified: trunk/libsbml/src/sbml/CompartmentType.h
===================================================================
--- trunk/libsbml/src/sbml/CompartmentType.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/sbml/CompartmentType.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -172,7 +172,7 @@
* (identifier) attribute of a CompartmentType is required to have a value.
* Thus, callers are cautioned to assign a value after calling this
* constructor. Setting the identifier can be accomplished using the
- * method @if clike setId() @endif@if python setId() @endif@if java setId(String id) @endif.
+ * method setId(@if java String id@endif).
*
* @param sbmlns an SBMLNamespaces object.
*
Modified: trunk/libsbml/src/sbml/InitialAssignment.h
===================================================================
--- trunk/libsbml/src/sbml/InitialAssignment.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/sbml/InitialAssignment.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -400,7 +400,7 @@
* The units are calculated based on the mathematical expression in the
* InitialAssignment and the model quantities referenced by
* <code><ci></code> elements used within that expression. The
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java InitialAssignment::getDerivedUnitDefinition()@endif
+ * @if java InitialAssignment::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* method returns the calculated units.
*
* Note that the functionality that facilitates unit analysis depends
@@ -413,13 +413,13 @@
* units. In those cases, it is not possible to calculate the units of
* the overall expression without making assumptions. LibSBML does not
* make assumptions about the units, and
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java InitialAssignment::getDerivedUnitDefinition()@endif
+ * @if java InitialAssignment::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* only returns the units as far as it is able to determine them. For
* example, in an expression <em>X + Y</em>, if <em>X</em> has
* unambiguously-defined units and <em>Y</em> does not, it will return
* the units of <em>X</em>. <strong>It is important that callers also
* invoke the method</strong>
- * @if clike containsUndeclaredUnits()@endif@if python containsUndeclaredUnits()@endif@if java InitialAssignment::containsUndeclaredUnits()@endif
+ * @if java InitialAssignment::containsUndeclaredUnits()@else containsUndeclaredUnits()@endif
* <strong>to determine whether this situation holds</strong>. Callers
* may wish to take suitable actions in those scenarios.
*
@@ -439,7 +439,7 @@
* The units are calculated based on the mathematical expression in the
* InitialAssignment and the model quantities referenced by
* <code><ci></code> elements used within that expression. The
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java InitialAssignment::getDerivedUnitDefinition()@endif
+ * @if java InitialAssignment::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* method returns the calculated units.
*
* Note that the functionality that facilitates unit analysis depends
@@ -452,13 +452,13 @@
* units. In those cases, it is not possible to calculate the units of
* the overall expression without making assumptions. LibSBML does not
* make assumptions about the units, and
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java InitialAssignment::getDerivedUnitDefinition()@endif
+ * @if java InitialAssignment::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* only returns the units as far as it is able to determine them. For
* example, in an expression <em>X + Y</em>, if <em>X</em> has
* unambiguously-defined units and <em>Y</em> does not, it will return
* the units of <em>X</em>. <strong>It is important that callers also
* invoke the method</strong>
- * @if clike containsUndeclaredUnits()@endif@if python containsUndeclaredUnits()@endif@if java InitialAssignment::containsUndeclaredUnits()@endif
+ * @if java InitialAssignment::containsUndeclaredUnits()@else containsUndeclaredUnits()@endif
* <strong>to determine whether this situation holds</strong>. Callers
* may wish to take suitable actions in those scenarios.
*
@@ -481,7 +481,7 @@
*
* @note A return value of @c true indicates that the UnitDefinition
* returned by
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java InitialAssignment::getDerivedUnitDefinition()@endif
+ * @if java InitialAssignment::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* may not accurately represent the units of the expression.
*
* @see getDerivedUnitDefinition()
@@ -500,7 +500,7 @@
*
* @note A return value of @c true indicates that the UnitDefinition
* returned by
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java InitialAssignment::getDerivedUnitDefinition()@endif
+ * @if java InitialAssignment::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* may not accurately represent the units of the expression.
*
* @see getDerivedUnitDefinition()
Modified: trunk/libsbml/src/sbml/KineticLaw.h
===================================================================
--- trunk/libsbml/src/sbml/KineticLaw.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/sbml/KineticLaw.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -226,7 +226,7 @@
* it as as a text string.
*
* This is fundamentally equivalent to
- * @if clike getMath()@endif@if python getMath()@endif@if java KineticLaw::getMath()@endif.
+ * @if java KineticLaw::getMath()@else getMath()@endif.
* This variant is provided principally for compatibility compatibility
* with SBML Level 1.
*
@@ -244,7 +244,7 @@
* it as as an AST.
*
* This is fundamentally equivalent to
- * @if clike getFormula()@endif@if python getFormula()@endif@if java KineticLaw::getFormula()@endif.
+ * @if java KineticLaw::getFormula()@else getFormula()@endif.
* The latter is provided principally for compatibility compatibility
* with SBML Level 1, which represented mathematical formulas in
* text-string form.
@@ -291,10 +291,10 @@
* KineticLaw's "formula" attribute is set.
*
* This is functionally identical to the method
- * @if clike isSetMath()@endif@if python isSetMath()@endif@if java KineticLaw::isSetMath()@endif. It is
+ * @if java KineticLaw::isSetMath()@else isSetMath()@endif. It is
* provided in order to mirror the parallel between
- * @if clike getFormula()@endif@if python getFormula()@endif@if java KineticLaw::getFormula()@endif and
- * @if clike getMath()@endif@if python getMath()@endif@if java KineticLaw::getMath()@endif.
+ * @if java KineticLaw::getFormula()@else getFormula()@endif and
+ * @if java KineticLaw::getMath()@else getMath()@endif.
*
* @return @c true if the formula (meaning the @c math subelement) of
* this KineticLaw is set, @c false otherwise.
@@ -311,10 +311,10 @@
* Kinetic's "math" subelement is set.
*
* This is identical to the method
- * @if clike isSetFormula()@endif@if python isSetFormula()@endif@if java KineticLaw::isSetFormula()@endif.
+ * @if java KineticLaw::isSetFormula()@else isSetFormula()@endif.
* It is provided in order to mirror the parallel between
- * @if clike getFormula()@endif@if python getFormula()@endif@if java KineticLaw::getFormula()@endif and
- * @if clike getMath()@endif@if python getMath()@endif@if java KineticLaw::getMath()@endif.
+ * @if java KineticLaw::getFormula()@else getFormula()@endif and
+ * @if java KineticLaw::getMath()@else getMath()@endif.
*
* @return @c true if the formula (meaning the @c math subelement) of
* this KineticLaw is set, @c false otherwise.
@@ -384,7 +384,7 @@
* of the given ASTNode.
*
* This is fundamentally identical to
- * @if clike getFormula()@endif@if python getFormula()@endif@if java KineticLaw::setFormula(String formula)@endif.
+ * @if java KineticLaw::setFormula(String formula)@else getFormula()@endif.
* The latter is provided principally for compatibility compatibility with
* SBML Level 1, which represented mathematical formulas in text-string
* form.
@@ -511,7 +511,7 @@
* instance in the KineticLaw</em>. In addition, the caller should make
* sure to free the original object if it is no longer being used, or
* else a memory leak will result. Please see
- * @if clike createParameter()@endif@if python createParameter()@endif@if java KineticLaw::createParameter()@endif
+ * @if java KineticLaw::createParameter()@else createParameter()@endif
* for a method that does not lead to these issues.
*
* @see createParameter()
@@ -543,7 +543,7 @@
* instance in the KineticLaw</em>. In addition, the caller should make
* sure to free the original object if it is no longer being used, or
* else a memory leak will result. Please see
- * @if clike createParameter()@endif@if python createParameter()@endif@if java KineticLaw::createParameter()@endif
+ * @if java KineticLaw::createParameter()@else createParameter()@endif
* for a method that does not lead to these issues.
*
* @see createLocalParameter()
@@ -717,7 +717,7 @@
* The units are calculated based on the mathematical expression in the
* KineticLaw and the model quantities referenced by
* <code><ci></code> elements used within that expression. The
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java KineticLaw::getDerivedUnitDefinition()@endif
+ * @if java KineticLaw::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* method returns the calculated units.
*
* Note that the functionality that facilitates unit analysis depends
@@ -730,13 +730,13 @@
* units. In those cases, it is not possible to calculate the units of
* the overall expression without making assumptions. LibSBML does not
* make assumptions about the units, and
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java KineticLaw::getDerivedUnitDefinition()@endif
+ * @if java KineticLaw::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* only returns the units as far as it is able to determine them. For
* example, in an expression <em>X + Y</em>, if <em>X</em> has
* unambiguously-defined units and <em>Y</em> does not, it will return
* the units of <em>X</em>. <strong>It is important that callers also
* invoke the method</strong>
- * @if clike containsUndeclaredUnits()@endif@if java KineticLaw::containsUndeclaredUnits()@endif
+ * @if java KineticLaw::containsUndeclaredUnits()@else containsUndeclaredUnits()@endif
* <strong>to determine whether this situation holds</strong>. Callers may
* wish to take suitable actions in those scenarios.
*
@@ -756,7 +756,7 @@
* The units are calculated based on the mathematical expression in the
* KineticLaw and the model quantities referenced by
* <code><ci></code> elements used within that expression. The
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java KineticLaw::getDerivedUnitDefinition()@endif
+ * @if java KineticLaw::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* method returns the calculated units.
*
* Note that the functionality that facilitates unit analysis depends
@@ -769,13 +769,13 @@
* units. In those cases, it is not possible to calculate the units of
* the overall expression without making assumptions. LibSBML does not
* make assumptions about the units, and
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java KineticLaw::getDerivedUnitDefinition()@endif
+ * @if java KineticLaw::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* only returns the units as far as it is able to determine them. For
* example, in an expression <em>X + Y</em>, if <em>X</em> has
* unambiguously-defined units and <em>Y</em> does not, it will return
* the units of <em>X</em>. <strong>It is important that callers also
* invoke the method</strong>
- * @if clike containsUndeclaredUnits()@endif@if java KineticLaw::containsUndeclaredUnits()@endif
+ * @if java KineticLaw::containsUndeclaredUnits()@else containsUndeclaredUnits()@endif
* <strong>to determine whether this situation holds</strong>. Callers
* may wish to take suitable actions in those scenarios.
*
@@ -798,7 +798,7 @@
*
* @note A return value of @c true indicates that the UnitDefinition
* returned by
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java KineticLaw::getDerivedUnitDefinition()@endif
+ * @if java KineticLaw::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* may not accurately represent the units of the expression.
*
* @see getDerivedUnitDefinition()
@@ -817,7 +817,7 @@
*
* @note A return value of @c true indicates that the UnitDefinition
* returned by
- * @if clike getDerivedUnitDefinition()@endif@if python getDerivedUnitDefinition()@endif@if java KineticLaw::getDerivedUnitDefinition()@endif
+ * @if java KineticLaw::getDerivedUnitDefinition()@else getDerivedUnitDefinition()@endif
* may not accurately represent the units of the expression.
*
* @see getDerivedUnitDefinition()
Modified: trunk/libsbml/src/sbml/LocalParameter.h
===================================================================
--- trunk/libsbml/src/sbml/LocalParameter.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/sbml/LocalParameter.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -201,7 +201,7 @@
* Thus, callers are cautioned to assign a value after calling this
* constructor if no identifier is provided as an argument. Setting the
* identifier can be accomplished using the method
- * @if clike setId()@endif@if python setId()@endif@if java setId(String id)@endif.
+ * @if java setId(String id)@else setId()@endif.
*
* @param sbmlns an SBMLNamespaces object.
*
Modified: trunk/libsbml/src/sbml/Model.h
===================================================================
--- trunk/libsbml/src/sbml/Model.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/sbml/Model.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -94,7 +94,8 @@
* @section approaches Approaches to creating objects using the libSBML API
*
* LibSBML provides two main mechanisms for creating objects: class
- * constructors (e.g., @if clike @link Species::Species() Species() @endlink @endif@if python @link Species::Species() Species() @endlink @endif@if java <a href="org/sbml/libsbml/Species.html">Species()</a> @endif),
+ * constructors
+ * (e.g., @if java <a href="org/sbml/libsbml/Species.html">Species()</a> @else Species::Species() @endif),
* and <code>create<span class="placeholder"><em>Object</em></span>()</code>
* methods (such as Model::createSpecies()) provided by certain <span
* class="placeholder"><em>Object</em></span> classes such as Model. These
@@ -127,7 +128,7 @@
Species *sp = model->createSpecies();
sp->setId("MySpecies");
@endverbatim
-@endif@if java
+ * @endif@if java
@verbatim
// Create an SBMLDocument object in Level 3 Version 1 format:
@@ -149,7 +150,7 @@
Species sp = model.createSpecies();
sp.setId("BestSpeciesEver");
@endverbatim
-@endif
+ * @endif
*
* The <code>create<span
* class="placeholder"><em>Object</em></span>()</code> methods return a
@@ -183,7 +184,7 @@
delete newsp;
@endverbatim
-@endif@if java
+ * @endif@if java
@verbatim
// Create a Species object and add it to the model.
// This uses the Species class constructor:
@@ -197,14 +198,14 @@
newsp.setId("NewId"); // Warning -- doesn't change the species in 'model'!
@endverbatim
-@endif
+ * @endif
*
- * The key point of the example above is that, because the @if clike Model::addSpecies() @endif@if python Model::addSpecies() @endif@if java Model::addSpecies(Species s) @endif
+ * The key point of the example above is that, because the
+ * @if java Model::addSpecies(Species s)@else Model::addSpecies()@endif
* call makes a copy of the object handed to it, care is needed
- * @if clike both when
- * attempting to make changes to the object, and when the original object
- * is no longer needed.@endif@if java when
- * attempting to make changes to the object.@endif
+ * @if clike both when attempting to make changes to the object, and when
+ * the original object is no longer needed.@else when attempting to make
+ * changes to the object.@endif
*
* @section checking Consistency and adherence to SBML specifications
*
Modified: trunk/libsbml/src/sbml/Parameter.h
===================================================================
--- trunk/libsbml/src/sbml/Parameter.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/sbml/Parameter.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -229,7 +229,7 @@
* Thus, callers are cautioned to assign a value after calling this
* constructor if no identifier is provided as an argument. Setting the
* identifier can be accomplished using the method
- * @if clike setId()@endif@if python setId()@endif@if java setId(String id)@endif.
+ * @if java setId(String id)@else setId()@endif.
*
* @param sbmlns an SBMLNamespaces object.
*
Modified: trunk/libsbml/src/sbml/Rule.h
===================================================================
--- trunk/libsbml/src/sbml/Rule.h 2011-02-27 05:14:17 UTC (rev 13062)
+++ trunk/libsbml/src/sbml/Rule.h 2011-02-27 05:16:27 UTC (rev 13063)
@@ -174,7 +174,7 @@
* Level 3 for distinguishing rules; specifically, it uses an
* attribute whose value is drawn from an enumeration of 3 values. LibSBML
* supports this using methods that work @if clike a libSBML enumeration
- * type, #RuleType_t, whose values are @endif@if notcpp with the enumeration
+ * type, #RuleType_t, whose values are @else with the enumeration
* values @endif listed in the following table.
*
* <p>
@@ -367,7 +367,7 @@
* Level 3 for distinguishing rules; specifically, it uses an
* attribute whose value is drawn from an enumeration of 3 values. LibSBML
* supports this using methods that work @if clike a libSBML enumeration
- * type, #RuleType_t, whose values are @endif@if notcpp with the enumeration
+ * type, #RuleType_t, whose values are @else with the enumeration
* values @endif listed in the following table.
*
* <p>
@@ -604,7 +604,7 @@
* Level 3 for distinguishing rules; specifically, it uses an
* attribute whose value is drawn from an enumeration of 3 values. LibSBML
* supports thi...
[truncated message content] |
|
From: <mh...@us...> - 2011-02-27 05:14:23
|
Revision: 13062
http://sbml.svn.sourceforge.net/sbml/?rev=13062&view=rev
Author: mhucka
Date: 2011-02-27 05:14:17 +0000 (Sun, 27 Feb 2011)
Log Message:
-----------
Changed convention for sections that are enabled for
different languages. No longer using 'notcpp' to mean anything other than c
and c++, and instead using it to mean solely not c++. Also introduced
'notclike' to mean not c or c++ instead, as the opposite of the
existing 'clike'.
Modified Paths:
--------------
trunk/libsbml/docs/src/doxygen-config-c.txt.in
trunk/libsbml/docs/src/doxygen-config-perl.txt.in
trunk/libsbml/docs/src/doxygen-config-python.txt.in
Modified: trunk/libsbml/docs/src/doxygen-config-c.txt.in
===================================================================
--- trunk/libsbml/docs/src/doxygen-config-c.txt.in 2011-02-27 05:10:26 UTC (rev 13061)
+++ trunk/libsbml/docs/src/doxygen-config-c.txt.in 2011-02-27 05:14:17 UTC (rev 13062)
@@ -42,7 +42,7 @@
# The ENABLED_SECTIONS tag can be used to enable conditional
# documentation sections, marked by \if sectionname ... \endif.
-ENABLED_SECTIONS = doxygen-c-only doxygen-clike-only notcpp
+ENABLED_SECTIONS = doxygen-c-only doxygen-clike-only clike conly
# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum
# is documented as struct, union, or enum with the name of the typedef. So
Modified: trunk/libsbml/docs/src/doxygen-config-perl.txt.in
===================================================================
--- trunk/libsbml/docs/src/doxygen-config-perl.txt.in 2011-02-27 05:10:26 UTC (rev 13061)
+++ trunk/libsbml/docs/src/doxygen-config-perl.txt.in 2011-02-27 05:14:17 UTC (rev 13062)
@@ -89,7 +89,7 @@
# The ENABLED_SECTIONS tag can be used to enable conditional
# documentation sections, marked by \if sectionname ... \endif.
-ENABLED_SECTIONS = notcpp doxygen-perl-only
+ENABLED_SECTIONS = perl notclike doxygen-perl-only
BRIEF_MEMBER_DESC = YES
Modified: trunk/libsbml/docs/src/doxygen-config-python.txt.in
===================================================================
--- trunk/libsbml/docs/src/doxygen-config-python.txt.in 2011-02-27 05:10:26 UTC (rev 13061)
+++ trunk/libsbml/docs/src/doxygen-config-python.txt.in 2011-02-27 05:14:17 UTC (rev 13062)
@@ -61,7 +61,7 @@
# The ENABLED_SECTIONS tag can be used to enable conditional
# documentation sections, marked by \if sectionname ... \endif.
-ENABLED_SECTIONS = notcpp doxygen-python-only python
+ENABLED_SECTIONS = python notclike doxygen-python-only
# Because of how we construct the Python documentation, we don't want
# the first sentence to be assumed to be the brief description.
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <mh...@us...> - 2011-02-27 05:10:33
|
Revision: 13061
http://sbml.svn.sourceforge.net/sbml/?rev=13061&view=rev
Author: mhucka
Date: 2011-02-27 05:10:26 +0000 (Sun, 27 Feb 2011)
Log Message:
-----------
1) Rewrote handling of @if ... @endif to handle @else.
2) Made the 'language' variable global to avoid having to pass it around
all over the place. This is especially useful for functions called for
regex sub(), where arguments aren't possible.
Modified Paths:
--------------
trunk/libsbml/src/bindings/swig/swigdoc.py
Modified: trunk/libsbml/src/bindings/swig/swigdoc.py
===================================================================
--- trunk/libsbml/src/bindings/swig/swigdoc.py 2011-02-26 23:53:09 UTC (rev 13060)
+++ trunk/libsbml/src/bindings/swig/swigdoc.py 2011-02-27 05:10:26 UTC (rev 13061)
@@ -38,6 +38,7 @@
# Globally-scoped variables
#
+language = ''
docincpath = ''
libsbmlclasses = ["AlgebraicRule",
"ASTNode",
@@ -124,8 +125,8 @@
- functions
"""
- def __init__ (self, forLanguage, stream):
- """CHeader (forLanguage, stream=None) -> CHeader
+ def __init__ (self, stream):
+ """CHeader (stream=None) -> CHeader
Creates a new CHeader reading from the given stream.
"""
@@ -134,10 +135,10 @@
self.classDocs = [ ]
if stream is not None:
- self.read(forLanguage, stream)
+ self.read(stream)
- def read (self, forLanguage, stream):
+ def read (self, stream):
"""read (PushBackStream)
Reads a C/C++ header file from the given stream.
@@ -165,8 +166,8 @@
# Track things that we flag as internal, so that we can
# remove them from the documentation.
- if (stripped.find('@cond doxygen-libsbml-internal') >= 0): isInternal = True
- if (stripped.find('@endcond') >= 0): isInternal = False
+ if (stripped.find('@cond doxygen-libsbml-internal') >= 0): isInternal = True
+ if (stripped.find('@endcond') >= 0): isInternal = False
# Watch for class description, usually at top of file.
@@ -264,7 +265,7 @@
# Swig doesn't seem to mind C++ argument lists, even though they
# have "const", "&", etc. So I'm leaving the arg list unmodified.
- func = Method(forLanguage, isInternal, docstring, name, args, (isConst > 0))
+ func = Method(isInternal, docstring, name, args, (isConst > 0))
if inClass:
c = self.classes[-1]
@@ -301,7 +302,6 @@
"""A Method encapsulates a C/C++ function. Currently, it has the
following public attributes:
- - forLanguage
- isInternal
- docstring
- name
@@ -309,11 +309,11 @@
- isConst
"""
- def __init__ (self, forLanguage, isInternal, docstring, name, args, isConst):
- """Method(forLanguage, isInternal, docstring name, args, isConst) -> Method
+ def __init__ (self, isInternal, docstring, name, args, isConst):
+ """Method(isInternal, docstring name, args, isConst) -> Method
Creates a new Method description with the given docstring, name and args,
- for the language forLanguage, with special consideration if the method
+ for the language, with special consideration if the method
was declared constant and/or internal.
"""
@@ -321,7 +321,7 @@
self.isConst = isConst
if isInternal:
- if forLanguage == 'java':
+ if language == 'java':
# This is a hack, but Javadoc offers no way of selectively omitting
# documentation from the output, so this is the most straightforward
# and unobtrusive approach I've found. The following flags our
@@ -348,7 +348,7 @@
# combination doesn't seem to arise in libSBML currently, and anyway,
# this fixes a real problem in the Java documentation for libSBML.
- if forLanguage == 'java':
+ if language == 'java':
if isConst and (args.find('unsigned int') >= 0):
self.args = ''
elif not args.strip() == '()':
@@ -429,8 +429,8 @@
-def rewriteCommonReferences (docstring, language):
- """rewriteCommonReferences (docstring, language) -> docstring
+def rewriteCommonReferences (docstring):
+ """rewriteCommonReferences (docstring) -> docstring
Rewrites common C++ doxygen references to match language-specific needs.
"""
@@ -495,35 +495,21 @@
return content
-def translateIfJava (match):
- text = match.group()
- if match.group(1) == 'java' or match.group(1) == 'notcpp':
- text = match.group(2)
- else:
- text = ''
- return text
-
-def translateIfPerl (match):
+def translateIfElse (match):
text = match.group()
- if match.group(1) == 'perl' or match.group(1) == 'notcpp':
+ if match.group(1) == language or \
+ match.group(1) == 'notcpp' or \
+ match.group(1) == 'notclike':
text = match.group(2)
+ elif match.group(4) == '@else':
+ text = match.group(5)
else:
text = ''
return text
-def translateIfPython (match):
- text = match.group()
- if match.group(1) == 'python' or match.group(1) == 'notcpp':
- text = match.group(2)
- else:
- text = ''
- return text
-
-
-
def translateJavaCrossRef (match):
prior = match.group(1)
classname = match.group(2)
@@ -571,22 +557,30 @@
-def sanitizeForHTML (docstring, language):
- """sanitizeForHTML (docstring, language) -> docstring
+def sanitizeForHTML (docstring):
+ """sanitizeForHTML (docstring) -> docstring
Performs HTML transformations on the C++/Doxygen docstring.
"""
# First do conditional section inclusion based on the current language.
- # This ONLY handles @if foo @endif, not @if foo @else bar @endif.
+ # Our possible conditional elements and their meanings are:
+ #
+ # java: only Java
+ # python: only Python
+ # perl: only Perl
+ # cpp: only C++
+ # conly: only C
+ # clike: C, C++
+ # notcpp: not C++
+ # notclike: not C or C++
+ #
+ # The notcpp/notclike variants are because Doxygen 1.6.x doesn't have
+ # @ifnot, yet sometimes we want to say "if not C or C++".
- p = re.compile('@if\s+(java|python|perl|clike|notcpp)\s+(.+?)@endif', re.DOTALL)
- if language == 'java':
- docstring = p.sub(translateIfJava, docstring)
- elif language == 'perl':
- docstring = p.sub(translateIfPerl, docstring)
- elif language == 'python':
- docstring = p.sub(translateIfPython, docstring)
+ cases = 'java|python|perl|cpp|conly|clike|notcpp|notclike'
+ p = re.compile('@if\s+(' + cases + ')\s+(.+?)((@else)\s+(.+?))?@endif', re.DOTALL)
+ docstring = p.sub(translateIfElse, docstring)
# Replace blank lines between paragraphs with <p>. There are two main
# cases: comments blocks whose lines always begin with an asterix (e.g.,
@@ -696,7 +690,7 @@
C++/Doxygen docstring.
"""
- docstring = rewriteCommonReferences(docstring, 'java')
+ docstring = rewriteCommonReferences(docstring)
# Preliminary: rewrite some of the data type references to equivalent
# Java types. (Note: this rewriting affects only the documentation
@@ -720,7 +714,7 @@
# Do the big work.
- docstring = sanitizeForHTML(docstring, 'java')
+ docstring = sanitizeForHTML(docstring)
# Fix up for a problem introduced by sanitizeForHTML -- should fix
# properly some day.
@@ -789,7 +783,7 @@
more elaborate filter that processes the output of *this* filter.
"""
- docstring = rewriteCommonReferences(docstring, 'python')
+ docstring = rewriteCommonReferences(docstring)
docstring = docstring.replace('/**', '').replace('*/', '')
p = re.compile('^(\s*)\*([ \t]*)', re.MULTILINE)
@@ -853,7 +847,7 @@
C++/Doxygen docstring.
"""
- docstring = rewriteCommonReferences(docstring, 'perl')
+ docstring = rewriteCommonReferences(docstring)
# Get rid of the /** ... */ and leading *'s.
docstring = docstring.replace('/**', '').replace('*/', '').replace('*', ' ')
@@ -898,7 +892,7 @@
-def processClassMethods(ostream, language, cclass):
+def processClassMethods(ostream, cclass):
# In the Python docs, we have to combine the docstring for methods with
# different signatures and write out a single method docstring. In the
# other languages, we write out separate docstrings for every method
@@ -927,7 +921,7 @@
docstring += rewriteDocstringForPython(mm.docstring)
else:
docstring = rewriteDocstringForPython(m.docstring)
- ostream.write(formatMethodDocString(language, m.name, cclass.name, docstring, m.args))
+ ostream.write(formatMethodDocString(m.name, cclass.name, docstring, m.args))
written[m.name + m.args] = 1
else: # Not python
for m in cclass.methods:
@@ -937,13 +931,13 @@
docstring = rewriteDocstringForJava(m.docstring)
elif language == 'perl':
docstring = rewriteDocstringForPerl(m.docstring)
- ostream.write(formatMethodDocString(language, m.name, cclass.name, docstring, m.args))
+ ostream.write(formatMethodDocString(m.name, cclass.name, docstring, m.args))
ostream.flush()
-def formatMethodDocString (language, methodname, classname, docstring, args=None):
+def formatMethodDocString (methodname, classname, docstring, args=None):
if language == 'java':
pre = '%javamethodmodifiers'
post = ' public'
@@ -970,18 +964,18 @@
-def generateFunctionDocString (language, methodname, docstring, args):
+def generateFunctionDocString (methodname, docstring, args):
if language == 'java':
doc = rewriteDocstringForJava(docstring)
elif language == 'python':
doc = rewriteDocstringForPython(docstring)
elif language == 'perl':
doc = rewriteDocstringForPerl(docstring)
- return formatMethodDocString(language, methodname, None, doc, args)
+ return formatMethodDocString(methodname, None, doc, args)
-def generateClassDocString (language, docstring, classname):
+def generateClassDocString (docstring, classname):
if language == 'java':
pre = '%typemap(javaimports) '
docstring = rewriteDocstringForJava(docstring)
@@ -1000,26 +994,26 @@
-def processClasses (ostream, classes, language):
+def processClasses (ostream, classes):
for c in classes:
- processClassMethods(ostream, language, c)
+ processClassMethods(ostream, c)
-def processFunctions (ostream, functions, language):
+def processFunctions (ostream, functions):
for f in functions:
- ostream.write(generateFunctionDocString(language, f.name, f.docstring, f.args))
+ ostream.write(generateFunctionDocString(f.name, f.docstring, f.args))
-def processClassDocs (ostream, classDocs, language):
+def processClassDocs (ostream, classDocs):
for c in classDocs:
- ostream.write(generateClassDocString(language, c.docstring, c.name))
+ ostream.write(generateClassDocString(c.docstring, c.name))
-def processFile (filename, ostream, language):
- """processFile (filename, ostream, language='java'|'python')
+def processFile (filename, ostream):
+ """processFile (filename, ostream)
Reads the the given header file and writes to ostream the necessary SWIG
incantation to annotate each method (or function) with a docstring
@@ -1027,12 +1021,12 @@
"""
istream = open(filename)
- header = CHeader(language, istream)
+ header = CHeader(istream)
istream.close()
- processClassDocs(ostream, header.classDocs, language)
- processClasses(ostream, header.classes, language)
- processFunctions(ostream, header.functions, language)
+ processClassDocs(ostream, header.classDocs)
+ processClasses(ostream, header.classes)
+ processFunctions(ostream, header.functions)
ostream.flush()
@@ -1052,6 +1046,7 @@
sys.exit(1)
global docincpath
+ global language
language = args[1]
includepath = args[2].replace('-I', '')
@@ -1068,7 +1063,7 @@
for file in headers:
filename = os.path.normpath(os.path.join(includepath, file))
- processFile(filename, stream, language)
+ processFile(filename, stream)
if language == 'perl':
stream.write('=cut\n')
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-26 23:53:15
|
Revision: 13060
http://sbml.svn.sourceforge.net/sbml/?rev=13060&view=rev
Author: fbergmann
Date: 2011-02-26 23:53:09 +0000 (Sat, 26 Feb 2011)
Log Message:
-----------
- need to copy layout include files to install directory when compiled with_layout
Modified Paths:
--------------
trunk/libsbml/src/CMakeLists.txt
Modified: trunk/libsbml/src/CMakeLists.txt
===================================================================
--- trunk/libsbml/src/CMakeLists.txt 2011-02-26 22:46:09 UTC (rev 13059)
+++ trunk/libsbml/src/CMakeLists.txt 2011-02-26 23:53:09 UTC (rev 13060)
@@ -83,6 +83,8 @@
if (WITH_LAYOUT)
copy_files( ${CMAKE_CURRENT_SOURCE_DIR}/sbml/layout
${CMAKE_CURRENT_SOURCE_DIR}/../include/sbml/layout *.h )
+ file(GLOB layout_files "${CMAKE_CURRENT_SOURCE_DIR}/sbml/layout/*.h" )
+ install(FILES ${layout_files} DESTINATION include/sbml/layout)
endif()
FILE(GLOB files "${CMAKE_CURRENT_SOURCE_DIR}/sbml/*.h")
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-26 22:46:16
|
Revision: 13059
http://sbml.svn.sourceforge.net/sbml/?rev=13059&view=rev
Author: fbergmann
Date: 2011-02-26 22:46:09 +0000 (Sat, 26 Feb 2011)
Log Message:
-----------
- remove warnings from cmake files
Modified Paths:
--------------
trunk/libsbml/CMakeLists.txt
trunk/libsbml/src/bindings/matlab/FindMatlab.cmake
trunk/libsbml/src/util/List.cpp
Modified: trunk/libsbml/CMakeLists.txt
===================================================================
--- trunk/libsbml/CMakeLists.txt 2011-02-26 18:57:13 UTC (rev 13058)
+++ trunk/libsbml/CMakeLists.txt 2011-02-26 22:46:09 UTC (rev 13059)
@@ -402,10 +402,10 @@
)
if(UNIX)
else()
- if (${CMAKE_SIZEOF_VOID_P} EQUAL 4)
+ if (CMAKE_SIZEOF_VOID_P EQUAL 4)
# mark libsbml library as x86
set(CSHARP_EXTRA_ARGS -platform:x86 )
- elseif(${CMAKE_SIZEOF_VOID_P} EQUAL 8)
+ elseif(CMAKE_SIZEOF_VOID_P EQUAL 8)
# mark libsbml library as x64
set(CSHARP_EXTRA_ARGS -platform:x64 )
endif()
Modified: trunk/libsbml/src/bindings/matlab/FindMatlab.cmake
===================================================================
--- trunk/libsbml/src/bindings/matlab/FindMatlab.cmake 2011-02-26 18:57:13 UTC (rev 13058)
+++ trunk/libsbml/src/bindings/matlab/FindMatlab.cmake 2011-02-26 22:46:09 UTC (rev 13059)
@@ -52,7 +52,7 @@
endif()
endif()
else()
- if (${CMAKE_SIZEOF_VOID_P} EQUAL 4)
+ if (CMAKE_SIZEOF_VOID_P EQUAL 4)
if (EXISTS "C:/Program Files (x86)/MATLAB/R2010b")
set(MATLAB_ROOT_PATH "C:/Program Files (x86)/MATLAB/R2010b")
elseif (EXISTS "C:/Program Files (x86)/MATLAB/R2010a")
@@ -136,7 +136,7 @@
# unfortunately this won't find matlab R2010b on my machine
if (NOT "${MATLAB_ROOT}")
SET(MATLAB_MEX_COMMAND "${MATLAB_ROOT_PATH}/bin/mex.bat")
- if (${CMAKE_SIZEOF_VOID_P} EQUAL 4)
+ if (CMAKE_SIZEOF_VOID_P EQUAL 4)
SET(MATLAB_ROOT "${MATLAB_ROOT_PATH}/extern/lib/win32/microsoft/")
else()
SET(MATLAB_ROOT "${MATLAB_ROOT_PATH}/extern/lib/win64/microsoft/")
Modified: trunk/libsbml/src/util/List.cpp
===================================================================
--- trunk/libsbml/src/util/List.cpp 2011-02-26 18:57:13 UTC (rev 13058)
+++ trunk/libsbml/src/util/List.cpp 2011-02-26 22:46:09 UTC (rev 13059)
@@ -79,6 +79,8 @@
void
List::add (void *item)
{
+ if (item == NULL) return;
+
ListNode* node = new ListNode(item);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-26 18:57:19
|
Revision: 13058
http://sbml.svn.sourceforge.net/sbml/?rev=13058&view=rev
Author: fbergmann
Date: 2011-02-26 18:57:13 +0000 (Sat, 26 Feb 2011)
Log Message:
-----------
- add files to generate the python installers
Added Paths:
-----------
trunk/libsbml/dev/utilities/win_installer/python/
trunk/libsbml/dev/utilities/win_installer/python/libsbml.pth
trunk/libsbml/dev/utilities/win_installer/python/setup.py
Added: trunk/libsbml/dev/utilities/win_installer/python/libsbml.pth
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/python/libsbml.pth (rev 0)
+++ trunk/libsbml/dev/utilities/win_installer/python/libsbml.pth 2011-02-26 18:57:13 UTC (rev 13058)
@@ -0,0 +1 @@
+libsbml
Added: trunk/libsbml/dev/utilities/win_installer/python/setup.py
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/python/setup.py (rev 0)
+++ trunk/libsbml/dev/utilities/win_installer/python/setup.py 2011-02-26 18:57:13 UTC (rev 13058)
@@ -0,0 +1,64 @@
+## @file setup.py
+## @brief Python distutils code for libSBML Python module
+## @author Michael Hucka
+## @author Ben Bornstein
+## @author Ben Kovitz
+## @author Frank Bergmann (fbe...@ca...)
+##
+## $Id$
+## $HeadURL$
+##
+##<!---------------------------------------------------------------------------
+## This file is part of libSBML. Please visit http://sbml.org for more
+## information about SBML, and the latest version of libSBML.
+##
+## Copyright 2005-2010 California Institute of Technology.
+## Copyright 2002-2005 California Institute of Technology and
+## Japan Science and Technology Corporation.
+##
+## This library is free software; you can redistribute it and/or modify it
+## under the terms of the GNU Lesser General Public License as published by
+## the Free Software Foundation. A copy of the license agreement is provided
+## in the file named "LICENSE.txt" included with this software distribution
+## and also available online as http://sbml.org/software/libsbml/license.html
+##----------------------------------------------------------------------- -->*/
+
+import platform
+
+# figure out whether this is a 64bit or 32 bit installation
+basepath = '../../../win64/'
+if platform.uname()[4] == 'x86':
+ basepath = '../../../win32/'
+
+from distutils.core import setup, Extension
+
+setup(name = "libsbml",
+ version = "4.3.0",
+ description = "LibSBML Python API",
+ long_description = ("LibSBML is a library for reading, writing and "+
+ "manipulating the Systems Biology Markup Language "+
+ "(SBML). It is written in ISO C and C++, supports "+
+ "SBML Levels 1, 2 and 3, and runs on Linux, Microsoft "+
+ "Windows, and Apple MacOS X. For more information "+
+ "about SBML, please see http://sbml.org."),
+ license = "LGPL",
+ author = "SBML Team",
+ author_email = "lib...@ca...",
+ url = "http://sbml.org",
+ packages = ["libsbml"],
+ package_dir = {'libsbml': 'libsbml'},
+ data_files = [('Lib/site-packages/libsbml', [basepath + 'bin/libsbml.dll']),
+ ('Lib/site-packages', ['libsbml.pth'])],
+ ext_package = "libsbml",
+ ext_modules = [Extension("_libsbml",
+ sources = [ "libsbml_wrap.cpp"],
+ define_macros = [('WIN32', None),
+ ('USE_LAYOUT', None),
+ ('LIBSBML_EXPORTS', None)],
+ include_dirs = [basepath + "include",
+ basepath + "include/sbml", "."],
+ libraries = ["libsbml"],
+ library_dirs = [basepath + "lib"]
+ )
+ ]
+)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-26 01:24:21
|
Revision: 13057
http://sbml.svn.sourceforge.net/sbml/?rev=13057&view=rev
Author: fbergmann
Date: 2011-02-26 01:24:15 +0000 (Sat, 26 Feb 2011)
Log Message:
-----------
- fix path settings to avoid warnings (another warning was issued)
Modified Paths:
--------------
trunk/libsbml/win/msvc9/expat/libsbml_csharp.vcproj
Modified: trunk/libsbml/win/msvc9/expat/libsbml_csharp.vcproj
===================================================================
--- trunk/libsbml/win/msvc9/expat/libsbml_csharp.vcproj 2011-02-26 01:10:59 UTC (rev 13056)
+++ trunk/libsbml/win/msvc9/expat/libsbml_csharp.vcproj 2011-02-26 01:24:15 UTC (rev 13057)
@@ -16,7 +16,7 @@
<Configurations>
<Configuration
Name="Debug|Win32"
- OutputDirectory="../../bin/csharp/"
+ OutputDirectory="..\..\bin\csharp\"
IntermediateDirectory=".\Debug"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
@@ -78,14 +78,14 @@
<Tool
Name="VCLinkerTool"
AdditionalDependencies="zdll.lib bzip2.lib libexpat.lib"
- OutputFile="libsbmlcsD.dll"
+ OutputFile="$(OutDir)\libsbmlcsD.dll"
LinkIncremental="2"
SuppressStartupBanner="true"
GenerateDebugInformation="true"
- ProgramDatabaseFile="libsbmlcsD.pdb"
+ ProgramDatabaseFile="$(OutDir)\libsbmlcsD.pdb"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
- ImportLibrary="libsbmlcsD.lib"
+ ImportLibrary="$(OutDir)\libsbmlcsD.lib"
TargetMachine="1"
/>
<Tool
@@ -113,7 +113,7 @@
</Configuration>
<Configuration
Name="Release|Win32"
- OutputDirectory="../../bin/csharp/"
+ OutputDirectory="..\..\bin\csharp\"
IntermediateDirectory=".\Release"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
@@ -178,13 +178,13 @@
<Tool
Name="VCLinkerTool"
AdditionalDependencies="zdll.lib bzip2.lib libexpat.lib"
- OutputFile="libsbmlcs.dll"
+ OutputFile="$(OutDir)\libsbmlcs.dll"
LinkIncremental="2"
SuppressStartupBanner="true"
- ProgramDatabaseFile="libsbmlcs.pdb"
+ ProgramDatabaseFile="$(OutDir)\libsbmlcs.pdb"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
- ImportLibrary="libsbmlcs.lib"
+ ImportLibrary="$(OutDir)\libsbmlcs.lib"
TargetMachine="1"
/>
<Tool
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-26 01:11:05
|
Revision: 13056
http://sbml.svn.sourceforge.net/sbml/?rev=13056&view=rev
Author: fbergmann
Date: 2011-02-26 01:10:59 +0000 (Sat, 26 Feb 2011)
Log Message:
-----------
- fix path settings to avoid warnings like:
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppBuild.targets(990,5): warning MSB8012: TargetPath(libsbml_csharp.dll) does not match the Linker's OutputFile property value (libsbmlcs.dll). This may cause your project to build incorrectly. To correct this, please make sure that $(OutDir), $(TargetName) and $(TargetExt) property values match the value specified in %(Link.OutputFile).
Modified Paths:
--------------
trunk/libsbml/win/msvc9/expat/libsbml_csharp.vcproj
Modified: trunk/libsbml/win/msvc9/expat/libsbml_csharp.vcproj
===================================================================
--- trunk/libsbml/win/msvc9/expat/libsbml_csharp.vcproj 2011-02-26 00:43:16 UTC (rev 13055)
+++ trunk/libsbml/win/msvc9/expat/libsbml_csharp.vcproj 2011-02-26 01:10:59 UTC (rev 13056)
@@ -2,7 +2,7 @@
<VisualStudioProject
ProjectType="Visual C++"
Version="9.00"
- Name="libsbml_csharp"
+ Name="libsbmlcs"
ProjectGUID="{5AA48709-30C4-433C-B29B-EE09F618A1C3}"
TargetFrameworkVersion="131072"
>
@@ -16,7 +16,7 @@
<Configurations>
<Configuration
Name="Debug|Win32"
- OutputDirectory=".\bin"
+ OutputDirectory="../../bin/csharp/"
IntermediateDirectory=".\Debug"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
@@ -78,14 +78,14 @@
<Tool
Name="VCLinkerTool"
AdditionalDependencies="zdll.lib bzip2.lib libexpat.lib"
- OutputFile="../../bin/csharp/libsbmlcsD.dll"
+ OutputFile="libsbmlcsD.dll"
LinkIncremental="2"
SuppressStartupBanner="true"
GenerateDebugInformation="true"
- ProgramDatabaseFile=".\bin/libsbmlcsD.pdb"
+ ProgramDatabaseFile="libsbmlcsD.pdb"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
- ImportLibrary="../../bin/csharp/libsbmlcsD.lib"
+ ImportLibrary="libsbmlcsD.lib"
TargetMachine="1"
/>
<Tool
@@ -113,7 +113,7 @@
</Configuration>
<Configuration
Name="Release|Win32"
- OutputDirectory="..\bin"
+ OutputDirectory="../../bin/csharp/"
IntermediateDirectory=".\Release"
ConfigurationType="2"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
@@ -178,13 +178,13 @@
<Tool
Name="VCLinkerTool"
AdditionalDependencies="zdll.lib bzip2.lib libexpat.lib"
- OutputFile="../../bin/csharp/libsbmlcs.dll"
+ OutputFile="libsbmlcs.dll"
LinkIncremental="2"
SuppressStartupBanner="true"
- ProgramDatabaseFile=".\bin/csharp.pdb"
+ ProgramDatabaseFile="libsbmlcs.pdb"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
- ImportLibrary="../../bin/csharp/libsbmlcs.lib"
+ ImportLibrary="libsbmlcs.lib"
TargetMachine="1"
/>
<Tool
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-26 00:43:23
|
Revision: 13055
http://sbml.svn.sourceforge.net/sbml/?rev=13055&view=rev
Author: fbergmann
Date: 2011-02-26 00:43:16 +0000 (Sat, 26 Feb 2011)
Log Message:
-----------
- exclude new test from being translated
Modified Paths:
--------------
trunk/libsbml/dev/utilities/translateTests/translateTests.pl
Modified: trunk/libsbml/dev/utilities/translateTests/translateTests.pl
===================================================================
--- trunk/libsbml/dev/utilities/translateTests/translateTests.pl 2011-02-26 00:32:46 UTC (rev 13054)
+++ trunk/libsbml/dev/utilities/translateTests/translateTests.pl 2011-02-26 00:43:16 UTC (rev 13055)
@@ -221,6 +221,35 @@
test_SBMLNamespaces_invalid => 0,
test_SBase_addCVTerms_num_check => 0,
test_SBase_appendNotesWithGlobalNamespace => 0,
+ test_AlgebraicRule_accessWithNULL => 0,
+ test_Compartment_accessWithNULL => 0,
+ test_CompartmentType_accessWithNULL => 0,
+ test_Constraint_accessWithNULL => 0,
+ test_Delay_accessWithNULL => 0,
+ test_Event_accessWithNULL => 0,
+ test_EventAssignment_accessWithNULL => 0,
+ test_FunctionDefinition_accessWithNULL => 0,
+ test_InitialAssignment_accessWithNULL => 0,
+ test_KineticLaw_accessWithNULL => 0,
+ test_L3_LocalParameter_accessWithNULL => 0,
+ test_ListOf_accessWithNULL => 0,
+ test_Model_accessWithNULL => 0,
+ test_Parameter_accessWithNULL => 0,
+ test_Priority_accessWithNULL => 0,
+ test_Reaction_accessWithNULL => 0,
+ test_ReadSBML_accessWithNULL => 0,
+ test_SBMLDocument_accessWithNULL => 0,
+ test_SBMLNamespaces_accessWithNULL => 0,
+ test_SBase_accessWithNULL => 0,
+ test_Species_accessWithNULL => 0,
+ test_SpeciesReference_accessWithNULL => 0,
+ test_SpeciesType_accessWithNULL => 0,
+ test_StoichiometryMath_accessWithNULL => 0,
+ test_SyntaxChecker_accessWithNULL => 0,
+ test_Trigger_accessWithNULL => 0,
+ test_Unit_accessWithNULL => 0,
+ test_UnitDefinition_accessWithNULL => 0,
+ test_WriteSBML_accessWithNULL => 0,
);
######################################################################
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-26 00:32:55
|
Revision: 13054
http://sbml.svn.sourceforge.net/sbml/?rev=13054&view=rev
Author: fbergmann
Date: 2011-02-26 00:32:46 +0000 (Sat, 26 Feb 2011)
Log Message:
-----------
- added tests that access SBML elements with NULL
Modified Paths:
--------------
trunk/libsbml/src/sbml/Compartment.cpp
trunk/libsbml/src/sbml/CompartmentType.cpp
trunk/libsbml/src/sbml/Constraint.cpp
trunk/libsbml/src/sbml/Delay.cpp
trunk/libsbml/src/sbml/Event.cpp
trunk/libsbml/src/sbml/EventAssignment.cpp
trunk/libsbml/src/sbml/FunctionDefinition.cpp
trunk/libsbml/src/sbml/InitialAssignment.cpp
trunk/libsbml/src/sbml/KineticLaw.cpp
trunk/libsbml/src/sbml/ListOf.cpp
trunk/libsbml/src/sbml/LocalParameter.cpp
trunk/libsbml/src/sbml/LocalParameter.h
trunk/libsbml/src/sbml/Model.cpp
trunk/libsbml/src/sbml/Rule.cpp
trunk/libsbml/src/sbml/SBMLWriter.cpp
trunk/libsbml/src/sbml/Species.cpp
trunk/libsbml/src/sbml/SpeciesReference.cpp
trunk/libsbml/src/sbml/SpeciesType.cpp
trunk/libsbml/src/sbml/StoichiometryMath.cpp
trunk/libsbml/src/sbml/SyntaxChecker.cpp
trunk/libsbml/src/sbml/Trigger.cpp
trunk/libsbml/src/sbml/Unit.cpp
trunk/libsbml/src/sbml/test/TestAlgebraicRule.c
trunk/libsbml/src/sbml/test/TestCompartment.c
trunk/libsbml/src/sbml/test/TestCompartmentType.c
trunk/libsbml/src/sbml/test/TestConstraint.c
trunk/libsbml/src/sbml/test/TestDelay.c
trunk/libsbml/src/sbml/test/TestEvent.c
trunk/libsbml/src/sbml/test/TestEventAssignment.c
trunk/libsbml/src/sbml/test/TestFunctionDefinition.c
trunk/libsbml/src/sbml/test/TestInitialAssignment.c
trunk/libsbml/src/sbml/test/TestKineticLaw.c
trunk/libsbml/src/sbml/test/TestL3LocalParameter.c
trunk/libsbml/src/sbml/test/TestListOf.c
trunk/libsbml/src/sbml/test/TestModel.c
trunk/libsbml/src/sbml/test/TestModifierSpeciesReference.c
trunk/libsbml/src/sbml/test/TestParameter.c
trunk/libsbml/src/sbml/test/TestPriority.c
trunk/libsbml/src/sbml/test/TestReaction.c
trunk/libsbml/src/sbml/test/TestReadSBML.cpp
trunk/libsbml/src/sbml/test/TestSBMLDocument.c
trunk/libsbml/src/sbml/test/TestSBMLError.cpp
trunk/libsbml/src/sbml/test/TestSBMLNamespaces.cpp
trunk/libsbml/src/sbml/test/TestSBase.cpp
trunk/libsbml/src/sbml/test/TestSpecies.c
trunk/libsbml/src/sbml/test/TestSpeciesReference.c
trunk/libsbml/src/sbml/test/TestSpeciesType.c
trunk/libsbml/src/sbml/test/TestStoichiometryMath.c
trunk/libsbml/src/sbml/test/TestSyntaxChecker.c
trunk/libsbml/src/sbml/test/TestTrigger.c
trunk/libsbml/src/sbml/test/TestUnit.c
trunk/libsbml/src/sbml/test/TestUnitDefinition.c
trunk/libsbml/src/sbml/test/TestWriteSBML.cpp
Modified: trunk/libsbml/src/sbml/Compartment.cpp
===================================================================
--- trunk/libsbml/src/sbml/Compartment.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/Compartment.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -1811,6 +1811,7 @@
void
Compartment_free (Compartment_t *c)
{
+ if (c != NULL)
delete c;
}
Modified: trunk/libsbml/src/sbml/CompartmentType.cpp
===================================================================
--- trunk/libsbml/src/sbml/CompartmentType.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/CompartmentType.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -690,6 +690,7 @@
void
CompartmentType_free (CompartmentType_t *ct)
{
+ if (ct != NULL)
delete ct;
}
Modified: trunk/libsbml/src/sbml/Constraint.cpp
===================================================================
--- trunk/libsbml/src/sbml/Constraint.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/Constraint.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -794,6 +794,7 @@
void
Constraint_free (Constraint_t *c)
{
+ if (c != NULL)
delete c;
}
Modified: trunk/libsbml/src/sbml/Delay.cpp
===================================================================
--- trunk/libsbml/src/sbml/Delay.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/Delay.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -698,6 +698,7 @@
void
Delay_free (Delay_t *t)
{
+ if (t != NULL)
delete t;
}
Modified: trunk/libsbml/src/sbml/Event.cpp
===================================================================
--- trunk/libsbml/src/sbml/Event.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/Event.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -1847,6 +1847,7 @@
void
Event_free (Event_t *e)
{
+ if (e != NULL)
delete e;
}
Modified: trunk/libsbml/src/sbml/EventAssignment.cpp
===================================================================
--- trunk/libsbml/src/sbml/EventAssignment.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/EventAssignment.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -919,6 +919,7 @@
void
EventAssignment_free (EventAssignment_t *ea)
{
+ if (ea != NULL)
delete ea;
}
Modified: trunk/libsbml/src/sbml/FunctionDefinition.cpp
===================================================================
--- trunk/libsbml/src/sbml/FunctionDefinition.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/FunctionDefinition.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -992,6 +992,7 @@
void
FunctionDefinition_free (FunctionDefinition_t *fd)
{
+ if (fd != NULL)
delete fd;
}
Modified: trunk/libsbml/src/sbml/InitialAssignment.cpp
===================================================================
--- trunk/libsbml/src/sbml/InitialAssignment.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/InitialAssignment.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -913,6 +913,7 @@
void
InitialAssignment_free (InitialAssignment_t *ia)
{
+ if (ia != NULL)
delete ia;
}
Modified: trunk/libsbml/src/sbml/KineticLaw.cpp
===================================================================
--- trunk/libsbml/src/sbml/KineticLaw.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/KineticLaw.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -1568,6 +1568,7 @@
void
KineticLaw_free (KineticLaw_t *kl)
{
+ if (kl != NULL)
delete kl;
}
Modified: trunk/libsbml/src/sbml/ListOf.cpp
===================================================================
--- trunk/libsbml/src/sbml/ListOf.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/ListOf.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -559,6 +559,7 @@
void
ListOf_free (ListOf_t *lo)
{
+ if (lo != NULL)
delete lo;
}
@@ -638,6 +639,7 @@
void
ListOf_clear (ListOf_t *lo, int doDelete)
{
+ if (lo != NULL)
lo->clear(doDelete);
}
Modified: trunk/libsbml/src/sbml/LocalParameter.cpp
===================================================================
--- trunk/libsbml/src/sbml/LocalParameter.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/LocalParameter.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -557,6 +557,7 @@
void
LocalParameter_free (LocalParameter_t *p)
{
+ if (p != NULL)
delete p;
}
Modified: trunk/libsbml/src/sbml/LocalParameter.h
===================================================================
--- trunk/libsbml/src/sbml/LocalParameter.h 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/LocalParameter.h 2011-02-26 00:32:46 UTC (rev 13054)
@@ -681,9 +681,9 @@
LocalParameter_clone (const LocalParameter_t *p);
-LIBSBML_EXTERN
-void
-LocalParameter_initDefaults (LocalParameter_t *p);
+//LIBSBML_EXTERN
+//void
+//LocalParameter_initDefaults (LocalParameter_t *p);
LIBSBML_EXTERN
@@ -711,9 +711,9 @@
LocalParameter_getUnits (const LocalParameter_t *p);
-LIBSBML_EXTERN
-int
-LocalParameter_getConstant (const LocalParameter_t *p);
+//LIBSBML_EXTERN
+//int
+//LocalParameter_getConstant (const LocalParameter_t *p);
LIBSBML_EXTERN
@@ -756,11 +756,11 @@
LocalParameter_setUnits (LocalParameter_t *p, const char *units);
-LIBSBML_EXTERN
-int
-LocalParameter_setConstant (LocalParameter_t *p, int value);
+//LIBSBML_EXTERN
+//int
+//LocalParameter_setConstant (LocalParameter_t *p, int value);
+//
-
LIBSBML_EXTERN
int
LocalParameter_unsetName (LocalParameter_t *p);
Modified: trunk/libsbml/src/sbml/Model.cpp
===================================================================
--- trunk/libsbml/src/sbml/Model.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/Model.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -5718,6 +5718,7 @@
void
Model_free (Model_t *m)
{
+ if (m != NULL)
delete m;
}
Modified: trunk/libsbml/src/sbml/Rule.cpp
===================================================================
--- trunk/libsbml/src/sbml/Rule.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/Rule.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -1968,6 +1968,7 @@
void
Rule_free (Rule_t *r)
{
+ if (r != NULL)
delete r;
}
Modified: trunk/libsbml/src/sbml/SBMLWriter.cpp
===================================================================
--- trunk/libsbml/src/sbml/SBMLWriter.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/SBMLWriter.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -344,6 +344,7 @@
void
SBMLWriter_free (SBMLWriter_t *sw)
{
+ if (sw != NULL)
delete sw;
}
@@ -488,7 +489,7 @@
SBMLWriter_writeSBMLToString (SBMLWriter_t *sw, const SBMLDocument_t *d)
{
if (sw == NULL || d == NULL)
- return 0;
+ return NULL;
else
return sw->writeToString(d);
}
Modified: trunk/libsbml/src/sbml/Species.cpp
===================================================================
--- trunk/libsbml/src/sbml/Species.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/Species.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -2044,6 +2044,7 @@
void
Species_free (Species_t *s)
{
+ if (s != NULL)
delete s;
}
Modified: trunk/libsbml/src/sbml/SpeciesReference.cpp
===================================================================
--- trunk/libsbml/src/sbml/SpeciesReference.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/SpeciesReference.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -2389,6 +2389,7 @@
void
SpeciesReference_free (SpeciesReference_t *sr)
{
+ if (sr != NULL)
delete sr;
}
Modified: trunk/libsbml/src/sbml/SpeciesType.cpp
===================================================================
--- trunk/libsbml/src/sbml/SpeciesType.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/SpeciesType.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -690,6 +690,7 @@
void
SpeciesType_free (SpeciesType_t *st)
{
+ if (st != NULL)
delete st;
}
Modified: trunk/libsbml/src/sbml/StoichiometryMath.cpp
===================================================================
--- trunk/libsbml/src/sbml/StoichiometryMath.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/StoichiometryMath.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -606,6 +606,7 @@
void
StoichiometryMath_free (StoichiometryMath_t *stoichMath)
{
+ if (stoichMath != NULL)
delete stoichMath;
}
Modified: trunk/libsbml/src/sbml/SyntaxChecker.cpp
===================================================================
--- trunk/libsbml/src/sbml/SyntaxChecker.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/SyntaxChecker.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -1895,8 +1895,8 @@
int
SyntaxChecker_isValidSBMLSId(const char * sid)
{
- return static_cast<int>((sid == NULL) ?
- SyntaxChecker::isValidSBMLSId("") : SyntaxChecker::isValidSBMLSId(sid));
+ if (sid == NULL) return 1;
+ return static_cast<int>(SyntaxChecker::isValidSBMLSId(sid));
}
Modified: trunk/libsbml/src/sbml/Trigger.cpp
===================================================================
--- trunk/libsbml/src/sbml/Trigger.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/Trigger.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -742,6 +742,7 @@
void
Trigger_free (Trigger_t *t)
{
+ if (t != NULL)
delete t;
}
Modified: trunk/libsbml/src/sbml/Unit.cpp
===================================================================
--- trunk/libsbml/src/sbml/Unit.cpp 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/Unit.cpp 2011-02-26 00:32:46 UTC (rev 13054)
@@ -2105,6 +2105,7 @@
void
Unit_free (Unit_t *u)
{
+ if (u != NULL)
delete u;
}
Modified: trunk/libsbml/src/sbml/test/TestAlgebraicRule.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestAlgebraicRule.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestAlgebraicRule.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -158,7 +158,47 @@
}
END_TEST
+START_TEST (test_AlgebraicRule_accessWithNULL)
+{
+ fail_unless (Rule_clone(NULL) == NULL);
+ fail_unless (Rule_containsUndeclaredUnits(NULL) == 0);
+ fail_unless (Rule_createAlgebraicWithNS(NULL) == NULL);
+ fail_unless (Rule_createAssignmentWithNS(NULL) == NULL);
+ fail_unless (Rule_createRateWithNS(NULL) == NULL);
+
+ Rule_free(NULL);
+ fail_unless (Rule_getDerivedUnitDefinition(NULL) == NULL);
+ fail_unless (Rule_getFormula(NULL) == NULL);
+ fail_unless (Rule_getL1TypeCode(NULL) == SBML_UNKNOWN);
+ fail_unless (Rule_getMath(NULL) == NULL);
+ fail_unless (Rule_getNamespaces(NULL) == NULL);
+ fail_unless (Rule_getType(NULL) == RULE_TYPE_INVALID);
+ fail_unless (Rule_getTypeCode(NULL) == SBML_UNKNOWN);
+ fail_unless (Rule_getUnits(NULL) == NULL);
+ fail_unless (Rule_getVariable(NULL) == NULL);
+ fail_unless (Rule_isAlgebraic(NULL) == 0);
+ fail_unless (Rule_isAssignment(NULL) == 0);
+ fail_unless (Rule_isCompartmentVolume(NULL) == 0);
+ fail_unless (Rule_isParameter(NULL) == 0);
+ fail_unless (Rule_isRate(NULL) == 0);
+ fail_unless (Rule_isScalar(NULL) == 0);
+ fail_unless (Rule_isSetFormula(NULL) == 0);
+ fail_unless (Rule_isSetMath(NULL) == 0);
+ fail_unless (Rule_isSetUnits(NULL) == 0);
+ fail_unless (Rule_isSetVariable(NULL) == 0);
+ fail_unless (Rule_isSpeciesConcentration(NULL) == 0);
+ fail_unless (Rule_setFormula(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless (Rule_setL1TypeCode(NULL, SBML_UNKNOWN) == LIBSBML_INVALID_OBJECT);
+ fail_unless (Rule_setMath(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless (Rule_setUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless (Rule_setVariable(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless (Rule_setVariable(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+
+}
+END_TEST
+
+
Suite *
create_suite_AlgebraicRule (void)
{
@@ -170,11 +210,12 @@
AlgebraicRuleTest_setup,
AlgebraicRuleTest_teardown );
- tcase_add_test( tcase, test_AlgebraicRule_create );
- tcase_add_test( tcase, test_AlgebraicRule_createWithFormula );
- tcase_add_test( tcase, test_AlgebraicRule_createWithMath );
- tcase_add_test( tcase, test_AlgebraicRule_free_NULL );
- tcase_add_test( tcase, test_AlgebraicRule_createWithNS );
+ tcase_add_test( tcase, test_AlgebraicRule_create );
+ tcase_add_test( tcase, test_AlgebraicRule_createWithFormula );
+ tcase_add_test( tcase, test_AlgebraicRule_createWithMath );
+ tcase_add_test( tcase, test_AlgebraicRule_free_NULL );
+ tcase_add_test( tcase, test_AlgebraicRule_createWithNS );
+ tcase_add_test( tcase, test_AlgebraicRule_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestCompartment.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestCompartment.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestCompartment.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -41,6 +41,16 @@
CK_CPPSTART
#endif
+#if WIN32 && !defined(CYGWIN)
+int isnan(double x);
+int isinf(double x);
+int finite(double x);
+#ifndef __DBL_EPSILON__
+#include <float.h>
+#define __DBL_EPSILON__ DBL_EPSILON
+#endif
+#endif
+
static Compartment_t *C;
@@ -368,7 +378,58 @@
}
END_TEST
+START_TEST (test_Compartment_accessWithNULL )
+{
+ fail_unless(Compartment_clone(NULL) == NULL);
+ fail_unless(Compartment_createWithNS(NULL) == NULL);
+ Compartment_free(NULL);
+
+ fail_unless(Compartment_getCompartmentType(NULL) == NULL);
+ fail_unless(Compartment_getConstant(NULL) == 0);
+ fail_unless(Compartment_getDerivedUnitDefinition(NULL) == NULL);
+ fail_unless(Compartment_getId(NULL) == NULL);
+ fail_unless(Compartment_getName(NULL) == NULL);
+ fail_unless(Compartment_getNamespaces(NULL) == NULL);
+ fail_unless(Compartment_getOutside(NULL) == NULL);
+ fail_unless( isnan ( Compartment_getSize(NULL) ));
+ fail_unless(Compartment_getSpatialDimensions(NULL) == SBML_INT_MAX);
+ fail_unless( isnan ( Compartment_getSpatialDimensionsAsDouble(NULL) ));
+ fail_unless(Compartment_getUnits(NULL) == NULL);
+ fail_unless( isnan ( Compartment_getVolume(NULL) ));
+ fail_unless(Compartment_hasRequiredAttributes(NULL) == 0);
+
+ Compartment_initDefaults(NULL);
+
+ fail_unless(Compartment_isSetCompartmentType(NULL) == 0);
+ fail_unless(Compartment_isSetConstant(NULL) == 0);
+ fail_unless(Compartment_isSetId(NULL) == 0);
+ fail_unless(Compartment_isSetName(NULL) == 0);
+ fail_unless(Compartment_isSetOutside(NULL) == 0);
+ fail_unless(Compartment_isSetSize(NULL) == 0);
+ fail_unless(Compartment_isSetSpatialDimensions(NULL) == 0);
+ fail_unless(Compartment_isSetUnits(NULL) == 0);
+ fail_unless(Compartment_isSetVolume(NULL) == 0);
+ fail_unless(Compartment_setCompartmentType(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_setConstant(NULL, 0) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_setId(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_setName(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_setOutside(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_setSize(NULL, 0) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_setSpatialDimensions(NULL, 0) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_setSpatialDimensionsAsDouble(NULL, 0) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_setUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_unsetCompartmentType(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_unsetName(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_unsetOutside(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_unsetSize(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_unsetSpatialDimensions(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_unsetUnits(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Compartment_unsetVolume(NULL) == LIBSBML_INVALID_OBJECT);
+
+}
+END_TEST
+
Suite *
create_suite_Compartment (void)
{
@@ -380,20 +441,21 @@
CompartmentTest_setup,
CompartmentTest_teardown );
- tcase_add_test( tcase, test_Compartment_create );
- tcase_add_test( tcase, test_Compartment_createWith );
- tcase_add_test( tcase, test_Compartment_free_NULL );
- tcase_add_test( tcase, test_Compartment_setId );
- tcase_add_test( tcase, test_Compartment_setName );
- tcase_add_test( tcase, test_Compartment_setUnits );
- tcase_add_test( tcase, test_Compartment_setOutside );
- tcase_add_test( tcase, test_Compartment_unsetSize );
- tcase_add_test( tcase, test_Compartment_unsetVolume );
- tcase_add_test( tcase, test_Compartment_getsetType );
- tcase_add_test( tcase, test_Compartment_getsetConstant );
- tcase_add_test( tcase, test_Compartment_getSpatialDimensions);
- tcase_add_test( tcase, test_Compartment_initDefaults );
+ tcase_add_test( tcase, test_Compartment_create );
+ tcase_add_test( tcase, test_Compartment_createWith );
+ tcase_add_test( tcase, test_Compartment_free_NULL );
+ tcase_add_test( tcase, test_Compartment_setId );
+ tcase_add_test( tcase, test_Compartment_setName );
+ tcase_add_test( tcase, test_Compartment_setUnits );
+ tcase_add_test( tcase, test_Compartment_setOutside );
+ tcase_add_test( tcase, test_Compartment_unsetSize );
+ tcase_add_test( tcase, test_Compartment_unsetVolume );
+ tcase_add_test( tcase, test_Compartment_getsetType );
+ tcase_add_test( tcase, test_Compartment_getsetConstant );
+ tcase_add_test( tcase, test_Compartment_getSpatialDimensions );
+ tcase_add_test( tcase, test_Compartment_initDefaults );
tcase_add_test( tcase, test_Compartment_createWithNS );
+ tcase_add_test( tcase, test_Compartment_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestCompartmentType.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestCompartmentType.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestCompartmentType.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -208,7 +208,24 @@
}
END_TEST
+START_TEST (test_CompartmentType_accessWithNULL )
+{
+ fail_unless( CompartmentType_clone (NULL) == NULL);
+ fail_unless( CompartmentType_createWithNS (NULL) == NULL);
+ CompartmentType_free (NULL);
+
+ fail_unless( CompartmentType_getId (NULL) == NULL);
+ fail_unless( CompartmentType_getName (NULL) == NULL);
+ fail_unless( CompartmentType_getNamespaces (NULL) == NULL);
+ fail_unless( CompartmentType_isSetId (NULL) == 0);
+ fail_unless( CompartmentType_isSetName (NULL) == 0);
+ fail_unless( CompartmentType_setId (NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( CompartmentType_setName (NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( CompartmentType_unsetName (NULL) == LIBSBML_INVALID_OBJECT);
+}
+END_TEST
+
Suite *
create_suite_CompartmentType (void)
{
@@ -220,13 +237,14 @@
CompartmentTypeTest_setup,
CompartmentTypeTest_teardown );
- tcase_add_test( tcase, test_CompartmentType_create );
- //tcase_add_test( tcase, test_CompartmentType_createWith );
- tcase_add_test( tcase, test_CompartmentType_free_NULL );
- tcase_add_test( tcase, test_CompartmentType_setId );
- tcase_add_test( tcase, test_CompartmentType_setName );
- tcase_add_test( tcase, test_CompartmentType_unsetName );
- tcase_add_test( tcase, test_CompartmentType_createWithNS );
+ tcase_add_test( tcase, test_CompartmentType_create );
+ //tcase_add_test( tcase, test_CompartmentType_createWith );
+ tcase_add_test( tcase, test_CompartmentType_free_NULL );
+ tcase_add_test( tcase, test_CompartmentType_setId );
+ tcase_add_test( tcase, test_CompartmentType_setName );
+ tcase_add_test( tcase, test_CompartmentType_unsetName );
+ tcase_add_test( tcase, test_CompartmentType_createWithNS );
+ tcase_add_test( tcase, test_CompartmentType_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestConstraint.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestConstraint.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestConstraint.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -200,7 +200,25 @@
}
END_TEST
+START_TEST (test_Constraint_accessWithNULL )
+{
+ fail_unless( Constraint_clone(NULL) == NULL );
+ fail_unless( Constraint_createWithNS(NULL) == NULL );
+ Constraint_free(NULL);
+
+ fail_unless( Constraint_getMath(NULL) == NULL );
+ fail_unless( Constraint_getMessage(NULL) == NULL );
+ fail_unless( Constraint_getMessageString(NULL) == NULL );
+ fail_unless( Constraint_getNamespaces(NULL) == NULL );
+ fail_unless( Constraint_isSetMath(NULL) == 0);
+ fail_unless( Constraint_isSetMessage(NULL) == 0);
+ fail_unless( Constraint_setMath(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( Constraint_setMessage(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( Constraint_unsetMessage(NULL) == LIBSBML_INVALID_OBJECT);
+}
+END_TEST
+
Suite *
create_suite_Constraint (void)
{
@@ -212,12 +230,13 @@
ConstraintTest_setup,
ConstraintTest_teardown );
- tcase_add_test( tcase, test_Constraint_create );
- //tcase_add_test( tcase, test_Constraint_createWithMath );
- tcase_add_test( tcase, test_Constraint_free_NULL );
- tcase_add_test( tcase, test_Constraint_setMath );
- tcase_add_test( tcase, test_Constraint_setMessage );
- tcase_add_test( tcase, test_Constraint_createWithNS );
+ tcase_add_test( tcase, test_Constraint_create );
+ //tcase_add_test( tcase, test_Constraint_createWithMath );
+ tcase_add_test( tcase, test_Constraint_free_NULL );
+ tcase_add_test( tcase, test_Constraint_setMath );
+ tcase_add_test( tcase, test_Constraint_setMessage );
+ tcase_add_test( tcase, test_Constraint_createWithNS );
+ tcase_add_test( tcase, test_Constraint_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestDelay.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestDelay.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestDelay.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -213,6 +213,24 @@
END_TEST
+START_TEST (test_Delay_accessWithNULL )
+{
+ fail_unless( Delay_clone(NULL) == NULL );
+ fail_unless( Delay_containsUndeclaredUnits(NULL) == 0);
+ fail_unless( Delay_createWithNS(NULL) == NULL);
+
+ Delay_free(NULL);
+
+
+ fail_unless( Delay_getDerivedUnitDefinition(NULL) == NULL);
+ fail_unless( Delay_getMath(NULL) == NULL);
+ fail_unless( Delay_getNamespaces(NULL) == NULL);
+ fail_unless( Delay_isSetMath(NULL) == 0);
+ fail_unless( Delay_setMath(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+
+}
+END_TEST
+
Suite *
create_suite_Delay (void)
{
@@ -224,13 +242,14 @@
DelayTest_setup,
DelayTest_teardown );
- tcase_add_test( tcase, test_Delay_create );
- //tcase_add_test( tcase, test_Delay_createWithMath );
- tcase_add_test( tcase, test_Delay_setMath );
- tcase_add_test( tcase, test_Delay_setMath1 );
- tcase_add_test( tcase, test_Delay_setMath2 );
- tcase_add_test( tcase, test_Delay_free_NULL );
- tcase_add_test( tcase, test_Delay_createWithNS );
+ tcase_add_test( tcase, test_Delay_create );
+ //tcase_add_test( tcase, test_Delay_createWithMath );
+ tcase_add_test( tcase, test_Delay_setMath );
+ tcase_add_test( tcase, test_Delay_setMath1 );
+ tcase_add_test( tcase, test_Delay_setMath2 );
+ tcase_add_test( tcase, test_Delay_free_NULL );
+ tcase_add_test( tcase, test_Delay_createWithNS );
+ tcase_add_test( tcase, test_Delay_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestEvent.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestEvent.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestEvent.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -375,6 +375,57 @@
}
END_TEST
+START_TEST (test_Event_accessWithNULL)
+{
+ fail_unless(Event_addEventAssignment(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_clone(NULL) == NULL);
+ fail_unless(Event_createDelay(NULL) == NULL);
+ fail_unless(Event_createEventAssignment(NULL) == NULL);
+ fail_unless(Event_createPriority(NULL) == NULL);
+ fail_unless(Event_createTrigger(NULL) == NULL);
+ fail_unless(Event_createWithNS(NULL) == NULL);
+
+ Event_free(NULL);
+
+ fail_unless(Event_getDelay(NULL) == NULL);
+ fail_unless(Event_getEventAssignment(NULL, 0) == NULL);
+ fail_unless(Event_getEventAssignmentByVar(NULL, NULL) == NULL);
+ fail_unless(Event_getId(NULL) == NULL);
+ fail_unless(Event_getListOfEventAssignments(NULL) == NULL);
+ fail_unless(Event_getName(NULL) == NULL);
+ fail_unless(Event_getNamespaces(NULL) == NULL);
+ fail_unless(Event_getNumEventAssignments(NULL) == SBML_INT_MAX);
+ fail_unless(Event_getPriority(NULL) == NULL);
+ fail_unless(Event_getTimeUnits(NULL) == NULL);
+ fail_unless(Event_getTrigger(NULL) == NULL);
+ fail_unless(Event_getUseValuesFromTriggerTime(NULL) == 0);
+ fail_unless(Event_hasRequiredAttributes(NULL) == 0);
+ fail_unless(Event_hasRequiredElements(NULL) == 0);
+ fail_unless(Event_isSetDelay(NULL) == 0);
+ fail_unless(Event_isSetId(NULL) == 0);
+ fail_unless(Event_isSetName(NULL) == 0);
+ fail_unless(Event_isSetPriority(NULL) == 0);
+ fail_unless(Event_isSetTimeUnits(NULL) == 0);
+ fail_unless(Event_isSetTrigger(NULL) == 0);
+ fail_unless(Event_isSetUseValuesFromTriggerTime(NULL) == 0);
+ fail_unless(Event_removeEventAssignment(NULL, 0) == NULL);
+ fail_unless(Event_removeEventAssignmentByVar(NULL, NULL) == NULL);
+ fail_unless(Event_setDelay(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_setId(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_setName(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_setPriority(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_setTimeUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_setTrigger(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_setUseValuesFromTriggerTime(NULL, 0) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_unsetDelay(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_unsetId(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_unsetName(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_unsetPriority(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Event_unsetTimeUnits(NULL) == LIBSBML_INVALID_OBJECT);
+}
+END_TEST
+
+
Suite *
create_suite_Event (void)
{
@@ -386,18 +437,19 @@
EventTest_setup,
EventTest_teardown );
- tcase_add_test( tcase, test_Event_create );
- //tcase_add_test( tcase, test_Event_createWith );
- tcase_add_test( tcase, test_Event_free_NULL );
- tcase_add_test( tcase, test_Event_setId );
- tcase_add_test( tcase, test_Event_setName );
- tcase_add_test( tcase, test_Event_setTrigger );
- tcase_add_test( tcase, test_Event_setDelay );
- tcase_add_test( tcase, test_Event_setTimeUnits );
- tcase_add_test( tcase, test_Event_full );
+ tcase_add_test( tcase, test_Event_create );
+ //tcase_add_test( tcase, test_Event_createWith );
+ tcase_add_test( tcase, test_Event_free_NULL );
+ tcase_add_test( tcase, test_Event_setId );
+ tcase_add_test( tcase, test_Event_setName );
+ tcase_add_test( tcase, test_Event_setTrigger );
+ tcase_add_test( tcase, test_Event_setDelay );
+ tcase_add_test( tcase, test_Event_setTimeUnits );
+ tcase_add_test( tcase, test_Event_full );
tcase_add_test( tcase, test_Event_setUseValuesFromTriggerTime );
- tcase_add_test( tcase, test_Event_createWithNS );
- tcase_add_test( tcase, test_Event_removeEventAssignment );
+ tcase_add_test( tcase, test_Event_createWithNS );
+ tcase_add_test( tcase, test_Event_removeEventAssignment );
+ tcase_add_test( tcase, test_Event_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestEventAssignment.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestEventAssignment.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestEventAssignment.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -206,7 +206,27 @@
}
END_TEST
+START_TEST (test_EventAssignment_accessWithNULL)
+{
+ fail_unless( EventAssignment_clone(NULL) == NULL );
+ fail_unless( EventAssignment_containsUndeclaredUnits(NULL) == 0 );
+ fail_unless( EventAssignment_createWithNS(NULL) == NULL );
+
+ EventAssignment_free(NULL);
+ fail_unless( EventAssignment_getDerivedUnitDefinition(NULL) == NULL );
+ fail_unless( EventAssignment_getMath(NULL) == NULL );
+ fail_unless( EventAssignment_getNamespaces(NULL) == NULL );
+ fail_unless( EventAssignment_getVariable(NULL) == NULL );
+ fail_unless( EventAssignment_isSetMath(NULL) == 0 );
+ fail_unless( EventAssignment_isSetVariable(NULL) == 0 );
+ fail_unless( EventAssignment_setMath(NULL, NULL) == LIBSBML_INVALID_OBJECT );
+ fail_unless( EventAssignment_setVariable(NULL, NULL) == LIBSBML_INVALID_OBJECT );
+ fail_unless( EventAssignment_setVariable(NULL, NULL) == LIBSBML_INVALID_OBJECT );
+}
+END_TEST
+
+
Suite *
create_suite_EventAssignment (void)
{
@@ -218,12 +238,13 @@
EventAssignmentTest_setup,
EventAssignmentTest_teardown );
- tcase_add_test( tcase, test_EventAssignment_create );
- //tcase_add_test( tcase, test_EventAssignment_createWith );
- tcase_add_test( tcase, test_EventAssignment_free_NULL );
- tcase_add_test( tcase, test_EventAssignment_setVariable );
- tcase_add_test( tcase, test_EventAssignment_setMath );
- tcase_add_test( tcase, test_EventAssignment_createWithNS );
+ tcase_add_test( tcase, test_EventAssignment_create );
+ //tcase_add_test( tcase, test_EventAssignment_createWith );
+ tcase_add_test( tcase, test_EventAssignment_free_NULL );
+ tcase_add_test( tcase, test_EventAssignment_setVariable );
+ tcase_add_test( tcase, test_EventAssignment_setMath );
+ tcase_add_test( tcase, test_EventAssignment_createWithNS );
+ tcase_add_test( tcase, test_EventAssignment_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestFunctionDefinition.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestFunctionDefinition.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestFunctionDefinition.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -300,7 +300,32 @@
}
END_TEST
+START_TEST (test_FunctionDefinition_accessWithNULL )
+{
+ fail_unless( FunctionDefinition_clone(NULL) == NULL );
+ fail_unless( FunctionDefinition_createWithNS(NULL) == NULL );
+ FunctionDefinition_free(NULL);
+
+ fail_unless( FunctionDefinition_getArgument(NULL, 0) == NULL );
+ fail_unless( FunctionDefinition_getArgumentByName(NULL, NULL) == NULL );
+ fail_unless( FunctionDefinition_getBody(NULL) == NULL );
+ fail_unless( FunctionDefinition_getId(NULL) == NULL );
+ fail_unless( FunctionDefinition_getMath(NULL) == NULL );
+ fail_unless( FunctionDefinition_getName(NULL) == NULL );
+ fail_unless( FunctionDefinition_getNamespaces(NULL) == NULL );
+ fail_unless( FunctionDefinition_getNumArguments(NULL) == SBML_INT_MAX );
+ fail_unless( FunctionDefinition_isSetId(NULL) == 0 );
+ fail_unless( FunctionDefinition_isSetMath(NULL) == 0 );
+ fail_unless( FunctionDefinition_isSetName(NULL) == 0 );
+ fail_unless( FunctionDefinition_setId(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( FunctionDefinition_setMath(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( FunctionDefinition_setName(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( FunctionDefinition_unsetName(NULL) == LIBSBML_INVALID_OBJECT);
+
+}
+END_TEST
+
Suite *
create_suite_FunctionDefinition (void)
{
@@ -312,15 +337,16 @@
FunctionDefinitionTest_setup,
FunctionDefinitionTest_teardown );
- tcase_add_test( tcase, test_FunctionDefinition_create );
- tcase_add_test( tcase, test_FunctionDefinition_createWith );
- tcase_add_test( tcase, test_FunctionDefinition_free_NULL );
- tcase_add_test( tcase, test_FunctionDefinition_getArguments );
- tcase_add_test( tcase, test_FunctionDefinition_getBody );
- tcase_add_test( tcase, test_FunctionDefinition_setId );
- tcase_add_test( tcase, test_FunctionDefinition_setName );
- tcase_add_test( tcase, test_FunctionDefinition_setMath );
- tcase_add_test( tcase, test_FunctionDefinition_createWithNS );
+ tcase_add_test( tcase, test_FunctionDefinition_create );
+ tcase_add_test( tcase, test_FunctionDefinition_createWith );
+ tcase_add_test( tcase, test_FunctionDefinition_free_NULL );
+ tcase_add_test( tcase, test_FunctionDefinition_getArguments );
+ tcase_add_test( tcase, test_FunctionDefinition_getBody );
+ tcase_add_test( tcase, test_FunctionDefinition_setId );
+ tcase_add_test( tcase, test_FunctionDefinition_setName );
+ tcase_add_test( tcase, test_FunctionDefinition_setMath );
+ tcase_add_test( tcase, test_FunctionDefinition_createWithNS );
+ tcase_add_test( tcase, test_FunctionDefinition_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestInitialAssignment.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestInitialAssignment.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestInitialAssignment.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -202,7 +202,25 @@
}
END_TEST
+START_TEST (test_InitialAssignment_accessWithNULL)
+{
+ fail_unless(InitialAssignment_clone(NULL) == NULL);
+ fail_unless(InitialAssignment_containsUndeclaredUnits(NULL) == 0);
+ fail_unless(InitialAssignment_createWithNS(NULL) == NULL);
+ InitialAssignment_free(NULL);
+
+ fail_unless(InitialAssignment_getDerivedUnitDefinition(NULL) == NULL);
+ fail_unless(InitialAssignment_getMath(NULL) == NULL);
+ fail_unless(InitialAssignment_getNamespaces(NULL) == NULL);
+ fail_unless(InitialAssignment_getSymbol(NULL) == NULL);
+ fail_unless(InitialAssignment_isSetMath(NULL) == 0);
+ fail_unless(InitialAssignment_isSetSymbol(NULL) == 0);
+ fail_unless(InitialAssignment_setMath(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(InitialAssignment_setSymbol(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+}
+END_TEST
+
Suite *
create_suite_InitialAssignment (void)
{
@@ -214,12 +232,13 @@
InitialAssignmentTest_setup,
InitialAssignmentTest_teardown );
- tcase_add_test( tcase, test_InitialAssignment_create );
- //tcase_add_test( tcase, test_InitialAssignment_createWith );
- tcase_add_test( tcase, test_InitialAssignment_free_NULL );
- tcase_add_test( tcase, test_InitialAssignment_setSymbol );
- tcase_add_test( tcase, test_InitialAssignment_setMath );
- tcase_add_test( tcase, test_InitialAssignment_createWithNS );
+ tcase_add_test( tcase, test_InitialAssignment_create );
+ //tcase_add_test( tcase, test_InitialAssignment_createWith );
+ tcase_add_test( tcase, test_InitialAssignment_free_NULL );
+ tcase_add_test( tcase, test_InitialAssignment_setSymbol );
+ tcase_add_test( tcase, test_InitialAssignment_setMath );
+ tcase_add_test( tcase, test_InitialAssignment_createWithNS );
+ tcase_add_test( tcase, test_InitialAssignment_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestKineticLaw.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestKineticLaw.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestKineticLaw.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -427,6 +427,49 @@
END_TEST
+START_TEST (test_KineticLaw_accessWithNULL)
+{
+ fail_unless( KineticLaw_addLocalParameter(NULL, NULL) == LIBSBML_INVALID_OBJECT );
+ fail_unless( KineticLaw_addParameter(NULL, NULL) == LIBSBML_INVALID_OBJECT );
+ fail_unless( KineticLaw_clone(NULL) == NULL);
+ fail_unless( KineticLaw_containsUndeclaredUnits(NULL) == 0);
+ fail_unless( KineticLaw_createLocalParameter(NULL) == NULL);
+ fail_unless( KineticLaw_createParameter(NULL) == NULL);
+ fail_unless( KineticLaw_createWithNS(NULL) == NULL);
+
+ KineticLaw_free(NULL);
+
+ fail_unless( KineticLaw_getDerivedUnitDefinition(NULL) == NULL);
+ fail_unless( KineticLaw_getFormula(NULL) == NULL);
+ fail_unless( KineticLaw_getListOfLocalParameters(NULL) == NULL);
+ fail_unless( KineticLaw_getListOfParameters(NULL) == NULL);
+ fail_unless( KineticLaw_getLocalParameter(NULL, 0) == NULL);
+ fail_unless( KineticLaw_getLocalParameterById(NULL, NULL) == NULL);
+ fail_unless( KineticLaw_getMath(NULL) == NULL);
+ fail_unless( KineticLaw_getNamespaces(NULL) == NULL);
+ fail_unless( KineticLaw_getNumLocalParameters(NULL) == SBML_INT_MAX);
+ fail_unless( KineticLaw_getNumParameters(NULL) == SBML_INT_MAX);
+ fail_unless( KineticLaw_getParameter(NULL, 0) == NULL);
+ fail_unless( KineticLaw_getParameterById(NULL, NULL) == NULL);
+ fail_unless( KineticLaw_getSubstanceUnits(NULL) == NULL);
+ fail_unless( KineticLaw_getTimeUnits(NULL) == NULL);
+ fail_unless( KineticLaw_isSetFormula(NULL) == 0);
+ fail_unless( KineticLaw_isSetMath(NULL) == 0);
+ fail_unless( KineticLaw_isSetSubstanceUnits(NULL) == 0);
+ fail_unless( KineticLaw_isSetTimeUnits(NULL) == 0);
+ fail_unless( KineticLaw_removeLocalParameter(NULL, 0) == NULL);
+ fail_unless( KineticLaw_removeLocalParameterById(NULL, NULL) == NULL);
+ fail_unless( KineticLaw_removeParameter(NULL, 0) == NULL);
+ fail_unless( KineticLaw_removeParameterById(NULL, NULL) == NULL);
+ fail_unless( KineticLaw_setFormula(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( KineticLaw_setMath(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( KineticLaw_setSubstanceUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( KineticLaw_setTimeUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( KineticLaw_unsetSubstanceUnits(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( KineticLaw_unsetTimeUnits(NULL) == LIBSBML_INVALID_OBJECT);
+}
+END_TEST
+
Suite *
create_suite_KineticLaw (void)
{
@@ -439,19 +482,20 @@
KineticLawTest_teardown );
tcase_add_test( tcase, test_KineticLaw_create );
- //tcase_add_test( tcase, test_KineticLaw_createWith );
- //tcase_add_test( tcase, test_KineticLaw_createWithMath );
+ //tcase_add_test( tcase, test_KineticLaw_createWith );
+ //tcase_add_test( tcase, test_KineticLaw_createWithMath );
tcase_add_test( tcase, test_KineticLaw_free_NULL );
tcase_add_test( tcase, test_KineticLaw_setFormula );
- tcase_add_test( tcase, test_KineticLaw_setBadFormula );
+ tcase_add_test( tcase, test_KineticLaw_setBadFormula );
tcase_add_test( tcase, test_KineticLaw_setFormulaFromMath );
tcase_add_test( tcase, test_KineticLaw_setMath );
tcase_add_test( tcase, test_KineticLaw_setMathFromFormula );
tcase_add_test( tcase, test_KineticLaw_addParameter );
tcase_add_test( tcase, test_KineticLaw_getParameter );
tcase_add_test( tcase, test_KineticLaw_getParameterById );
- tcase_add_test( tcase, test_KineticLaw_createWithNS );
+ tcase_add_test( tcase, test_KineticLaw_createWithNS );
tcase_add_test( tcase, test_KineticLaw_removeParameter );
+ tcase_add_test( tcase, test_KineticLaw_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestL3LocalParameter.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestL3LocalParameter.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestL3LocalParameter.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -261,7 +261,39 @@
}
END_TEST
+START_TEST (test_L3_LocalParameter_accessWithNULL)
+{
+ fail_unless( LocalParameter_clone(NULL) == NULL );
+ fail_unless( LocalParameter_createWithNS(NULL) == NULL );
+ LocalParameter_free(NULL);
+
+ //fail_unless( LocalParameter_getConstant(NULL) == 0 );
+ fail_unless( LocalParameter_getDerivedUnitDefinition(NULL) == NULL );
+ fail_unless( LocalParameter_getId(NULL) == NULL );
+ fail_unless( LocalParameter_getName(NULL) == NULL );
+ fail_unless( LocalParameter_getNamespaces(NULL) == NULL );
+ fail_unless( LocalParameter_getUnits(NULL) == NULL );
+ fail_unless( isnan( LocalParameter_getValue(NULL) ));
+ fail_unless( LocalParameter_hasRequiredAttributes(NULL) == 0);
+
+ //LocalParameter_initDefaults(NULL);
+
+ fail_unless( LocalParameter_isSetId(NULL) == 0);
+ fail_unless( LocalParameter_isSetName(NULL) == 0);
+ fail_unless( LocalParameter_isSetUnits(NULL) == 0);
+ fail_unless( LocalParameter_isSetValue(NULL) == 0);
+ //fail_unless( LocalParameter_setConstant(NULL, 0) == LIBSBML_INVALID_OBJECT);
+ fail_unless( LocalParameter_setId(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( LocalParameter_setName(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( LocalParameter_setUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( LocalParameter_setValue(NULL, 0) == LIBSBML_INVALID_OBJECT);
+ fail_unless( LocalParameter_unsetName(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( LocalParameter_unsetUnits(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless( LocalParameter_unsetValue(NULL) == LIBSBML_INVALID_OBJECT);
+}
+END_TEST
+
Suite *
create_suite_L3_LocalParameter (void)
{
@@ -273,15 +305,16 @@
L3LocalParameterTest_setup,
L3LocalParameterTest_teardown );
- tcase_add_test( tcase, test_L3_LocalParameter_create );
- tcase_add_test( tcase, test_L3_LocalParameter_free_NULL );
- tcase_add_test( tcase, test_L3_LocalParameter_id );
- tcase_add_test( tcase, test_L3_LocalParameter_name );
- tcase_add_test( tcase, test_L3_LocalParameter_units );
- tcase_add_test( tcase, test_L3_LocalParameter_value);
- tcase_add_test( tcase, test_L3_LocalParameter_createWithNS );
- tcase_add_test( tcase, test_L3_LocalParameter_hasRequiredAttributes );
- tcase_add_test( tcase, test_L3_LocalParameter_NS );
+ tcase_add_test( tcase, test_L3_LocalParameter_create );
+ tcase_add_test( tcase, test_L3_LocalParameter_free_NULL );
+ tcase_add_test( tcase, test_L3_LocalParameter_id );
+ tcase_add_test( tcase, test_L3_LocalParameter_name );
+ tcase_add_test( tcase, test_L3_LocalParameter_units );
+ tcase_add_test( tcase, test_L3_LocalParameter_value );
+ tcase_add_test( tcase, test_L3_LocalParameter_createWithNS );
+ tcase_add_test( tcase, test_L3_LocalParameter_hasRequiredAttributes );
+ tcase_add_test( tcase, test_L3_LocalParameter_NS );
+ tcase_add_test( tcase, test_L3_LocalParameter_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestListOf.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestListOf.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestListOf.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -212,6 +212,25 @@
}
END_TEST
+START_TEST (test_ListOf_accessWithNULL)
+{
+ fail_unless( ListOf_append(NULL, NULL) == LIBSBML_INVALID_OBJECT );
+ fail_unless( ListOf_appendAndOwn(NULL, NULL) == LIBSBML_INVALID_OBJECT );
+
+ ListOf_clear(NULL, 0);
+
+ fail_unless( ListOf_clone(NULL) == NULL);
+
+ ListOf_free(NULL);
+
+ fail_unless( ListOf_get(NULL, 0) == NULL);
+ fail_unless( ListOf_getItemTypeCode(NULL) == SBML_UNKNOWN);
+ fail_unless( ListOf_remove(NULL, 0) == NULL);
+ fail_unless( ListOf_size(NULL) == SBML_INT_MAX);
+
+}
+END_TEST
+
Suite *
create_suite_ListOf (void)
{
@@ -219,12 +238,13 @@
TCase *tcase = tcase_create("ListOf");
- tcase_add_test(tcase, test_ListOf_create );
- tcase_add_test(tcase, test_ListOf_free_NULL );
- tcase_add_test(tcase, test_ListOf_get );
- tcase_add_test(tcase, test_ListOf_remove );
- tcase_add_test(tcase, test_ListOf_clear );
- tcase_add_test(tcase, test_ListOf_append );
+ tcase_add_test(tcase, test_ListOf_create );
+ tcase_add_test(tcase, test_ListOf_free_NULL );
+ tcase_add_test(tcase, test_ListOf_get );
+ tcase_add_test(tcase, test_ListOf_remove );
+ tcase_add_test(tcase, test_ListOf_clear );
+ tcase_add_test(tcase, test_ListOf_append );
+ tcase_add_test(tcase, test_ListOf_accessWithNULL );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestModel.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestModel.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestModel.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -1559,7 +1559,185 @@
END_TEST
+START_TEST (test_Model_accessWithNULL)
+{
+ fail_unless(Model_addCompartment(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addCompartmentType(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addConstraint(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addEvent(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addFunctionDefinition(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addInitialAssignment(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+#ifdef USE_LAYOUT
+ fail_unless(Model_addLayout(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+#endif
+ fail_unless(Model_addParameter(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addReaction(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addRule(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addSpecies(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addSpeciesType(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_addUnitDefinition(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_clone(NULL) == NULL);
+ fail_unless(Model_createAlgebraicRule(NULL) == NULL);
+ fail_unless(Model_createAssignmentRule(NULL) == NULL);
+ fail_unless(Model_createCompartment(NULL) == NULL);
+ fail_unless(Model_createCompartmentType(NULL) == NULL);
+ fail_unless(Model_createConstraint(NULL) == NULL);
+ fail_unless(Model_createDelay(NULL) == NULL);
+ fail_unless(Model_createEvent(NULL) == NULL);
+ fail_unless(Model_createEventAssignment(NULL) == NULL);
+ fail_unless(Model_createFunctionDefinition(NULL) == NULL);
+ fail_unless(Model_createInitialAssignment(NULL) == NULL);
+ fail_unless(Model_createKineticLaw(NULL) == NULL);
+ fail_unless(Model_createKineticLawLocalParameter(NULL) == NULL);
+ fail_unless(Model_createKineticLawParameter(NULL) == NULL);
+#ifdef USE_LAYOUT
+ fail_unless(Model_createLayout(NULL) == NULL);
+#endif
+ fail_unless(Model_createModifier(NULL) == NULL);
+ fail_unless(Model_createParameter(NULL) == NULL);
+ fail_unless(Model_createProduct(NULL) == NULL);
+ fail_unless(Model_createRateRule(NULL) == NULL);
+ fail_unless(Model_createReactant(NULL) == NULL);
+ fail_unless(Model_createReaction(NULL) == NULL);
+ fail_unless(Model_createSpecies(NULL) == NULL);
+ fail_unless(Model_createSpeciesType(NULL) == NULL);
+ fail_unless(Model_createTrigger(NULL) == NULL);
+ fail_unless(Model_createUnit(NULL) == NULL);
+ fail_unless(Model_createUnitDefinition(NULL) == NULL);
+ fail_unless(Model_createWithNS(NULL) == NULL);
+ Model_free(NULL);
+
+ fail_unless(Model_getAreaUnits(NULL) == NULL);
+ fail_unless(Model_getCompartment(NULL, 0) == NULL);
+ fail_unless(Model_getCompartmentById(NULL, NULL) == NULL);
+ fail_unless(Model_getCompartmentType(NULL, 0) == NULL);
+ fail_unless(Model_getCompartmentTypeById(NULL, NULL) == NULL);
+ fail_unless(Model_getConstraint(NULL, 0) == NULL);
+ fail_unless(Model_getConversionFactor(NULL) == NULL);
+ fail_unless(Model_getEvent(NULL, 0) == NULL);
+ fail_unless(Model_getEventById(NULL, NULL) == NULL);
+ fail_unless(Model_getExtentUnits(NULL) == NULL);
+ fail_unless(Model_getFunctionDefinition(NULL, 0) == NULL);
+ fail_unless(Model_getFunctionDefinitionById(NULL, NULL) == NULL);
+ fail_unless(Model_getId(NULL) == NULL);
+ fail_unless(Model_getInitialAssignment(NULL, 0) == NULL);
+ fail_unless(Model_getInitialAssignmentBySym(NULL, NULL) == NULL);
+#ifdef USE_LAYOUT
+ fail_unless(Model_getLayout(NULL, 0) == NULL);
+#endif
+ fail_unless(Model_getLengthUnits(NULL) == NULL);
+ fail_unless(Model_getListOfCompartments(NULL) == NULL);
+ fail_unless(Model_getListOfCompartmentTypes(NULL) == NULL);
+ fail_unless(Model_getListOfConstraints(NULL) == NULL);
+ fail_unless(Model_getListOfEvents(NULL) == NULL);
+ fail_unless(Model_getListOfFunctionDefinitions(NULL) == NULL);
+ fail_unless(Model_getListOfInitialAssignments(NULL) == NULL);
+#ifdef USE_LAYOUT
+ fail_unless(Model_getListOfLayouts(NULL) == NULL);
+#endif
+ fail_unless(Model_getListOfParameters(NULL) == NULL);
+ fail_unless(Model_getListOfReactions(NULL) == NULL);
+ fail_unless(Model_getListOfRules(NULL) == NULL);
+ fail_unless(Model_getListOfSpecies(NULL) == NULL);
+ fail_unless(Model_getListOfSpeciesTypes(NULL) == NULL);
+ fail_unless(Model_getListOfUnitDefinitions(NULL) == NULL);
+ fail_unless(Model_getModelHistory(NULL) == NULL);
+ fail_unless(Model_getName(NULL) == NULL);
+ fail_unless(Model_getNamespaces(NULL) == NULL);
+ fail_unless(Model_getNumCompartments(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumCompartmentTypes(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumConstraints(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumEvents(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumFunctionDefinitions(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumInitialAssignments(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumParameters(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumReactions(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumRules(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumSpecies(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumSpeciesTypes(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumSpeciesWithBoundaryCondition(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getNumUnitDefinitions(NULL) == SBML_INT_MAX);
+ fail_unless(Model_getParameter(NULL, 0) == NULL);
+ fail_unless(Model_getParameterById(NULL, NULL) == NULL);
+ fail_unless(Model_getReaction(NULL, 0) == NULL);
+ fail_unless(Model_getReactionById(NULL, NULL) == NULL);
+ fail_unless(Model_getRule(NULL, 0) == NULL);
+ fail_unless(Model_getRuleByVar(NULL, NULL) == NULL);
+ fail_unless(Model_getSpecies(NULL, 0) == NULL);
+ fail_unless(Model_getSpeciesById(NULL, NULL) == NULL);
+ fail_unless(Model_getSpeciesReferenceById(NULL, NULL) == NULL);
+ fail_unless(Model_getSpeciesType(NULL, 0) == NULL);
+ fail_unless(Model_getSpeciesTypeById(NULL, NULL) == NULL);
+ fail_unless(Model_getSubstanceUnits(NULL) == NULL);
+ fail_unless(Model_getTimeUnits(NULL) == NULL);
+ fail_unless(Model_getUnitDefinition(NULL, 0) == NULL);
+ fail_unless(Model_getUnitDefinitionById(NULL, NULL) == NULL);
+ fail_unless(Model_getVolumeUnits(NULL) == NULL);
+ fail_unless(Model_isPopulatedListFormulaUnitsData(NULL) == 0);
+ fail_unless(Model_isSetAreaUnits(NULL) == 0);
+ fail_unless(Model_isSetConversionFactor(NULL) == 0);
+ fail_unless(Model_isSetExtentUnits(NULL) == 0);
+ fail_unless(Model_isSetId(NULL) == 0);
+ fail_unless(Model_isSetLengthUnits(NULL) == 0);
+ fail_unless(Model_isSetModelHistory(NULL) == 0);
+ fail_unless(Model_isSetName(NULL) == 0);
+ fail_unless(Model_isSetSubstanceUnits(NULL) == 0);
+ fail_unless(Model_isSetTimeUnits(NULL) == 0);
+ fail_unless(Model_isSetVolumeUnits(NULL) == 0);
+
+ Model_populateListFormulaUnitsData(NULL);
+
+ fail_unless(Model_removeCompartment(NULL, 0) == NULL);
+ fail_unless(Model_removeCompartmentById(NULL, NULL) == NULL);
+ fail_unless(Model_removeCompartmentType(NULL, 0) == NULL);
+ fail_unless(Model_removeCompartmentTypeById(NULL, NULL) == NULL);
+ fail_unless(Model_removeConstraint(NULL, 0) == NULL);
+ fail_unless(Model_removeEvent(NULL, 0) == NULL);
+ fail_unless(Model_removeEventById(NULL, NULL) == NULL);
+ fail_unless(Model_removeFunctionDefinition(NULL, 0) == NULL);
+ fail_unless(Model_removeFunctionDefinitionById(NULL, NULL) == NULL);
+ fail_unless(Model_removeInitialAssignment(NULL, 0) == NULL);
+ fail_unless(Model_removeInitialAssignmentBySym(NULL, NULL) == NULL);
+#ifdef USE_LAYOUT
+ fail_unless(Model_removeLayout(NULL, 0) == NULL);
+#endif
+ fail_unless(Model_removeParameter(NULL, 0) == NULL);
+ fail_unless(Model_removeParameterById(NULL, NULL) == NULL);
+ fail_unless(Model_removeReaction(NULL, 0) == NULL);
+ fail_unless(Model_removeReactionById(NULL, NULL) == NULL);
+ fail_unless(Model_removeRule(NULL, 0) == NULL);
+ fail_unless(Model_removeRuleByVar(NULL, NULL) == NULL);
+ fail_unless(Model_removeSpecies(NULL, 0) == NULL);
+ fail_unless(Model_removeSpeciesById(NULL, NULL) == NULL);
+ fail_unless(Model_removeSpeciesType(NULL, 0) == NULL);
+ fail_unless(Model_removeSpeciesTypeById(NULL, NULL) == NULL);
+ fail_unless(Model_removeUnitDefinition(NULL, 0) == NULL);
+ fail_unless(Model_removeUnitDefinitionById(NULL, NULL) == NULL);
+ fail_unless(Model_setAreaUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_setConversionFactor(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_setExtentUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_setId(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_setLengthUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_setModelHistory(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_setName(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_setSubstanceUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_setTimeUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_setVolumeUnits(NULL, NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetAreaUnits(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetConversionFactor(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetExtentUnits(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetId(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetLengthUnits(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetModelHistory(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetName(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetSubstanceUnits(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetTimeUnits(NULL) == LIBSBML_INVALID_OBJECT);
+ fail_unless(Model_unsetVolumeUnits(NULL) == LIBSBML_INVALID_OBJECT);
+
+}
+END_TEST
+
Suite *
create_suite_Model (void)
{
@@ -1667,6 +1845,8 @@
tcase_add_test( t, test_Model_removeConstraint );
tcase_add_test( t, test_Model_removeReaction );
tcase_add_test( t, test_Model_removeEvent );
+
+ tcase_add_test( t, test_Model_accessWithNULL );
suite_add_tcase(s, t);
Modified: trunk/libsbml/src/sbml/test/TestModifierSpeciesReference.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestModifierSpeciesReference.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestModifierSpeciesReference.c 2011-02-26 00:32:46 UTC (rev 13054)
@@ -152,7 +152,6 @@
}
END_TEST
-
Suite *
create_suite_ModifierSpeciesReference (void)
{
@@ -164,10 +163,10 @@
ModifierSpeciesReferenceTest_setup,
ModifierSpeciesReferenceTest_teardown );
- tcase_add_test( tcase, test_ModifierSpeciesReference_create );
- tcase_add_test( tcase, test_ModifierSpeciesReference_free_NULL );
- tcase_add_test( tcase, test_ModifierSpeciesReference_setSpecies );
- tcase_add_test( tcase, test_ModifierSpeciesReference_createWithNS );
+ tcase_add_test( tcase, test_ModifierSpeciesReference_create );
+ tcase_add_test( tcase, test_ModifierSpeciesReference_free_NULL );
+ tcase_add_test( tcase, test_ModifierSpeciesReference_setSpecies );
+ tcase_add_test( tcase, test_ModifierSpeciesReference_createWithNS );
suite_add_tcase(suite, tcase);
Modified: trunk/libsbml/src/sbml/test/TestParameter.c
===================================================================
--- trunk/libsbml/src/sbml/test/TestParameter.c 2011-02-25 17:33:54 UTC (rev 13053)
+++ trunk/libsbml/src/sbml/test/TestPara...
[truncated message content] |
|
From: <fbe...@us...> - 2011-02-25 17:34:00
|
Revision: 13053
http://sbml.svn.sourceforge.net/sbml/?rev=13053&view=rev
Author: fbergmann
Date: 2011-02-25 17:33:54 +0000 (Fri, 25 Feb 2011)
Log Message:
-----------
- ListOf needs to check append / appendAndOwn for NULL argument
Modified Paths:
--------------
trunk/libsbml/src/sbml/ListOf.cpp
Modified: trunk/libsbml/src/sbml/ListOf.cpp
===================================================================
--- trunk/libsbml/src/sbml/ListOf.cpp 2011-02-25 17:14:23 UTC (rev 13052)
+++ trunk/libsbml/src/sbml/ListOf.cpp 2011-02-25 17:33:54 UTC (rev 13053)
@@ -35,6 +35,7 @@
#include <sbml/ListOf.h>
#include <sbml/SBO.h>
#include <sbml/common/common.h>
+#include <sbml/common/operationReturnValues.h>
/** @cond doxygen-ignored */
@@ -137,6 +138,7 @@
int
ListOf::append (const SBase* item)
{
+ if (item == NULL) return LIBSBML_INVALID_OBJECT;
return appendAndOwn( item->clone() );
}
@@ -148,6 +150,8 @@
int
ListOf::appendAndOwn (SBase* item)
{
+ if (item == NULL) return LIBSBML_INVALID_OBJECT;
+
bool okayToAdd = false;
/* okay to add the object if
* 1) first object to be added to listOf doesnt have type
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <fbe...@us...> - 2011-02-25 17:14:30
|
Revision: 13052
http://sbml.svn.sourceforge.net/sbml/?rev=13052&view=rev
Author: fbergmann
Date: 2011-02-25 17:14:23 +0000 (Fri, 25 Feb 2011)
Log Message:
-----------
- xml constructor exception needs to be listed in the VS project
Modified Paths:
--------------
trunk/libsbml/win/msvc7/common/csharp/CSharp_cspDLL.csproj
trunk/libsbml/win/msvc8/common/csharp/CSharp_cspDLL.csproj
trunk/libsbml/win/msvc9/common/csharp/CSharp_cspDLL.csproj
Modified: trunk/libsbml/win/msvc7/common/csharp/CSharp_cspDLL.csproj
===================================================================
--- trunk/libsbml/win/msvc7/common/csharp/CSharp_cspDLL.csproj 2011-02-25 15:32:07 UTC (rev 13051)
+++ trunk/libsbml/win/msvc7/common/csharp/CSharp_cspDLL.csproj 2011-02-25 17:14:23 UTC (rev 13052)
@@ -589,6 +589,11 @@
BuildAction = "Compile"
/>
<File
+ RelPath = "csharp-files-win\XMLConstructorException.cs"
+ SubType = "Code"
+ BuildAction = "Compile"
+ />
+ <File
RelPath = "Properties\AssemblyInfo.cs"
SubType = "Code"
BuildAction = "Compile"
Modified: trunk/libsbml/win/msvc8/common/csharp/CSharp_cspDLL.csproj
===================================================================
--- trunk/libsbml/win/msvc8/common/csharp/CSharp_cspDLL.csproj 2011-02-25 15:32:07 UTC (rev 13051)
+++ trunk/libsbml/win/msvc8/common/csharp/CSharp_cspDLL.csproj 2011-02-25 17:14:23 UTC (rev 13052)
@@ -392,6 +392,9 @@
<Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\SBMLNamespacesList.cs">
<SubType>Code</SubType>
</Compile>
+ <Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\XMLConstructorException.cs">
+ <SubType>Code</SubType>
+ </Compile>
</ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
Modified: trunk/libsbml/win/msvc9/common/csharp/CSharp_cspDLL.csproj
===================================================================
--- trunk/libsbml/win/msvc9/common/csharp/CSharp_cspDLL.csproj 2011-02-25 15:32:07 UTC (rev 13051)
+++ trunk/libsbml/win/msvc9/common/csharp/CSharp_cspDLL.csproj 2011-02-25 17:14:23 UTC (rev 13052)
@@ -390,6 +390,9 @@
<Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\SBMLNamespacesList.cs">
<SubType>Code</SubType>
</Compile>
+ <Compile Include="..\..\..\..\src\bindings\csharp\csharp-files-win\XMLConstructorException.cs">
+ <SubType>Code</SubType>
+ </Compile>
<Compile Include="..\..\..\..\src\bindings\csharp\Properties\AssemblyInfo.cs">
<SubType>Code</SubType>
</Compile>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <sar...@us...> - 2011-02-25 15:32:13
|
Revision: 13051
http://sbml.svn.sourceforge.net/sbml/?rev=13051&view=rev
Author: sarahkeating
Date: 2011-02-25 15:32:07 +0000 (Fri, 25 Feb 2011)
Log Message:
-----------
caught typo
Modified Paths:
--------------
trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win32.iss
Modified: trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win32.iss
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win32.iss 2011-02-25 15:28:54 UTC (rev 13050)
+++ trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win32.iss 2011-02-25 15:32:07 UTC (rev 13051)
@@ -257,6 +257,7 @@
MatlabRoot := GetMatlabRoot('');
GetPython25Dir('');
GetPython26Dir('');
+ GetPython27Dir('');
if (not Python25Present) and (not Python26Present) and (not Python27Present) then begin
PythonPresent := False;
end else begin
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <sar...@us...> - 2011-02-25 15:29:00
|
Revision: 13050
http://sbml.svn.sourceforge.net/sbml/?rev=13050&view=rev
Author: sarahkeating
Date: 2011-02-25 15:28:54 +0000 (Fri, 25 Feb 2011)
Log Message:
-----------
caught more typos
Modified Paths:
--------------
trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss
Modified: trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss 2011-02-25 15:21:01 UTC (rev 13049)
+++ trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss 2011-02-25 15:28:54 UTC (rev 13050)
@@ -662,14 +662,14 @@
{ function to return flag as to whether to write libraries to other directories directory}
function GetPython27() : Boolean;
begin
- if (InstallOptionsPage.Values[4] = True) and (PythonPage.SelectedValueIndex = 2) then
+ if (InstallOptionsPage.Values[4] = True) and (PythonPage.SelectedValueIndex = 1) then
Result := True
else
Result := False;
end;
function GetPython26() : Boolean;
begin
- if (InstallOptionsPage.Values[4] = True) and (PythonPage.SelectedValueIndex = 1) then
+ if (InstallOptionsPage.Values[4] = True) and (PythonPage.SelectedValueIndex = 0) then
Result := True
else
Result := False;
@@ -677,9 +677,9 @@
function GetPython25() : Boolean;
begin
- if (InstallOptionsPage.Values[4] = True) and (PythonPage.SelectedValueIndex = 0) then
+{ if (InstallOptionsPage.Values[4] = True) and (PythonPage.SelectedValueIndex = 0) then
Result := True
- else
+ else }
Result := False;
end;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <sar...@us...> - 2011-02-25 15:21:07
|
Revision: 13049
http://sbml.svn.sourceforge.net/sbml/?rev=13049&view=rev
Author: sarahkeating
Date: 2011-02-25 15:21:01 +0000 (Fri, 25 Feb 2011)
Log Message:
-----------
caught a bug in listing octave
Modified Paths:
--------------
trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss
Modified: trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss 2011-02-25 14:31:49 UTC (rev 13048)
+++ trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss 2011-02-25 15:21:01 UTC (rev 13049)
@@ -9,7 +9,7 @@
AppPublisherURL=http://sbml.org
AppSupportURL=http://sbml.org
AppUpdatesURL=http://sbml.org
-DefaultDirName={pf}\SBML\libSBML-4..0-libxml2-x64
+DefaultDirName={pf}\SBML\libSBML-4.3.0-libxml2-x64
DefaultGroupName=libSBML
DisableProgramGroupPage=yes
OutputDir=.\Output
@@ -256,6 +256,7 @@
MatlabRoot := GetMatlabRoot('');
GetPython25Dir('');
GetPython26Dir('');
+ GetPython27Dir('');
if (not Python26Present) and (not Python27Present) then begin
PythonPresent := False;
end else begin
@@ -302,7 +303,6 @@
InstallOptionsPage.Add('Install C# language interface');
InstallOptionsPage.Add('Install Java language interface');
InstallOptionsPage.Add('Install MATLAB language interface');
- InstallOptionsPage.Add('Install Octave language interface');
InstallOptionsPage.Add('Install Perl language interface');
InstallOptionsPage.Add('Install Python language interface');
@@ -741,8 +741,9 @@
{ Return the selected DataDir }
Result := OctavePage.Values[0];
end;
+
[Run]
-Filename: "{app}\bindings\python\libsbml-4.3.0.win64-py2.6.exe"; flags: nowait; Check: GetPython26;
-Filename: "{app}\bindings\python\libsbml-4.3.0.win64-py2.7.exe"; flags: nowait; Check: GetPython27;
+Filename: "{app}\bindings\python\libsbml-4.3.0.win-amd64-py2.6.exe"; flags: nowait; Check: GetPython26;
+Filename: "{app}\bindings\python\libsbml-4.3.0.win-amd64-py2.7.exe"; flags: nowait; Check: GetPython27;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <sar...@us...> - 2011-02-25 14:31:56
|
Revision: 13048
http://sbml.svn.sourceforge.net/sbml/?rev=13048&view=rev
Author: sarahkeating
Date: 2011-02-25 14:31:49 +0000 (Fri, 25 Feb 2011)
Log Message:
-----------
updated for 4.3
Modified Paths:
--------------
trunk/libsbml/dev/utilities/win_installer/createXMLRel_x64.bat
trunk/libsbml/dev/utilities/win_installer/createXMLRel_x86.bat
trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win32.iss
trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss
Modified: trunk/libsbml/dev/utilities/win_installer/createXMLRel_x64.bat
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/createXMLRel_x64.bat 2011-02-25 14:16:39 UTC (rev 13047)
+++ trunk/libsbml/dev/utilities/win_installer/createXMLRel_x64.bat 2011-02-25 14:31:49 UTC (rev 13048)
@@ -208,10 +208,17 @@
cd matlab
copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.mexw64 TranslateSBML.mexw64
copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.m TranslateSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.c TranslateSBML.c
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.mexw64 OutputSBML.mexw64
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.m OutputSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.c OutputSBML.c
copy ..\..\..\..\..\..\src\bindings\matlab\Contents.m Contents.m
copy ..\..\..\..\..\..\src\bindings\matlab\CheckAndConvert.m CheckAndConvert.m
copy ..\..\..\..\..\..\src\bindings\matlab\isoctave.m isoctave.m
-copy ..\..\..\..\..\..\src\bindings\matlab\install_for_win64installers.m install_win64.m
+copy ..\..\..\..\..\..\src\bindings\matlab\ConvertFormulaToMathML.m ConvertFormulaToMathML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\isSBML_Model.m isSBML_Model.m
+copy ..\..\..\..\..\..\src\bindings\matlab\buildSBML.m buildSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\installSBML.m installSBML.m
copy ..\..\..\..\..\..\src\bindings\matlab\test.xml test.xml
cd ..
Modified: trunk/libsbml/dev/utilities/win_installer/createXMLRel_x86.bat
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/createXMLRel_x86.bat 2011-02-25 14:16:39 UTC (rev 13047)
+++ trunk/libsbml/dev/utilities/win_installer/createXMLRel_x86.bat 2011-02-25 14:31:49 UTC (rev 13048)
@@ -209,21 +209,37 @@
cd matlab
copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.mexw32 TranslateSBML.mexw32
copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.m TranslateSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.c TranslateSBML.c
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.mexw32 OutputSBML.mexw32
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.m OutputSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.c OutputSBML.c
copy ..\..\..\..\..\..\src\bindings\matlab\Contents.m Contents.m
copy ..\..\..\..\..\..\src\bindings\matlab\CheckAndConvert.m CheckAndConvert.m
copy ..\..\..\..\..\..\src\bindings\matlab\isoctave.m isoctave.m
-copy ..\..\..\..\..\..\src\bindings\matlab\install_for_Win32installers.m install_Win32.m
+copy ..\..\..\..\..\..\src\bindings\matlab\ConvertFormulaToMathML.m ConvertFormulaToMathML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\isSBML_Model.m isSBML_Model.m
+copy ..\..\..\..\..\..\src\bindings\matlab\buildSBML.m buildSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\installSBML.m installSBML.m
copy ..\..\..\..\..\..\src\bindings\matlab\test.xml test.xml
cd ..
rem bindings/octave directory
cd octave
copy ..\..\..\..\..\..\src\bindings\octave\TranslateSBML.mex TranslateSBML.mex
+copy ..\..\..\..\..\..\src\bindings\octave\OutputSBML.mex OutputSBML.mex
+copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.m TranslateSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\TranslateSBML.c TranslateSBML.c
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.m OutputSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\OutputSBML.c OutputSBML.c
+copy ..\..\..\..\..\..\src\bindings\matlab\Contents.m Contents.m
copy ..\..\..\..\..\..\src\bindings\matlab\CheckAndConvert.m CheckAndConvert.m
copy ..\..\..\..\..\..\src\bindings\matlab\isoctave.m isoctave.m
+copy ..\..\..\..\..\..\src\bindings\matlab\ConvertFormulaToMathML.m ConvertFormulaToMathML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\isSBML_Model.m isSBML_Model.m
+copy ..\..\..\..\..\..\src\bindings\matlab\buildSBML.m buildSBML.m
+copy ..\..\..\..\..\..\src\bindings\matlab\installSBML.m installSBML.m
copy ..\..\..\..\..\..\src\bindings\matlab\test.xml test.xml
-copy ..\..\..\..\..\..\src\bindings\matlab\install_for_Win32installers.m install_Win32.m
-cd ..
+d ..
rem bindings/csharp directory
cd csharp
Modified: trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win32.iss
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win32.iss 2011-02-25 14:16:39 UTC (rev 13047)
+++ trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win32.iss 2011-02-25 14:31:49 UTC (rev 13048)
@@ -1,19 +1,19 @@
-; Version No is currently 4.2.0
+; Version No is currently 4.3.0
; Check before use
[Setup]
AppName=libSBML
-AppVerName=libSBML 4.2.0
+AppVerName=libSBML 4.3.0
AppPublisher=SBML Team
AppPublisherURL=http://sbml.org
AppSupportURL=http://sbml.org
AppUpdatesURL=http://sbml.org
-DefaultDirName={pf}\SBML\libSBML-4.2.0-libxml2-x86
+DefaultDirName={pf}\SBML\libSBML-4.3.0-libxml2-x86
DefaultGroupName=libSBML
DisableProgramGroupPage=yes
OutputDir=.\Output
-OutputBaseFilename=libSBML-4.2.0-win-libxml2-x86
+OutputBaseFilename=libSBML-4.3.0-win-libxml2-x86
WizardSmallImageFile=.\graphics\libsbml-installer-mini-logo.bmp
WizardImageFile=.\graphics\libsbml-installer-graphic.bmp
UsePreviousAppDir=no
@@ -29,18 +29,14 @@
Source: C:\libsbml_trunk\dev\utilities\win_installer\libsbml\bindings\matlab\*; DestDir: {code:GetMatlabDir}; Flags: ignoreversion recursesubdirs createallsubdirs; Check: GetMatlab
Source: C:\libsbml_trunk\dev\utilities\win_installer\libsbml\bindings\octave\*; DestDir: {code:GetOctaveDir}; Flags: ignoreversion recursesubdirs createallsubdirs; Check: GetOctave
Source: C:\libsbml_trunk\dev\utilities\win_installer\libsbml\bindings\csharp\*; DestDir: {code:GetCSharpDir}; Flags: ignoreversion recursesubdirs createallsubdirs; Check: GetCSharp
-Source: C:\libsbml_trunk\dev\utilities\win_installer\libsbml\bindings\python\python25\libsbml.py; DestDir: {code:GetPython25Dir}; Check: GetPython25
-Source: C:\libsbml_trunk\dev\utilities\win_installer\libsbml\bindings\python\python25\_libsbml.pyd; DestDir: {code:GetPython25Dir}; Check: GetPython25
-Source: C:\libsbml_trunk\dev\utilities\win_installer\libsbml\bindings\python\python26\libsbml.py; DestDir: {code:GetPython26Dir}; Check: GetPython26
Source: C:\libsbml_trunk\dev\utilities\win_installer\libsbml\bindings\perl\*; DestDir: {code:GetPerlDir}; Flags: ignoreversion recursesubdirs createallsubdirs; Check: GetPerl
-Source: C:\libsbml_trunk\dev\utilities\win_installer\libsbml\bindings\python\python26\_libsbml.pyd; DestDir: {code:GetPython26Dir}; Check: GetPython26
[Registry]
Root: HKCU; Subkey: Software\SBML; Flags: uninsdeletekeyifempty
Root: HKCU; Subkey: Software\SBML\libSBML; Flags: uninsdeletekey
Root: HKLM; Subkey: Software\SBML; Flags: uninsdeletekeyifempty
Root: HKLM; Subkey: Software\SBML\libSBML; Flags: uninsdeletekey
-Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: Version; ValueData: 4.2.0
+Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: Version; ValueData: 4.3.0
Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: InstallPath; ValueData: {app}
[Code]
@@ -59,6 +55,7 @@
Python25Present: Boolean;
Python26Present: Boolean;
PythonPresent: Boolean;
+ Python27Present: Boolean;
MatlabVersion: String;
MatlabRoot: String;
CSharpRoot: String;
@@ -153,6 +150,25 @@
Result := Root;
end;
+{function to return python 2.6 dir directory}
+function GetPython27Dir(S : String): String;
+var
+ Root:String;
+ Key: String;
+
+begin
+ Key := '';
+ Root := '';
+ Key := Key + 'Software\Python\PythonCore\2.7\InstallPath\';
+ if RegQueryStringValue(HKLM, Key, '', Root) then begin
+ Root:= Root + 'Lib\site-packages\';
+ Python27Present := True;
+ end else begin
+ Python27Present := False;
+ end;
+ Result := Root;
+end;
+
function GetJavaDir(Param: String): String;
begin
{ Return the selected DataDir }
@@ -220,7 +236,7 @@
Note: it includes a version number
**********************************************************************************************************}
- MsgBox('This setup installs the Windows version of libSBML 4.2.0 built using the libxml2 2.7.3 XML Parser library. All the necessary libraries are included. The source code is available as a separate download.', mbInformation, mb_Ok);
+ MsgBox('This setup installs the Windows version of libSBML 4.3.0 built using the libxml2 2.7.3 XML Parser library. All the necessary libraries are included. The source code is available as a separate download.', mbInformation, mb_Ok);
{ MsgBox('This setup installs the Windows release of libSBML 3.0.2 built using the Expat XML Parser libraries. All the necessary libraries are included. The source code is available as a seperate download.', mbInformation, mb_Ok); }
end;
@@ -237,11 +253,11 @@
begin
{get data from system}
PreviousInstalledVersion := GetVersion();
- ThisVersion := '4.2.0';
+ ThisVersion := '4.3.0';
MatlabRoot := GetMatlabRoot('');
GetPython25Dir('');
GetPython26Dir('');
- if (not Python25Present) and (not Python26Present) then begin
+ if (not Python25Present) and (not Python26Present) and (not Python27Present) then begin
PythonPresent := False;
end else begin
PythonPresent := True;
@@ -297,8 +313,8 @@
'Select the version of python you wish to install', True, False);
PythonPage.Add('Python 2.5');
PythonPage.Add('Python 2.6');
+ PythonPage.Add('Python 2.7');
-
{ perl page : location to install perl binding }
PerlPage := CreateInputDirPage(InstallOptionsPage.ID,
'Perl binding', '',
@@ -379,6 +395,7 @@
case GetPreviousData('PythonVers', '') of
'Python 2.5': PythonPage.SelectedValueIndex := 0;
'Python 2.6': PythonPage.SelectedValueIndex := 1;
+ 'Python 2.7': PythonPage.SelectedValueIndex := 2;
else
PythonPage.SelectedValueIndex := 1;
end;
@@ -459,6 +476,7 @@
case PythonPage.SelectedValueIndex of
0: PythonVers := 'Python 2.5';
1: PythonVers := 'Python 2.6';
+ 2: PythonVers := 'Python 2.7';
end;
SetPreviousData(PreviousDataKey, 'PythonVers', PythonVers);
@@ -534,6 +552,8 @@
MsgBox('Python 2.5 cannot be detected on the system. Cannot install to site-packages directory.', mbInformation, MB_OK);
end else if (not Python26Present) and (PythonPage.SelectedValueIndex = 1) then begin
MsgBox('Python 2.6 cannot be detected on the system. Cannot install to site-packages directory.', mbInformation, MB_OK);
+ end else if (not Python27Present) and (PythonPage.SelectedValueIndex = 2) then begin
+ MsgBox('Python 2.7 cannot be detected on the system. Cannot install to site-packages directory.', mbInformation, MB_OK);
end;
Result := True;
@@ -620,6 +640,11 @@
S := S + 'Writing libSBML Python 2.6 files to site-packages directory' + NewLine;
S := S + ' ' + GetPython26Dir('');
S := S + NewLine;
+ end else if (PythonPage.SelectedValueIndex = 2) then begin
+ S := S + NewLine;
+ S := S + 'Writing libSBML Python 2.7 files to site-packages directory' + NewLine;
+ S := S + ' ' + GetPython27Dir('');
+ S := S + NewLine;
end;
end else begin
S := S + NewLine;
@@ -635,7 +660,15 @@
Result:= S;
end;
-{ function to return flag as to whether to write libraries to system directory}
+{ function to return flag as to whether to write libraries to other directories directory}
+function GetPython27() : Boolean;
+begin
+ if (InstallOptionsPage.Values[5] = True) and (PythonPage.SelectedValueIndex = 2) then
+ Result := True
+ else
+ Result := False;
+end;
+
function GetPython26() : Boolean;
begin
if (InstallOptionsPage.Values[5] = True) and (PythonPage.SelectedValueIndex = 1) then
@@ -710,3 +743,10 @@
{ Return the selected DataDir }
Result := OctavePage.Values[0];
end;
+
+[Run]
+
+Filename: "{app}\bindings\python\libsbml-4.3.0.win32-py2.5.exe"; flags: nowait; Check: GetPython25;
+Filename: "{app}\bindings\python\libsbml-4.3.0.win32-py2.6.exe"; flags: nowait; Check: GetPython26;
+Filename: "{app}\bindings\python\libsbml-4.3.0.win32-py2.7.exe"; flags: nowait; Check: GetPython27;
+
Modified: trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss
===================================================================
--- trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss 2011-02-25 14:16:39 UTC (rev 13047)
+++ trunk/libsbml/dev/utilities/win_installer/install_libsbml_script_xml_win64.iss 2011-02-25 14:31:49 UTC (rev 13048)
@@ -1,19 +1,19 @@
-; Version No is currently 4.2.0
+; Version No is currently 4.3.0
; Check before use
[Setup]
AppName=libSBML
-AppVerName=libSBML 4.2.0
+AppVerName=libSBML 4.3.0
AppPublisher=SBML Team
AppPublisherURL=http://sbml.org
AppSupportURL=http://sbml.org
AppUpdatesURL=http://sbml.org
-DefaultDirName={pf}\SBML\libSBML-4.2.0-libxml2-x64
+DefaultDirName={pf}\SBML\libSBML-4..0-libxml2-x64
DefaultGroupName=libSBML
DisableProgramGroupPage=yes
OutputDir=.\Output
-OutputBaseFilename=libSBML-4.2.0-win-libxml2-x64
+OutputBaseFilename=libSBML-4.3.0-win-libxml2-x64
WizardSmallImageFile=.\graphics\libsbml-installer-mini-logo.bmp
WizardImageFile=.\graphics\libsbml-installer-graphic.bmp
UsePreviousAppDir=no
@@ -29,18 +29,14 @@
Source: C:\libsbml\dev\utilities\win_installer\libsbml\bindings\java\*; DestDir: {code:GetJavaDir}; Flags: ignoreversion recursesubdirs createallsubdirs; Check: GetJava
Source: C:\libsbml\dev\utilities\win_installer\libsbml\bindings\matlab\*; DestDir: {code:GetMatlabDir}; Flags: ignoreversion recursesubdirs createallsubdirs; Check: GetMatlab
Source: C:\libsbml\dev\utilities\win_installer\libsbml\bindings\csharp\*; DestDir: {code:GetCSharpDir}; Flags: ignoreversion recursesubdirs createallsubdirs; Check: GetCSharp
-Source: C:\libsbml\dev\utilities\win_installer\libsbml\bindings\python\python25\libsbml.py; DestDir: {code:GetPython25Dir}; Check: GetPython25
-Source: C:\libsbml\dev\utilities\win_installer\libsbml\bindings\python\python25\_libsbml.pyd; DestDir: {code:GetPython25Dir}; Check: GetPython25
-Source: C:\libsbml\dev\utilities\win_installer\libsbml\bindings\python\python26\libsbml.py; DestDir: {code:GetPython26Dir}; Check: GetPython26
Source: C:\libsbml\dev\utilities\win_installer\libsbml\bindings\perl\*; DestDir: {code:GetPerlDir}; Flags: ignoreversion recursesubdirs createallsubdirs; Check: GetPerl
-Source: C:\libsbml\dev\utilities\win_installer\libsbml\bindings\python\python26\_libsbml.pyd; DestDir: {code:GetPython26Dir}; Check: GetPython26
[Registry]
Root: HKCU; Subkey: Software\SBML; Flags: uninsdeletekeyifempty
Root: HKCU; Subkey: Software\SBML\libSBML; Flags: uninsdeletekey
Root: HKLM; Subkey: Software\SBML; Flags: uninsdeletekeyifempty
Root: HKLM; Subkey: Software\SBML\libSBML; Flags: uninsdeletekey
-Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: Version; ValueData: 4.2.0
+Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: Version; ValueData: 4.3.0
Root: HKLM; Subkey: Software\SBML\libSBML; ValueType: string; ValueName: InstallPath; ValueData: {app}
[Code]
@@ -59,6 +55,7 @@
Python25Present: Boolean;
Python26Present: Boolean;
PythonPresent: Boolean;
+ Python27Present: Boolean;
MatlabVersion: String;
MatlabRoot: String;
CSharpRoot: String;
@@ -153,6 +150,24 @@
Result := Root;
end;
+{function to return python 2.6 dir directory}
+function GetPython27Dir(S : String): String;
+var
+ Root:String;
+ Key: String;
+
+begin
+ Key := '';
+ Root := '';
+ Key := Key + 'Software\Python\PythonCore\2.7\InstallPath\';
+ if RegQueryStringValue(HKLM, Key, '', Root) then begin
+ Root:= Root + 'Lib\site-packages\';
+ Python27Present := True;
+ end else begin
+ Python27Present := False;
+ end;
+ Result := Root;
+end;
function GetJavaDir(Param: String): String;
begin
{ Return the selected DataDir }
@@ -220,7 +235,7 @@
Note: it includes a version number
**********************************************************************************************************}
- MsgBox('This setup installs the Windows version of libSBML 4.2.0 built using the libxml2 2.7.3 XML Parser library. All the necessary libraries are included. The source code is available as a separate download.', mbInformation, mb_Ok);
+ MsgBox('This setup installs the Windows version of libSBML 4.3.0 built using the libxml2 2.7.3 XML Parser library. All the necessary libraries are included. The source code is available as a separate download.', mbInformation, mb_Ok);
{ MsgBox('This setup installs the Windows release of libSBML 3.0.2 built using the Expat XML Parser libraries. All the necessary libraries are included. The source code is available as a seperate download.', mbInformation, mb_Ok); }
end;
@@ -237,11 +252,11 @@
begin
{get data from system}
PreviousInstalledVersion := GetVersion();
- ThisVersion := '4.2.0';
+ ThisVersion := '4.3.0';
MatlabRoot := GetMatlabRoot('');
GetPython25Dir('');
GetPython26Dir('');
- if (not Python25Present) and (not Python26Present) then begin
+ if (not Python26Present) and (not Python27Present) then begin
PythonPresent := False;
end else begin
PythonPresent := True;
@@ -295,10 +310,10 @@
PythonPage := CreateInputOptionPage(InstallOptionsPage.ID,
'Python binding', '',
'Select the version of python you wish to install', True, False);
- PythonPage.Add('Python 2.5');
+ {PythonPage.Add('Python 2.5'); }
PythonPage.Add('Python 2.6');
+ PythonPage.Add('Python 2.7');
-
{ perl page : location to install perl binding }
PerlPage := CreateInputDirPage(InstallOptionsPage.ID,
'Perl binding', '',
@@ -377,8 +392,9 @@
{python page}
case GetPreviousData('PythonVers', '') of
- 'Python 2.5': PythonPage.SelectedValueIndex := 0;
- 'Python 2.6': PythonPage.SelectedValueIndex := 1;
+ { 'Python 2.5': PythonPage.SelectedValueIndex := 0; }
+ 'Python 2.6': PythonPage.SelectedValueIndex := 0;
+ 'Python 2.7': PythonPage.SelectedValueIndex := 1;
else
PythonPage.SelectedValueIndex := 1;
end;
@@ -457,8 +473,9 @@
{python page}
case PythonPage.SelectedValueIndex of
- 0: PythonVers := 'Python 2.5';
- 1: PythonVers := 'Python 2.6';
+ { 0: PythonVers := 'Python 2.5'; }
+ 0: PythonVers := 'Python 2.6';
+ 1: PythonVers := 'Python 2.7';
end;
SetPreviousData(PreviousDataKey, 'PythonVers', PythonVers);
@@ -530,10 +547,12 @@
if not PythonPresent then begin
MsgBox('Python cannot be detected on the system. Cannot install to site-packages directory.', mbInformation, MB_OK);
InstallOptionsPage.Values[4] := False;
- end else if (not Python25Present) and (PythonPage.SelectedValueIndex = 0) then begin
- MsgBox('Python 2.5 cannot be detected on the system. Cannot install to site-packages directory.', mbInformation, MB_OK);
- end else if (not Python26Present) and (PythonPage.SelectedValueIndex = 1) then begin
+ { end else if (not Python25Present) and (PythonPage.SelectedValueIndex = 0) then begin
+ MsgBox('Python 2.5 cannot be detected on the system. Cannot install to site-packages directory.', mbInformation, MB_OK); }
+ end else if (not Python26Present) and (PythonPage.SelectedValueIndex = 0) then begin
MsgBox('Python 2.6 cannot be detected on the system. Cannot install to site-packages directory.', mbInformation, MB_OK);
+ end else if (not Python27Present) and (PythonPage.SelectedValueIndex = 1) then begin
+ MsgBox('Python 2.7 cannot be detected on the system. Cannot install to site-packages directory.', mbInformation, MB_OK);
end;
Result := True;
@@ -611,15 +630,20 @@
if (InstallOptionsPage.Values[4] = True) then begin
if (PythonPage.SelectedValueIndex = 0) then begin
- S := S + NewLine;
+{ S := S + NewLine;
S := S + 'Writing libSBML Python 2.5 files to site-packages directory' + NewLine;
S := S + ' ' + GetPython25Dir('');
S := S + NewLine;
- end else if (PythonPage.SelectedValueIndex = 1) then begin
+ end else if (PythonPage.SelectedValueIndex = 1) then begin }
S := S + NewLine;
S := S + 'Writing libSBML Python 2.6 files to site-packages directory' + NewLine;
S := S + ' ' + GetPython26Dir('');
S := S + NewLine;
+ end else if (PythonPage.SelectedValueIndex = 1) then begin
+ S := S + NewLine;
+ S := S + 'Writing libSBML Python 2.7 files to site-packages directory' + NewLine;
+ S := S + ' ' + GetPython27Dir('');
+ S := S + NewLine;
end;
end else begin
S := S + NewLine;
@@ -635,7 +659,14 @@
Result:= S;
end;
-{ function to return flag as to whether to write libraries to system directory}
+{ function to return flag as to whether to write libraries to other directories directory}
+function GetPython27() : Boolean;
+begin
+ if (InstallOptionsPage.Values[4] = True) and (PythonPage.SelectedValueIndex = 2) then
+ Result := True
+ else
+ Result := False;
+end;
function GetPython26() : Boolean;
begin
if (InstallOptionsPage.Values[4] = True) and (PythonPage.SelectedValueIndex = 1) then
@@ -710,3 +741,8 @@
{ Return the selected DataDir }
Result := OctavePage.Values[0];
end;
+[Run]
+
+Filename: "{app}\bindings\python\libsbml-4.3.0.win64-py2.6.exe"; flags: nowait; Check: GetPython26;
+Filename: "{app}\bindings\python\libsbml-4.3.0.win64-py2.7.exe"; flags: nowait; Check: GetPython27;
+
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <nik...@us...> - 2011-02-25 14:16:49
|
Revision: 13047
http://sbml.svn.sourceforge.net/sbml/?rev=13047&view=rev
Author: niko-rodrigue
Date: 2011-02-25 14:16:39 +0000 (Fri, 25 Feb 2011)
Log Message:
-----------
almost removed all the use of DOM objects to replace them by jsbml objects, it is compiling, need to make it works now svn st
Modified Paths:
--------------
trunk/sbmleditor/TODO.txt
trunk/sbmleditor/build.xml
trunk/sbmleditor/src/edu/ucla/sscnet/levine/jex/parser/MathMLParser.java
trunk/sbmleditor/src/edu/ucla/sscnet/levine/jex/parser/MathMLTokenParser.java
trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/SBMLJex.java
trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/SBMLJexPane.java
trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/event/JexAddNewSBMLElementActionListener.java
trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/event/JexSetMathItemListener.java
trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/parser/MathMLParser.java
trunk/sbmleditor/src/uk/ac/ebi/ontology/sbo/SBOReader.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/Main.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLDocument.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLDocumentJTree.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLDocumentProcessor.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLEditor.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLElementJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLNodeFilter.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLNodeTreeCellRenderer.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLNodeValueProcessor.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLSBaseFilter.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLSBaseValueProcessor.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLSchema.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLSchema_1_1.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/action/AddChildAction.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/action/CreateContextMenu.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/action/OpenSBMLElementJDialogAction.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/AlgebraicRuleJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/AnnotationJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/AssignmentRuleJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/CompartmentJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/CompartmentTypeJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/CompartmentVolumeRuleJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/ConstraintJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/DelayJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/EventAssignmentJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/EventJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/FunctionDefinitionJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/IdAndNameJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/InitialAssignmentJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/KineticLawJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/MathFieldJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/ModelJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/ModifierSpeciesReferenceJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/ParameterJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/ParameterRuleJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/RateRuleJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/ReactionJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/RelationRDFJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/RulesJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/SpeciesConcentrationRuleJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/SpeciesJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/SpeciesReferenceJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/SpeciesTypeJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/TextElementJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/UnitDefinitionJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/UnitJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/dialog/VCardRDFJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/extension/SBMLEditorExtension.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/extension/multistate/stochsim/StochSimMultistateExtension.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/ComplexTypeJComboBox.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBaseFactory.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBaseFilter.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBaseJDialog.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBaseProcessor.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBaseRemover.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBaseValueProcessor.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/TagTypeJComboBox.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/UnitJComboBox.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/sbw/SBWEditor.java
Added Paths:
-----------
trunk/sbmleditor/lib/jsbml-0.8-b1-with-dependencies.jar
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBMLElementFactory.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/tree/
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/tree/AttributeTreeNode.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/tree/SBMLMutableTreeNode.java
Removed Paths:
-------------
trunk/sbmleditor/src/org/sbml/
trunk/sbmleditor/src/uk/ac/ebi/ontology/sbo/MathCreateRule.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLTemplate.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/RDFElementUtilities.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBMLElementUtilities.java
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBML_level1v2.tmpl
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBML_level2.tmpl
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBML_level2v1.tmpl
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBML_level2v2.tmpl
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBML_level2v3.tmpl
trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/helper/SBML_level2v4.tmpl
Modified: trunk/sbmleditor/TODO.txt
===================================================================
--- trunk/sbmleditor/TODO.txt 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/TODO.txt 2011-02-25 14:16:39 UTC (rev 13047)
@@ -3,6 +3,14 @@
- support for SBML level 3 and his packages
+ - update the possible tag names to include reaction and any other like speciesReferences.
+ - update the Event dialog to integrate the new constructs.
+ - update the model dialog
+ - update the reaction dialog to add the compartment JComboBox for L3
+ - update the miriam qualifiers
+
+ - check that we put only valid id in the UnitJComboBox
+
- integrate the Biomodels.net converters
- improved support for SBO : tree of the ontology with search,
@@ -16,5 +24,5 @@
- Display/Hide individual annotation/notes/math
- - Offer the possiblility to change the id of an SBMl element. The function should update
+ - Offer the possibility to change the id of an SBMl element. The function should update
any references to the old id in the SBML file to avoid any inconsistency.
Modified: trunk/sbmleditor/build.xml
===================================================================
--- trunk/sbmleditor/build.xml 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/build.xml 2011-02-25 14:16:39 UTC (rev 13047)
@@ -22,7 +22,7 @@
<format property="YEAR" pattern="yyyy"/>
</tstamp>
<property name="Name" value="SBMLeditor"/>
- <property name="version" value="1.3.4"/>
+ <property name="version" value="2.0-dev"/>
<property name="year" value="${YEAR}"/>
<property name="name" value="SBMLeditor"/>
@@ -67,12 +67,13 @@
<path id="sbml.classpath">
<pathelement location="${jars.dir}/compneur-2.1.jar" />
<pathelement location="${jars.dir}/junit.jar" />
- <pathelement location="${jars.dir}/xml-apis.jar" />
- <pathelement location="${jars.dir}/xercesImpl.jar" />
+<!-- <pathelement location="${jars.dir}/xml-apis.jar" />
+ <pathelement location="${jars.dir}/xercesImpl.jar" /> -->
<pathelement location="${jars.dir}/SBWCore.jar" />
- <pathelement location="${jars.dir}/libsbml-3.1.x-utils.jar" />
- <pathelement location="${jars.dir}/libsbmlj-3.1.x.jar" />
+<!-- <pathelement location="${jars.dir}/libsbml-3.1.x-utils.jar" />
+ <pathelement location="${jars.dir}/libsbmlj-3.1.x.jar" /> -->
<pathelement location="${jars.dir}/log4j-1.2.15.jar" />
+ <pathelement location="${jars.dir}/jsbml-0.8-b1-with-dependencies.jar" />
</path>
</target>
@@ -125,8 +126,7 @@
<fileset
dir="${src.dir}"
excludes="**/CVS*, **/*.class, **/*~, **/*.tgz,
- **/TestLibSBMLJ.java, **/*.zip, org/**,
- **/*SBase*.java, uk/ac/ebi/ontology/**, **/.*, **/*~,
+ **/TestLibSBMLJ.java, **/*.zip, org/**, uk/ac/ebi/ontology/**, **/.*, **/*~,
uk/ac/ebi/sbml/editor/helper/LibSBMLUtilities.java, uk/ac/ebi/sbml/editor/extension/**">
</fileset>
</copy>
Added: trunk/sbmleditor/lib/jsbml-0.8-b1-with-dependencies.jar
===================================================================
(Binary files differ)
Property changes on: trunk/sbmleditor/lib/jsbml-0.8-b1-with-dependencies.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/sbmleditor/src/edu/ucla/sscnet/levine/jex/parser/MathMLParser.java
===================================================================
--- trunk/sbmleditor/src/edu/ucla/sscnet/levine/jex/parser/MathMLParser.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/edu/ucla/sscnet/levine/jex/parser/MathMLParser.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -26,7 +26,10 @@
import java.util.regex.Matcher;
import java.util.regex.Pattern;
-import uk.ac.ebi.sbml.editor.helper.LibSBMLUtilities;
+import org.sbml.jsbml.JSBML;
+import org.sbml.jsbml.text.parser.ParseException;
+
+// import uk.ac.ebi.sbml.editor.helper.LibSBMLUtilities;
import edu.ucla.sscnet.levine.jex.Jex;
import edu.ucla.sscnet.levine.jex.layout.MathBox;
import edu.ucla.sscnet.levine.jex.layout.RowBox;
@@ -125,8 +128,14 @@
*/
public String parseInfixFormula(String formula) {
- String mathMLString = LibSBMLUtilities.infixToMathML(formula);
-
+ String mathMLString = null; // LibSBMLUtilities.infixToMathML(formula);
+ try {
+ mathMLString = JSBML.parseFormula(formula).toMathML();
+ } catch (ParseException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+
return mathMLString;
}
Modified: trunk/sbmleditor/src/edu/ucla/sscnet/levine/jex/parser/MathMLTokenParser.java
===================================================================
--- trunk/sbmleditor/src/edu/ucla/sscnet/levine/jex/parser/MathMLTokenParser.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/edu/ucla/sscnet/levine/jex/parser/MathMLTokenParser.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -1,9 +1,10 @@
package edu.ucla.sscnet.levine.jex.parser;
-import org.w3c.dom.Element;
+import org.sbml.jsbml.MathContainer;
+
/**
* @author rodrigue
*
@@ -14,7 +15,7 @@
public class MathMLTokenParser {
- private Element mathElement = null;
+ private MathContainer mathElement = null;
private String mathMLString;
@@ -28,7 +29,7 @@
}
- public Element getMathMLElement() {
+ public MathContainer getMathMLElement() {
return mathElement;
}
Modified: trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/SBMLJex.java
===================================================================
--- trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/SBMLJex.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/SBMLJex.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -28,9 +28,11 @@
import java.awt.GridLayout;
import java.awt.event.KeyListener;
import java.io.BufferedReader;
+import java.io.ByteArrayInputStream;
import java.io.File;
import java.io.FileInputStream;
import java.io.InputStreamReader;
+import java.io.StringBufferInputStream;
import javax.swing.JButton;
import javax.swing.JFileChooser;
@@ -40,13 +42,10 @@
import javax.swing.JMenuItem;
import javax.swing.JPanel;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.xml.sax.SAXParseException;
+import org.sbml.jsbml.MathContainer;
+import org.sbml.jsbml.SBMLReader;
import uk.ac.ebi.compneur.util.CustomJDialogFacade;
-import uk.ac.ebi.compneur.xml.JAXPFacade;
-import uk.ac.ebi.compneur.xml.ListErrorHandler;
import uk.ac.ebi.compneur.xml.ui.XMLJFileChooser;
import uk.ac.ebi.mathml.editor.event.JexAddNewSBMLElementActionListener;
import uk.ac.ebi.mathml.editor.event.JexAddSBMLIdItemListener;
@@ -55,7 +54,6 @@
import uk.ac.ebi.sbml.editor.SBMLDocument;
import uk.ac.ebi.sbml.editor.SBMLEditor;
import uk.ac.ebi.sbml.editor.helper.ComplexTypeJComboBox;
-import uk.ac.ebi.sbml.editor.helper.LibSBMLUtilities;
import uk.ac.ebi.sbml.editor.helper.TagTypeJComboBox;
import edu.ucla.sscnet.levine.jex.Jex;
import edu.ucla.sscnet.levine.jex.JexPane;
@@ -74,7 +72,7 @@
public String selectedSBMLElementId;
- public Element selectedSBMLElement;
+ public MathContainer selectedSBMLElement;
public ComplexTypeJComboBox complexTypeJComboBox;
@@ -317,49 +315,30 @@
public static SBMLDocument openSBMLFile(BufferedReader sbmlStream)
throws Exception {
- Document document_ = null;
SBMLDocument sbmlDocument = null;
if (sbmlStream != null) {
- ListErrorHandler error_handler = new ListErrorHandler();
-
- document_ = JAXPFacade.getInstance().create(sbmlStream, true);
+ SBMLReader reader = new SBMLReader();
+ org.sbml.jsbml.SBMLDocument document = reader.readSBMLFromStream(new StringBufferInputStream(sbmlStream.toString()));
sbmlStream.close();
long validationErrors = 0;
- if (LibSBMLUtilities.isLibSBMLAvailable()) {
- validationErrors = LibSBMLUtilities.validate(document_);
- }
+ // TODO : replace
+// if (LibSBMLUtilities.isLibSBMLAvailable()) {
+// validationErrors = LibSBMLUtilities.validate(document_);
+// }
+
// boolean document_tobesaved = false;
- sbmlDocument = new SBMLDocument(document_, false);
+ sbmlDocument = new SBMLDocument(document, false);
- boolean sbmlEditorValidate = true;
- try {
- sbmlDocument.validate();
- } catch (RuntimeException e) {
- sbmlEditorValidate = false;
- }
-
- if (validationErrors > 0 || !sbmlEditorValidate) {
+ if (validationErrors > 0) {
CustomJDialogFacade.showErrorDialog(null,
"Your document contain some errors", "MathSBMLeditor",
true);
// return;
}
-
- if (!error_handler.isEmpty()) {
- SAXParseException[] errors = error_handler.toArray();
- for (int i = 0; i < errors.length; ++i) {
- String[] message = new String[3];
- message[0] = errors[i].toString();
- message[1] = "Line: " + errors[i].getLineNumber();
- message[2] = "URI: " + errors[i].getSystemId();
- CustomJDialogFacade.showErrorDialog(null, message,
- "SBMLeditor", true);
- }
- }
}
return sbmlDocument;
Modified: trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/SBMLJexPane.java
===================================================================
--- trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/SBMLJexPane.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/SBMLJexPane.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -33,7 +33,8 @@
import javax.swing.JFileChooser;
import javax.swing.JOptionPane;
-import org.w3c.dom.Element;
+import org.sbml.jsbml.KineticLaw;
+import org.sbml.jsbml.Reaction;
import uk.ac.ebi.compneur.xml.ui.XMLJFileChooser;
import uk.ac.ebi.mathml.editor.event.JexSetMathItemListener;
@@ -174,29 +175,18 @@
SBMLDocument.debug("JexPane : doAction(Update TagType JComboBox)");
SBMLDocument sbmlDocument = jex.sbmlDocument;
- String elementTagName = jex.selectedSBMLElement.getTagName();
+ String elementTagName = jex.selectedSBMLElement.getElementName();
boolean needLocalParam = false;
boolean foundLocalParam = false;
- if (elementTagName.endsWith("math")) {
- Element grandParent = (Element) jex.selectedSBMLElement.getParentNode().getParentNode();
-
- if (grandParent.getTagName().equals(SBMLDocument.REACTION_TAG_NAME)) {
- needLocalParam = true;
- jex.addSBMLNameTagTypeJComboBox.setReaction(grandParent);
- jex.selectedSBMLElementId = grandParent.getAttribute(sbmlDocument.getIdAttributeName());
- }
- } else if (elementTagName.equals(SBMLDocument.REACTION_TAG_NAME)) {
+ if (jex.selectedSBMLElement instanceof KineticLaw) {
+
needLocalParam = true;
- jex.addSBMLNameTagTypeJComboBox.setReaction(jex.selectedSBMLElement);
- jex.selectedSBMLElementId = jex.selectedSBMLElement.getAttribute(sbmlDocument.getIdAttributeName());
- } else if (elementTagName.equals(SBMLDocument.KINETIC_LAW_TAG_NAME)) {
- needLocalParam = true;
- Element reactionElement = (Element) jex.selectedSBMLElement.getParentNode();
- jex.addSBMLNameTagTypeJComboBox.setReaction(reactionElement);
- jex.selectedSBMLElementId = reactionElement.getAttribute(sbmlDocument.getIdAttributeName());
- }
+ jex.addSBMLNameTagTypeJComboBox.setReaction((Reaction) jex.selectedSBMLElement.getParentSBMLObject());
+ jex.selectedSBMLElementId = ((Reaction) jex.selectedSBMLElement.getParentSBMLObject()).getId();
+
+ }
if (needLocalParam) {
jex.insideReaction = true;
@@ -248,14 +238,17 @@
}
if (jex.selectedSBMLElement != null) {
- jex.sbmlDocument.setMathMLString(jex.selectedSBMLElement, mathMLString);
- if (!jex.selectedSBMLElement.getTagName().equals(SBMLDocument.KINETIC_LAW_TAG_NAME)) {
- jex.sbmlDocument.updateElementReferences(jex.selectedSBMLElement);
- } else {
- jex.sbmlDocument.updateElementReferences((Element) jex.selectedSBMLElement.getParentNode());
- }
+ // TODO : update
+ // jex.sbmlDocument.setMathMLString(jex.selectedSBMLElement, mathMLString);
+
+// if (!jex.selectedSBMLElement.getTagName().equals(SBMLDocument.KINETIC_LAW_TAG_NAME)) {
+// jex.sbmlDocument.updateElementReferences(jex.selectedSBMLElement);
+// } else {
+// jex.sbmlDocument.updateElementReferences((Element) jex.selectedSBMLElement.getParentNode());
+// }
+
// replace the specific element not to have to refresh everything
jex.sbmlEditor.updateDocumentTree(jex.selectedSBMLElement);
Modified: trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/event/JexAddNewSBMLElementActionListener.java
===================================================================
--- trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/event/JexAddNewSBMLElementActionListener.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/event/JexAddNewSBMLElementActionListener.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -27,7 +27,7 @@
import javax.swing.JOptionPane;
-import org.w3c.dom.Element;
+import org.sbml.jsbml.MathContainer;
import uk.ac.ebi.mathml.editor.SBMLJex;
import uk.ac.ebi.sbml.editor.SBMLDocument;
@@ -52,8 +52,8 @@
public void actionPerformed(ActionEvent e) {
// display a choice of tag name
- Element selectedElement = jex.selectedSBMLElement;
- String elementTagName = selectedElement.getTagName();
+ MathContainer selectedElement = jex.selectedSBMLElement;
+ String elementTagName = selectedElement.getElementName();
if (elementTagName.equals(SBMLDocument.FUNCTION_DEFINITION_TAG_NAME)) {
Modified: trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/event/JexSetMathItemListener.java
===================================================================
--- trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/event/JexSetMathItemListener.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/event/JexSetMathItemListener.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -55,8 +55,11 @@
String id = ((ComplexTypeJComboBox) e.getSource()).getSelectedId();
- String mathMLStr = sbmlDocument.getMathMLStringById(id);
+ String mathMLStr = null; // TODO : sbmlDocument.getMathMLStringById(id);
+ SBMLDocument.debug("JexSetMathItemListener : itemStateChanged : you need to implement something here !!!");
+
+
if (mathMLStr != null) {
//SBMLDocument.debug("JexSetMathItemListener : mathMLStr = " + mathMLStr);
Modified: trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/parser/MathMLParser.java
===================================================================
--- trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/parser/MathMLParser.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/uk/ac/ebi/mathml/editor/parser/MathMLParser.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -27,13 +27,15 @@
import java.util.regex.Matcher;
import java.util.regex.Pattern;
-import org.w3c.dom.Element;
+import org.sbml.jsbml.JSBML;
+import org.sbml.jsbml.MathContainer;
+import org.sbml.jsbml.SBMLException;
+import org.sbml.jsbml.text.parser.ParseException;
import uk.ac.ebi.mathml.editor.SBMLJex;
import uk.ac.ebi.mathml.editor.SBMLJexPane;
import uk.ac.ebi.sbml.editor.SBMLDocument;
import uk.ac.ebi.sbml.editor.SBMLSchema;
-import uk.ac.ebi.sbml.editor.helper.LibSBMLUtilities;
import edu.ucla.sscnet.levine.jex.Jex;
import edu.ucla.sscnet.levine.jex.layout.CharBox;
import edu.ucla.sscnet.levine.jex.layout.MathBox;
@@ -75,7 +77,7 @@
this.mathMLStr = mathMLStr;
stack = new Stack();
- Element selectedElement = this.jex.selectedSBMLElement;
+ MathContainer selectedElement = this.jex.selectedSBMLElement;
if (selectedElement != null) {
insideReaction = this.jex.insideReaction;
@@ -148,7 +150,13 @@
} else if (m.find() && xmlMatcher.find()){
SBMLDocument.debug(" uk.MathMLParser : parse (MathML) : mathML found.");
- formula = LibSBMLUtilities.mathMLToInfix(mathMLString);
+ try {
+ formula = JSBML.formulaToString(JSBML.readMathMLFromString(mathMLString));
+ } catch (SBMLException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+
if (emptyMath.find() || emptyMathLibSBML.find()) {
// There was a problem with libsbml call
formula = "";
@@ -355,8 +363,15 @@
SBMLDocument.debug(" MATMLParser : parseInfixFormula : formula with ids = " + formula);
- String mathMLString = LibSBMLUtilities.infixToMathML(formula);
-
+ String mathMLString = null; // LibSBMLUtilities.infixToMathML(formula);
+ try {
+ mathMLString = JSBML.parseFormula(formula).toMathML();
+ } catch (ParseException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+
+
SBMLDocument.debug(" MATMLParser : parseInfixFormula : mathMLformula = " + mathMLString);
Deleted: trunk/sbmleditor/src/uk/ac/ebi/ontology/sbo/MathCreateRule.java
===================================================================
--- trunk/sbmleditor/src/uk/ac/ebi/ontology/sbo/MathCreateRule.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/uk/ac/ebi/ontology/sbo/MathCreateRule.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -1,32 +0,0 @@
-package uk.ac.ebi.ontology.sbo;
-
-import javax.xml.parsers.ParserConfigurationException;
-
-import org.apache.commons.digester.NodeCreateRule;
-import org.w3c.dom.Element;
-
-public class MathCreateRule extends NodeCreateRule {
-
- MathCreateRule() throws ParserConfigurationException {
- super();
- }
-
- public void end() {
- Object mathElement = digester.peek();
-
- if (mathElement instanceof Element) {
- SBOTerm currentSBOTerm = (SBOTerm) digester.peek(1);
-
- String math = null;
-
- // TODO transform element into a string
- currentSBOTerm.setMath(math);
- }
-
- try {
- super.end(); // remove the element from the stack
- } catch (Exception e) {
- e.printStackTrace();
- }
- }
-}
Modified: trunk/sbmleditor/src/uk/ac/ebi/ontology/sbo/SBOReader.java
===================================================================
--- trunk/sbmleditor/src/uk/ac/ebi/ontology/sbo/SBOReader.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/uk/ac/ebi/ontology/sbo/SBOReader.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -8,19 +8,11 @@
import java.io.File;
import java.io.FileReader;
import java.io.IOException;
-import java.io.InputStreamReader;
import java.util.TreeMap;
-import javax.xml.parsers.ParserConfigurationException;
-
-import org.apache.commons.digester.Digester;
-import org.apache.commons.digester.xmlrules.DigesterLoader;
-import org.xml.sax.InputSource;
import org.xml.sax.SAXException;
public class SBOReader {
-
- private final static String APACHE_DIGESTER_RULES_FILE_NAME = "sbo-digester-rules.xml";
/**
* @param fileName
@@ -70,12 +62,8 @@
public static TreeMap read(BufferedReader reader)
throws IOException, SAXException
{
- BufferedReader digesterRules = null;
-
- digesterRules = new BufferedReader(new InputStreamReader(SBOReader.class
- .getResourceAsStream(APACHE_DIGESTER_RULES_FILE_NAME)));
-
- return read(reader, digesterRules);
+ // TODO
+ return null;
}
/**
@@ -90,19 +78,8 @@
throws IOException, SAXException
{
- Digester digester =
- DigesterLoader.createDigester(new InputSource(digesterRulesReader));
-
- try {
-
- digester.setValidating(false);
-
- digester.addRule("sbo/Term/math", new MathCreateRule());
- } catch (ParserConfigurationException e) {
- e.printStackTrace();
- }
-
- TreeMap sboTreeMap = (TreeMap) digester.parse(reader);
+ // TODO
+ TreeMap sboTreeMap = null;
return sboTreeMap;
}
Modified: trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/Main.java
===================================================================
--- trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/Main.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/Main.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -23,12 +23,10 @@
package uk.ac.ebi.sbml.editor;
import javax.swing.JFrame;
-import javax.swing.JOptionPane;
import javax.swing.UIManager;
import uk.ac.ebi.compneur.util.ImageIconMap;
import uk.ac.ebi.miriam.db.MIRIAMDatabase;
-import uk.ac.ebi.sbml.editor.helper.LibSBMLUtilities;
import uk.ac.ebi.sbml.editor.sbw.SBWEditor;
import uk.ac.ebi.sbml.editor.sbw.SBWEditorService;
import edu.caltech.sbw.ModuleImpl;
@@ -72,17 +70,17 @@
initImageIconMap();
- boolean isLibSBMLAvailable = LibSBMLUtilities.isLibSBMLAvailable();
+// boolean isLibSBMLAvailable = LibSBMLUtilities.isLibSBMLAvailable();
+//
+// if (!isLibSBMLAvailable) {
+// JOptionPane.showMessageDialog(null, "You are running SBMLeditor without having libSBML installed on your system.\n\n" +
+// "SBMLeditor will have some limitations :\n" +
+// "\t - you will not be able to use the graphical equation editor.\n" +
+// "\t - the validation of your model will not be complete. SBMLeditor is not implementing all the consistency rules done by libSBML.\n" +
+// "\t - you will not be able to convert your models to other SBML levels and versions.\n" +
+// "\n You can download libSBML from http://sbml.org/software/libsbml");
+// }
- if (!isLibSBMLAvailable) {
- JOptionPane.showMessageDialog(null, "You are running SBMLeditor without having libSBML installed on your system.\n\n" +
- "SBMLeditor will have some limitations :\n" +
- "\t - you will not be able to use the graphical equation editor.\n" +
- "\t - the validation of your model will not be complete. SBMLeditor is not implementing all the consistency rules done by libSBML.\n" +
- "\t - you will not be able to convert your models to other SBML levels and versions.\n" +
- "\n You can download libSBML from http://sbml.org/software/libsbml");
- }
-
if (args.length > 0) {
Modified: trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLDocument.java
===================================================================
--- trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLDocument.java 2011-02-25 13:42:19 UTC (rev 13046)
+++ trunk/sbmleditor/src/uk/ac/ebi/sbml/editor/SBMLDocument.java 2011-02-25 14:16:39 UTC (rev 13047)
@@ -25,32 +25,39 @@
package uk.ac.ebi.sbml.editor;
import java.awt.Color;
-import java.io.ByteArrayInputStream;
-import java.io.UnsupportedEncodingException;
import java.text.NumberFormat;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
-import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.List;
-import java.util.Map;
import java.util.Set;
import java.util.regex.Matcher;
-import org.w3c.dom.Attr;
-import org.w3c.dom.DOMException;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
+import org.sbml.jsbml.Compartment;
+import org.sbml.jsbml.CompartmentType;
+import org.sbml.jsbml.Event;
+import org.sbml.jsbml.EventAssignment;
+import org.sbml.jsbml.ExplicitRule;
+import org.sbml.jsbml.FunctionDefinition;
+import org.sbml.jsbml.KineticLaw;
+import org.sbml.jsbml.ListOf;
+import org.sbml.jsbml.LocalParameter;
+import org.sbml.jsbml.MathContainer;
+import org.sbml.jsbml.Model;
+import org.sbml.jsbml.ModifierSpeciesReference;
+import org.sbml.jsbml.NamedSBase;
+import org.sbml.jsbml.Parameter;
+import org.sbml.jsbml.Reaction;
+import org.sbml.jsbml.Rule;
+import org.sbml.jsbml.SBase;
+import org.sbml.jsbml.Species;
+import org.sbml.jsbml.SpeciesReference;
+import org.sbml.jsbml.SpeciesType;
+import org.sbml.jsbml.UnitDefinition;
-import uk.ac.ebi.compneur.xml.ElementUtilities;
-import uk.ac.ebi.compneur.xml.JAXPFacade;
-import uk.ac.ebi.compneur.xml.ListErrorHandler;
-import uk.ac.ebi.sbml.editor.helper.SBMLElementUtilities;
+
/**
* Contains functions to validate and keep the consistency of an SBML document.
*
@@ -62,6 +69,7 @@
*
*/
+@SuppressWarnings("deprecation")
public final class SBMLDocument {
public static final boolean debug = false;
@@ -132,19 +140,19 @@
//
//
/**
- * <code>name_to_listof_map</code>: an SBML tag name as key and the
+ * <code>nameToListOfMap</code>: an SBML tag name as key and the
* corresponding SBML container as value
*/
/**
- * <code>listof_to_name_map</code>: an SBML container as key and the
+ * <code>listOfToNameMap</code>: an SBML container as key and the
* corresponding SBML tag name as value
*/
/**
* <code>listOfToNamesMap</code>: an SBML container as key and a list of
* child SBML tag names as value
*/
- private static HashMap name_to_listof_map, listof_to_name_map,
- listOfToNamesMap;
+ private static HashMap<String, String> nameToListOfMap, listOfToNameMap;
+ private static HashMap<String, String[]> listOfToNamesMap;
/**
* list of rules for SBML level 1
@@ -155,16 +163,16 @@
*/
private static String[] rules_l2;
/**
- * list of all mathML element that have allways no child.
+ * list of all mathML element that have always no child.
*/
- private static ArrayList mathSingleEl;
+ private static ArrayList<String> mathSingleEl;
/**
* list of <code>predefinedUnits</code> in the <a
* href="http://sbml.org/specifications/sbml-level-2/version-1/html/sbml-level-2.html#tab:builtin">SBML
* specifications </a>
*/
- public static ArrayList predefinedUnits;
+ public static ArrayList<String> predefinedUnits;
static {
@@ -174,46 +182,46 @@
rules_l2 = new String[] { "algebraicRule",
"assignmentRule", "rateRule"};
- name_to_listof_map = new HashMap();
- name_to_listof_map.put("model", "listOfUnitDefinitions");
- name_to_listof_map.put("model", "listOfCompartments");
- name_to_listof_map.put("model", "listOfFunctionDefinitions");
- name_to_listof_map.put("model", "listOfSpecies");
- name_to_listof_map.put("model", "listOfParameters");
- name_to_listof_map.put("model", "listOfRules");
- name_to_listof_map.put("model", "listOfReactions");
- name_to_listof_map.put("model", "listOfEvents");
- name_to_listof_map.put("specie", "listOfSpecies");
- name_to_listof_map.put("species", "listOfSpecies");
- name_to_listof_map.put("compartment", "listOfCompartments");
- name_to_listof_map.put("algebraicRule", "listOfRules");
- name_to_listof_map.put("speciesConcentrationRule", "listOfRules");
- name_to_listof_map.put("compartmentVolumeRule", "listOfRules");
- name_to_listof_map.put("parameterRule", "listOfRules");
- name_to_listof_map.put("assignmentRule", "listOfRules");
- name_to_listof_map.put("rateRule", "listOfRules");
- name_to_listof_map.put("parameter", "listOfParameters");
- name_to_listof_map.put("reaction", "listOfReactions");
- name_to_listof_map.put("kineticLaw", "reaction");
- name_to_listof_map.put("speciesReference", "listOfReactants");
- name_to_listof_map.put("speciesReference", "listOfProducts");
- name_to_listof_map.put("modifierSpeciesReference", "listOfModifiers");
- name_to_listof_map.put("unit", "listOfUnits");
- name_to_listof_map.put("listOfUnits", "unitDefinition");
- name_to_listof_map.put("unitDefinition", "listOfUnitDefinitions");
- name_to_listof_map.put("functionDefinition",
+ nameToListOfMap = new HashMap<String, String>();
+ nameToListOfMap.put("model", "listOfUnitDefinitions");
+ nameToListOfMap.put("model", "listOfCompartments");
+ nameToListOfMap.put("model", "listOfFunctionDefinitions");
+ nameToListOfMap.put("model", "listOfSpecies");
+ nameToListOfMap.put("model", "listOfParameters");
+ nameToListOfMap.put("model", "listOfRules");
+ nameToListOfMap.put("model", "listOfReactions");
+ nameToListOfMap.put("model", "listOfEvents");
+ nameToListOfMap.put("specie", "listOfSpecies");
+ nameToListOfMap.put("species", "listOfSpecies");
+ nameToListOfMap.put("compartment", "listOfCompartments");
+ nameToListOfMap.put("algebraicRule", "listOfRules");
+ nameToListOfMap.put("speciesConcentrationRule", "listOfRules");
+ nameToListOfMap.put("compartmentVolumeRule", "listOfRules");
+ nameToListOfMap.put("parameterRule", "listOfRules");
+ nameToListOfMap.put("assignmentRule", "listOfRules");
+ nameToListOfMap.put("rateRule", "listOfRules");
+ nameToListOfMap.put("parameter", "listOfParameters");
+ nameToListOfMap.put("reaction", "listOfReactions");
+ nameToListOfMap.put("kineticLaw", "reaction");
+ nameToListOfMap.put("speciesReference", "listOfReactants");
+ nameToListOfMap.put("speciesReference", "listOfProducts");
+ nameToListOfMap.put("modifierSpeciesReference", "listOfModifiers");
+ nameToListOfMap.put("unit", "listOfUnits");
+ nameToListOfMap.put("listOfUnits", "unitDefinition");
+ nameToListOfMap.put("unitDefinition", "listOfUnitDefinitions");
+ nameToListOfMap.put("functionDefinition",
"listOfFunctionDefinitions");
- name_to_listof_map.put("event", "listOfEvents");
- name_to_listof_map.put("eventAssignment", "listOfEventAssignments");
- name_to_listof_map.put(COMPARTMENT_TYPE_TAG_NAME, "listOfCompartmentTypes");
- name_to_listof_map.put(SPECIES_TYPE_TAG_NAME, "listOfSpeciesTypes");
- name_to_listof_map.put(INITIAL_ASSIGNMENT_TAG_NAME, "listOfInitialAssignments");
- name_to_listof_map.put(CONSTRAINT_TAG_NAME, "listOfConstraints");
+ nameToListOfMap.put("event", "listOfEvents");
+ nameToListOfMap.put("eventAssignment", "listOfEventAssignments");
+ nameToListOfMap.put(COMPARTMENT_TYPE_TAG_NAME, "listOfCompartmentTypes");
+ nameToListOfMap.put(SPECIES_TYPE_TAG_NAME, "listOfSpeciesTypes");
+ nameToListOfMap.put(INITIAL_ASSIGNMENT_TAG_NAME, "listOfInitialAssignments");
+ nameToListOfMap.put(CONSTRAINT_TAG_NAME, "listOfConstraints");
- listof_to_name_map = new HashMap();
- listOfToNamesMap = new HashMap();
- listof_to_name_map.put("listOfSpecies", "species");
- listof_to_name_map.put("listOfCompartments", "compartment");
+ listOfToNameMap = new HashMap<String, String>();
+ listOfToNamesMap = new HashMap<String, String[]>();
+ listOfToNameMap.put("listOfSpecies", "species");
+ listOfToNameMap.put("listOfCompartments", "compartment");
listOfToNamesMap.put("listOfRules", rules_l1);
listOfToNamesMap.put("listOfRules_2", rules_l2);
listOfToNamesMap.put("model", new String[] { NOTES_TAG_NAME, ANNOTATION_TAG_NAME,
@@ -224,30 +232,30 @@
"listOfSpecies", "listOfParameters", "listOfRules", "listOfReactions",
"listOfEvents"});
- listof_to_name_map.put("listOfParameters", "parameter");
- listof_to_name_map.put("listOfReactions", "reaction");
- listof_to_name_map.put("reaction", "kineticLaw");
- listof_to_name_map.put("listOfReactants", "speciesReference");
- listof_to_name_map.put("listOfProducts", "speciesReference");
- listof_to_name_map.put("listOfModifiers", "modifierSpeciesReference");
- listof_to_name_map.put("listOfUnits", "unit");
- listof_to_name_map.put("unitDefinition", "listOfUnits");
- listof_to_name_map.put("listOfUnitDefinitions", "unitDefinition");
- listof_to_name_map.put("listOfFunctionDefinitions", "functionDefinition");
- listof_to_name_map.put("listOfEvents", "event");
- listof_to_name_map.put("listOfEventAssignments", "eventAssignment");
- listof_to_name_map.put("listOfCompartmentTypes", COMPARTMENT_TYPE_TAG_NAME);
- listof_to_name_map.put("listOfSpeciesTypes", SPECIES_TYPE_TAG_NAME);
- listof_to_name_map.put("listOfInitialAssignments", INITIAL_ASSIGNMENT_TAG_NAME);
- listof_to_name_map.put("listOfConstraints", CONSTRAINT_TAG_NAME);
+ listOfToNameMap.put("listOfParameters", "parameter");
+ listOfToNameMap.put("listOfReactions", "reaction");
+ listOfToNameMap.put("reaction", "kineticLaw");
+ listOfToNameMap.put("listOfReactants", "speciesReference");
+ listOfToNameMap.put("listOfProducts", "speciesReference");
+ listOfToNameMap.put("listOfModifiers", "modifierSpeciesReference");
+ listOfToNameMap.put("listOfUnits", "unit");
+ listOfToNameMap.put("unitDefinition", "listOfUnits");
+ listOfToNameMap.put("listOfUnitDefinitions", "unitDefinition");
+ listOfToNameMap.put("listOfFunctionDefinitions", "functionDefinition");
+ listOfToNameMap.put("listOfEvents", "event");
+ listOfToNameMap.put("listOfEventAssignments", "eventAssignment");
+ listOfToNameMap.put("listOfCompartmentTypes", COMPARTMENT_TYPE_TAG_NAME);
+ listOfToNameMap.put("listOfSpeciesTypes", SPECIES_TYPE_TAG_NAME);
+ listOfToNameMap.put("listOfInitialAssignments", INITIAL_ASSIGNMENT_TAG_NAME);
+ listOfToNameMap.put("listOfConstraints", CONSTRAINT_TAG_NAME);
- mathSingleEl = new ArrayList(SBMLSchema.MATHML_ARITHMETIC_OPERATORS);
+ mathSingleEl = new ArrayList<String>(SBMLSchema.MATHML_ARITHMETIC_OPERATORS);
mathSingleEl.addAll(SBMLSchema.MATHML_RELATIONAL_OPERATORS);
mathSingleEl.addAll(SBMLSchema.MATHML_TRIGOMNOMETRIC_OPERATORS);
mathSingleEl.addAll(SBMLSchema.MATHML_LOGICAL_OPERATORS);
- predefinedUnits = new ArrayList(5);
+ predefinedUnits = new ArrayList<String>(5);
predefinedUnits.add("substance");
predefinedUnits.add("volume");
predefinedUnits.add("area");
@@ -259,101 +267,104 @@
* Contains an SBML SId or metaId as key and the corresponding name (or
* again the key if the name is not defined) as value
*/
- private HashMap idMap = new LinkedHashMap();
+ private HashMap<String, String> idMap = new LinkedHashMap<String, String>();
/**
* Contains all the metaIds of the current SBML document
*/
- private ArrayList metaidList = new ArrayList();
+ private ArrayList<String> metaidList = new ArrayList<String>();
/**
* Contains an SBML tag name as key and an Integer as value, corresponding
* to the last id created for this tag name
*/
- private HashMap idCountMap = new HashMap();
+ private HashMap<String, Integer> idCountMap = new HashMap<String, Integer>();
/**
* Contains an sbml id as key and an ArrayList of xmlPath where the id is
- * refered.
+ * referenced.
*/
- private HashMap idToRefsMap = new HashMap();
+ private HashMap<String, ArrayList<String>> idToRefsMap = new HashMap<String, ArrayList<String>>();
/**
* Contains an xmlPath as key and an ArrayList of sbml ids where the xmlPath
- * is refered.
+ * is referenced.
*
*/
- private HashMap refToIdsMap = new HashMap();
+ private HashMap<String, ArrayList<String>> refToIdsMap = new HashMap<String, ArrayList<String>>();
/**
* Contains all the FunctionDefinition SIds for the current document as key
* and the corresponding name (or again the key if the name is not defined)
* as value
*/
- private HashMap functionMap = new LinkedHashMap();
+ private HashMap<String, String> functionMap = new LinkedHashMap<String, String>();
/**
* Contains all the possible ids for a Unit for the current document
* (including all predefined units, all unit kind and all UnitDefinition
* SIds) as key and the corresponding name (or again the key if the name is
* not defined) as value
*/
- private HashMap unitMap = new LinkedHashMap();
+ private HashMap<String, String> unitMap = new LinkedHashMap<String, String>();
/**
* Contains all the UnitDefinition SIds for the current document as key and
* the corresponding name (or again the key if the name is not defined) as
* value
*/
- private HashMap unitDefinitionMap = new LinkedHashMap();
+ private HashMap<String, String> unitDefinitionMap = new LinkedHashMap<String, String>();
/**
* Contains all the global Parameter SIds for the current document as key
* and the corresponding name (or again the key if the name is not defined)
* as value
*/
- private HashMap parameterMap = new LinkedHashMap();
+ private HashMap<String, String> parameterMap = new LinkedHashMap<String, String>();
/**
* Contains a reactionId as key and an ArrayList of local Parameter SIds as
* value
*/
- private HashMap localParameterMap = new HashMap();
+ private HashMap<String, ArrayList<String>> localParameterMap = new HashMap<String, ArrayList<String>>();
/**
* Contains all the CompartmentType SIds for the current document as key and the
* corresponding name (or again the key if the name is not defined) as value
*/
- private HashMap compartmentTypeMap = new LinkedHashMap();
+ private HashMap<String, String> compartmentTypeMap = new LinkedHashMap<String, String>();
/**
* Contains all the Compartment SIds for the current document as key and the
* corresponding name (or again the key if the name is not defined) as value
*/
- private HashMap compartmentMap = new LinkedHashMap();
+ private HashMap<String, String> compartmentMap = new LinkedHashMap<String, String>();
/**
* Contains all the SpeciesType SIds for the current document as key and the
* corresponding name (or again the key if the name is not defined) as value
*/
- private HashMap speciesTypeMap = new LinkedHashMap();
+ private HashMap<String, String> speciesTypeMap = new LinkedHashMap<String, String>();
/**
* Contains all the Species SIds for the current document as key and the
* corresponding name (or again the key if the name is not defined) as value
*/
- private HashMap specieMap = new LinkedHashMap();
+ private HashMap<String, String> specieMap = new LinkedHashMap<String, String>();
/**
* Contains all the different Rules metaids for the current document as key
* and the corresponding name (or again the key if the name is not defined)
* as value // ?? : really used this ??
*/
- private HashMap ruleMap = new LinkedHashMap();
+ private HashMap<String, String> ruleMap = new LinkedHashMap<String, String>();
/**
* Contains all the Reaction SIds for the current document as key and the
* corresponding name (or again the key if the name is not defined) as value
*/
- private HashMap reactionMap = new LinkedHashMap();
+ private HashMap<String, String> reactionMap = new LinkedHashMap<String, String>();
/**
* Contains all the Event SIds or metaids for the current document as key
* and the corresponding name (or again the key if the name is not defined)
* as value // ?? : really used like this ??
*/
- private HashMap eventMap = new LinkedHashMap();
+ private HashMap<String, String> eventMap = new LinkedHashMap<String, String>();
+ private org.sbml.jsbml.SBMLDocument sbmlDocument;
+
+
private String idAttrName = "id";
private int sbmlLevel = 2;
private int sbmlVersion = 1;
@@ -384,22 +395,22 @@
}
/**
- * Initializes all the ids maps using the current <code>document_</code>
+ * Initializes all the ids maps using the current <code>JSBML SBMLDocument</code>
*
*/
private void initMaps() {
clearMaps();
- sbmlLevel = SBMLDocument.getSBMLLevel(document_);
- sbmlVersion = SBMLDocument.getSBMLVersion(document_);
+ sbmlLevel = sbmlDocument.getLevel();
+ sbmlVersion = sbmlDocument.getVersion();
if (sbmlLevel == 1) {
idAttrName = "name";
}
- String modelId = getModelElement().getAttribute(idAttrName);
- String modelName = getModelElement().getAttribute("name");
+ String modelId = sbmlDocument.getModel().getId();
+ String modelName = sbmlDocument.getModel().getName();
if (modelName == null || modelName.length() == 0) {
modelName = modelId;
}
@@ -410,32 +421,28 @@
initMetaidMap();
- initMap(functionMap, "name", FUNCTION_DEFINITION_TAG_NAME, "listOfFunctionDefinitions");
+ initMap(functionMap, getModelElement().getListOfFunctionDefinitions());
initUnitMap();
initGlobalParameterMap();
initLocalParameterMap();
- initMap(compartmentTypeMap, "name", COMPARTMENT_TYPE_TAG_NAME, "listOfCompartmentTypes");
+ initMap(compartmentTypeMap, getModelElement().getListOfCompartmentTypes());
- initMap(compartmentMap, "name", COMPARTMENT_TAG_NAME, "listOfCompartments");
+ initMap(compartmentMap, getModelElement().getListOfCompartments());
- if (sbmlLevel == 1 && sbmlVersion == 1) {
- SPECIES_TAG_NAME = "specie";
- }
+ initMap(specieMap, getModelElement().getListOfSpecies());
- initMap(specieMap, "name", SPECIES_TAG_NAME, "listOfSpecies");
+ initMap(speciesTypeMap, getModelElement().getListOfSpeciesTypes());
- initMap(speciesTypeMap, "name", SPECIES_TYPE_TAG_NAME, "listOfSpeciesTypes");
+ initMap(ruleMap, getModelElement().getListOfRules());
- if (sbmlLevel == 1) {
- initMap(ruleMap, "name", "parameterRule", "listOfRules");
- }
+ initMap(reactionMap, getModelElement().getListOfReactions());
- initMap(reactionMap, "name", "reaction", "listOfReactions");
+ initMap(eventMap, getModelElement().getListOfEvents());
- initMap(eventMap, "name", "event", "listOfEvents");
+ // TODO : add new SBML elements
idCountMap.put(UNIT_DEFINITION_TAG_NAME, new Integer(unitDefinitionMap.size()));
idCountMap.put(FUNCTION_DEFINITION_TAG_NAME, new Integer(functionMap.size()));
@@ -466,37 +473,30 @@
for (int i = 0; i < items.length; ++i) {
unitMap.put(items[i], items[i]);
}
- try {
- HashMap idsMap = getComplexTypeValueSNamesAndIds(document_,
- "listOfUnitDefinitions", "unitDefinition", "name");
-
- Object[] objs = idsMap.entrySet().toArray();
-
- for (int i = 0; i < objs.length; ++i) {
- String item = (String) ((Map.Entry) objs[i]).getValue();
- String key = (String) ((Map.Entry) objs[i]).getKey();
- // check that the id doesn't already exist !!
- if (unitMap.get(key) != null || idMap.get(key) != null) {
- throw new RuntimeException("id " + key + " already exist.");
- }
-
- // debug("initUnitMap : unitDefId = " + key);
-
- unitMap.put(key, item);
- unitDefinitionMap.put(key, item);
- idMap.put(key, item); // Not necessary because Unit in a
- // different nameSpace ???
- }
- } catch (DOMException e) {
- debug("initUnitMap : " + e.getMessage()); // should not happen
- }
-
+
int predefUnitLength = SBMLDocument.predefinedUnits.size();
for (int i = 0; i < predefUnitLength; i++) {
- String predefinedUnit = (String) predefinedUnits.get(i);
+ String predefinedUnit = predefinedUnits.get(i);
unitMap.put(predefinedUnit, predefinedUnit);
}
+
+ ListOf<UnitDefinition> listOfUnitDefinitions = sbmlDocument.getModel().getListOfUnitDefinitions();
+
+ for (UnitDefinition unitDefinition : listOfUnitDefinitions) {
+ String id = unitDefinition.getId();
+ String name = unitDefinition.getName();
+
+ // debug("initUnitMap : unitDefId = " + key);
+
+ // TODO : check if the name is defined ??
+
+ unitMap.put(id, name);
+ unitDefinitionMap.put(id, name);
+ idMap.put(id, name); // Not necessary because Unit in a
+ // different nameSpace ???
+
+ }
}
@@ -507,26 +507,7 @@
* All ids are added also to the <code>idMap</code>
*/
private void initGlobalParameterMap() {
- try {
- HashMap idsMap = getGlobalParameterSNamesAndIds(document_);
-
- Object[] objs = idsMap.entrySet().toArray();
-
- for (int i = 0; i < objs.length; ++i) {
- String item = (String) ((Map.Entry) objs[i]).getValue();
- String key = (String) ((Map.Entry) objs[i]).getKey();
-
- // check that the id doesn't already exist !!
- if (unitMap.get(key) != null || idMap.get(key) != null) {
- throw new RuntimeException("id " + key + " already exist.");
- }
-
- idMap.put(key, item);
- parameterMap.put(key, item);
- }
- } catch (DOMException e) {
- debug(e.getMessage());
- }
+ initMap(parameterMap, getModelElement().getListOfParameters());
}
/**
@@ -536,59 +517,42 @@
* corresponding reaction SId. <br>
* All ids are added also to the <code>parameterMap</code> with
* reactionSId:parameterSId as key and the local parameter SId as value
- * Could be added also to the <code>idMap</code> like that but not used
- * for the moment on this form, so not really necessary yet.
+ * <br/>Also added to the <code>idMap</code>.
*
*/
private void initLocalParameterMap() {
- try {
- // get all reactions
- NodeList reactions = document_.getElementsByTagName(REACTION_TAG_NAME);
-
- for (int i = 0; i < reactions.getLength(); i++) {
- Element reaction = (Element) reactions.item(i);
- String reactionId = reaction.getAttribute(idAttrName);
+ // loop over all reactions
+ for (Reaction reaction : getModelElement().getListOfReactions()) {
+
+ String reactionId = reaction.getId();
+ ArrayList<String> localParamIds = new ArrayList<String>();
+ KineticLaw kineticLaw = reaction.getKineticLaw();
- ArrayList localParamIds = new ArrayList();
- List kineticLaws = ElementUtilities.getChildElementsByName(reaction, KINETIC_LAW_TAG_NAME);
-
- if (kineticLaws.size() == 0) {
- continue;
- }
-
- List listOfParameters = ElementUtilities.getChildElementsByName((Element) kineticLaws.get(0),
- "listOfParameters");
-
- if (listOfParameters.size() == 0) {
- continue;
- }
- Element listOfParameter = (Element) listOfParameters.get(0);
- List parameters = ElementUtilities.getChildElementsByName(listOfParameter, PARAMETER_TAG_NAME);
-
- // debug("\ninitLocalParameterMap : reactionId = " + reactionId + "\n");
-
- for (int j = 0; j < parameters.size(); j++) {
- Element parameter = (Element) parameters.get(j);
- String parameterId = parameter.getAttribute(idAttrName);
- String parameterName = parameter.getAttribute("name");
-
- if (parameterName == null || parameterName.length() == 0) {
- parameterName = parameterId;
- }
-
- // debug("initLocalParameterMap : parameterId = " + parameterId);
-
- localParamIds.add(parameterId);
-
- parameterMap.put(reactionId + ":" + parameterId, parameterName);
- }
- localParameterMap.put(reactionId, localParamIds);
- }
-
- } catch (DOMException e) {
- debug(e.getMessage());
- }
+ if (kineticLaw == null) {
+ continue;
+ }
+
+ // debug("\ninitLocalParameterMap : reactionId = " + reactionId + "\n");
+
+ for (LocalParameter parameter : kineticLaw.getListOfLocalParameters()) {
+
+ String parameterId = parameter.getId();
+ String parameterName = parameter.getName();
+
+ if (parameterName == null || parameterName.length() == 0) {
+ parameterName = parameterId;
+ }
+
+ // debug("initLocalParameterMap : parameterId = " + parameterId);
+
+ localParamIds.add(parameterId);
+
+ parameterMap.put(reactionId + ":" + parameterId, parameterName);
+ idMap.put(reactionId + ":" + parameterId, parameterName);
+ }
+ localParameterMap.put(reactionId, localParamIds);
+ }
}
/**
@@ -601,6 +565,8 @@
*/
private void initMetaidMap() {
+ // TODO : update
+
String[] tagNames = {MODEL_TAG_NAME, FUNCTION_DEFINITION_TAG_NAME,
UNIT_DEFINITION_TAG_NAME, UNIT_TAG_NAME, COMPARTMENT_TAG_NAME, SPECIES_TAG_NAME,
PARAMETER_TAG_NAME, REACTION_TAG_NAME, EVENT_TAG_NAME, KINETIC_LAW_TAG_NAME,
@@ -632,6 +598,10 @@
* @param tagNames
*/
private void addMetaIds(String[] tagNames) {
+
+ // TODO : implement
+
+ /*
for(int i = 0; i < tagNames.length; i++) {
NodeList nodes = document_.getElementsByTagName(tagNames[i]);
@@ -651,6 +621,7 @@
}
}
}
+ */
}
/**
@@ -672,45 +643,40 @@
}
/**
- * Populates an HashMap with all the childs nodes of the
- * <code>listOfName</code> element, if this element is found. All ids are
+ * Populates an HashMap with all the children of the
+ * <code>listOf</code> element. All ids are
* added also to the <code>idMap</code>
*
- * @see getComplexTypeValueSNamesAndIds
- *
* @param elementMap
* the HashMap where to put the found SIds
- * @param idName
- * the name of the id tag name (name for level 1, id for level 2)
- * @param elementName
- * the name of the child tag to look for in the childs of the
- * <code>listOfMap</code>
- * @param listOfName
- * the name of the container to search.
+ * @param listOf the list of SBase.
*/
- private void initMap(HashMap elementMap, String idName, String elementName, String listOfName) {
- try {
- HashMap idsMap = SBMLDocument
- .getComplexTypeValueSNamesAndIds(document_,
- listOfName, elementName, idName);
-
- Object[] objs = idsMap.entrySet().toArray();
-
- for (int i = 0; i < objs.length; ++i) {
- ...
[truncated message content] |