org.openmodelica.simulation.core.models.simulation
Class SimulationSessionConfiguration

java.lang.Object
  extended by org.openmodelica.simulation.core.models.simulation.SimulationSessionConfiguration

public class SimulationSessionConfiguration
extends java.lang.Object

A Simulation Session Configuration will be used to specify needed modifications on model values or simulation settings for a single simulation session. The use has the possibility to create different session configurations to test a model and to archive the modifications. The modified model data will be stored in a SimConfig.xml The modified simulation settings will be stored in a SimSetting.xml

Author:
EADS Innovation Works, Parham Vasaiely, Parham.Vasaiely@gmx.de

Constructor Summary
SimulationSessionConfiguration(java.lang.String configurationName, java.lang.String initial_path)
          Use this constructor if you want to create a new config file reading the configs folder
SimulationSessionConfiguration(java.lang.String configurationName, java.lang.String comment, java.lang.String initial_path)
          Use this constructor if you want to create a new session config file from a wizard.
 
Method Summary
 java.lang.String getComment()
           
 java.lang.String getConfigurationName()
           
 ModelicaModel getModelicaModel()
          Returns the configured, modified modelica model used to simulate a model with diffrent data and settings
 SimulationSetting getSimSetting()
           
 void readModelicaModelConfigFile(java.lang.String initial_path)
          Reads a model configuration file which is store in the initial_path folder
 void readSimSetting(java.lang.String initial_path)
          Reads a simulation setting file which is store in the initial_path folder
 void setComment(java.lang.String comment)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SimulationSessionConfiguration

public SimulationSessionConfiguration(java.lang.String configurationName,
                                      java.lang.String comment,
                                      java.lang.String initial_path)
Use this constructor if you want to create a new session config file from a wizard. NOTE: To avoid Object reference problems: A Wizard should first create a SimConfig.xml and a SimSettig.xml. Afterwards this constructor can create a new object based on the XMLs The same can be done with a copy method but this is much more comfortable

Parameters:
configurationName - Name for this configuration file should be unique otherwise it will overwrite an existing session configuration file from a simulation project
comment - Specified comments for this simulation configuration
initial_path - Path to the folder containing the model configuration file "_SimConfig.xml" and the simulation setting file "_SimSetting.xml"

SimulationSessionConfiguration

public SimulationSessionConfiguration(java.lang.String configurationName,
                                      java.lang.String initial_path)
Use this constructor if you want to create a new config file reading the configs folder

Parameters:
configurationName - Name for this configuration file should be unique otherwise it will overwrite an existing session configuration file from a simulation project
initial_path - Path to the folder containing the model configuration file "_SimConfig.xml" and the simulation setting file "_SimSetting.xml"
Method Detail

getConfigurationName

public java.lang.String getConfigurationName()

getComment

public java.lang.String getComment()

setComment

public void setComment(java.lang.String comment)

readModelicaModelConfigFile

public void readModelicaModelConfigFile(java.lang.String initial_path)
Reads a model configuration file which is store in the initial_path folder

Parameters:
initial_path - folder which contains the simulation configuration file (_SimConfig.xml)

getModelicaModel

public ModelicaModel getModelicaModel()
Returns the configured, modified modelica model used to simulate a model with diffrent data and settings

Returns:
Configured Modelica model

readSimSetting

public void readSimSetting(java.lang.String initial_path)
Reads a simulation setting file which is store in the initial_path folder

Parameters:
initial_path - folder which contains the simulation configuration file (_SimSetting.xml)

getSimSetting

public SimulationSetting getSimSetting()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object