- Index
- » Users
- » yvaidya
- » Profile
Posts
Posts
Thanks Adeas,
I have sorted this problem now. There were few issues:
1. Not using fully qualified domain names for package
2. Package name was not referred correctly in the .mo file and
3. It helps a lot when you use default directory as I think JavaOMC apis has some issues in parsing windows absolute paths.
Kind regards,
Yogi
Dear all,
I am new to Modelica and JavaOMC Apis. I have two modelica files and I am able to load one file successfully, but not the second. First file starts with
package ABC***
and second has:
within Modelica.Fluid.Examples;
package ABC*** extends Modelica.Icons.ExamplesPackage;
I would like to know, if I have to make any specific method calls/ environment setup before I should parse the second. My brief code is as below
JavaOMCAPI omc = new JavaOMCApi()
omc.getStandardLibrary();
File file = new File(fileName);
if(file.exists() {
boolean result = omc.loadFile(file.getPath()); //loadFile returns zero for second file
if(result) {
String[] packages = omc.getPackages();
}
}
Please help.
Thanks in advance.
Kind regards,
Yogi
- Index
- » Users
- » yvaidya
- » Profile