Class Fmi2SimulationEnvironment
- java.lang.Object
-
- org.intocps.maestro.framework.fmi2.Fmi2SimulationEnvironment
-
- All Implemented Interfaces:
org.intocps.maestro.framework.core.ISimulationEnvironment
public class Fmi2SimulationEnvironment extends java.lang.Object implements org.intocps.maestro.framework.core.ISimulationEnvironment
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classFmi2SimulationEnvironment.Relationstatic classFmi2SimulationEnvironment.Variable
-
Constructor Summary
Constructors Modifier Constructor Description protectedFmi2SimulationEnvironment(Fmi2SimulationEnvironmentConfiguration msg)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static java.util.List<ModelConnection>buildConnections(java.util.Map<java.lang.String,java.util.List<java.lang.String>> connections)voidcheck(org.intocps.maestro.core.messages.IErrorReporter reporter)java.util.List<RelationVariable>getConnectedOutputs()java.lang.StringgetFaultInjectionConfigurationPath()java.util.Set<java.util.Map.Entry<java.lang.String,org.intocps.maestro.fmi.Fmi2ModelDescription>>getFmusWithModelDescriptions()java.util.Set<java.util.Map.Entry<java.lang.String,java.net.URI>>getFmuToUri()ComponentInfogetInstanceByLexName(java.lang.String lexName)java.util.Set<java.util.Map.Entry<java.lang.String,ComponentInfo>>getInstances()java.util.Map<java.lang.String,java.util.List<java.lang.String>>getLogLevels()org.intocps.maestro.fmi.Fmi2ModelDescriptiongetModelDescription(java.lang.String name)java.util.Set<Fmi2SimulationEnvironment.Relation>getRelations(java.lang.String... identifiers)java.util.Set<Fmi2SimulationEnvironment.Relation>getRelations(java.util.List<org.intocps.maestro.ast.LexIdentifier> identifiers)Finds all the relations for the given FMU Component LexIdentifiersjava.util.Set<Fmi2SimulationEnvironment.Relation>getRelations(org.intocps.maestro.ast.LexIdentifier... identifiers)Finds all the relations for the given FMU Component LexIdentifiers<T extends org.intocps.maestro.framework.core.FrameworkUnitInfo>
TgetUnitInfo(org.intocps.maestro.ast.LexIdentifier identifier, org.intocps.maestro.core.Framework framework)java.net.URIgetUriFromFMUName(java.lang.String fmuName)java.util.List<RelationVariable>getVariablesToLog(java.lang.String instanceName)Retrieves all variables that should be logged for the given instance.static Fmi2SimulationEnvironmentof(java.io.File file, org.intocps.maestro.core.messages.IErrorReporter reporter)static Fmi2SimulationEnvironmentof(java.io.InputStream inputStream, org.intocps.maestro.core.messages.IErrorReporter reporter)static Fmi2SimulationEnvironmentof(Fmi2SimulationEnvironmentConfiguration msg, org.intocps.maestro.core.messages.IErrorReporter reporter)voidsetLexNameToInstanceNameMapping(java.lang.String lexName, java.lang.String instanceName)
-
-
-
Constructor Detail
-
Fmi2SimulationEnvironment
protected Fmi2SimulationEnvironment(Fmi2SimulationEnvironmentConfiguration msg) throws java.lang.Exception
- Throws:
java.lang.Exception
-
-
Method Detail
-
of
public static Fmi2SimulationEnvironment of(java.io.File file, org.intocps.maestro.core.messages.IErrorReporter reporter) throws java.lang.Exception
- Throws:
java.lang.Exception
-
of
public static Fmi2SimulationEnvironment of(Fmi2SimulationEnvironmentConfiguration msg, org.intocps.maestro.core.messages.IErrorReporter reporter) throws java.lang.Exception
- Throws:
java.lang.Exception
-
of
public static Fmi2SimulationEnvironment of(java.io.InputStream inputStream, org.intocps.maestro.core.messages.IErrorReporter reporter) throws java.lang.Exception
- Throws:
java.lang.Exception
-
buildConnections
public static java.util.List<ModelConnection> buildConnections(java.util.Map<java.lang.String,java.util.List<java.lang.String>> connections) throws java.lang.Exception
- Throws:
java.lang.Exception
-
getConnectedOutputs
public java.util.List<RelationVariable> getConnectedOutputs()
- Specified by:
getConnectedOutputsin interfaceorg.intocps.maestro.framework.core.ISimulationEnvironment
-
setLexNameToInstanceNameMapping
public void setLexNameToInstanceNameMapping(java.lang.String lexName, java.lang.String instanceName)
-
getInstanceByLexName
public ComponentInfo getInstanceByLexName(java.lang.String lexName)
-
getVariablesToLog
public java.util.List<RelationVariable> getVariablesToLog(java.lang.String instanceName)
Retrieves all variables that should be logged for the given instance. This is a combination of specified logvariables and connected outputs- Specified by:
getVariablesToLogin interfaceorg.intocps.maestro.framework.core.ISimulationEnvironment- Parameters:
instanceName-- Returns:
-
getFmusWithModelDescriptions
public java.util.Set<java.util.Map.Entry<java.lang.String,org.intocps.maestro.fmi.Fmi2ModelDescription>> getFmusWithModelDescriptions()
-
getInstances
public java.util.Set<java.util.Map.Entry<java.lang.String,ComponentInfo>> getInstances()
- Specified by:
getInstancesin interfaceorg.intocps.maestro.framework.core.ISimulationEnvironment
-
getFmuToUri
public java.util.Set<java.util.Map.Entry<java.lang.String,java.net.URI>> getFmuToUri()
-
getUriFromFMUName
public java.net.URI getUriFromFMUName(java.lang.String fmuName)
-
getLogLevels
public java.util.Map<java.lang.String,java.util.List<java.lang.String>> getLogLevels()
-
getRelations
public java.util.Set<Fmi2SimulationEnvironment.Relation> getRelations(java.util.List<org.intocps.maestro.ast.LexIdentifier> identifiers)
Finds all the relations for the given FMU Component LexIdentifiers- Specified by:
getRelationsin interfaceorg.intocps.maestro.framework.core.ISimulationEnvironment- Parameters:
identifiers- FMU Component LexIdentifiers- Returns:
-
getRelations
public java.util.Set<Fmi2SimulationEnvironment.Relation> getRelations(org.intocps.maestro.ast.LexIdentifier... identifiers)
Finds all the relations for the given FMU Component LexIdentifiers- Specified by:
getRelationsin interfaceorg.intocps.maestro.framework.core.ISimulationEnvironment- Parameters:
identifiers- FMU Component LexIdentifiers- Returns:
-
getRelations
public java.util.Set<Fmi2SimulationEnvironment.Relation> getRelations(java.lang.String... identifiers)
- Specified by:
getRelationsin interfaceorg.intocps.maestro.framework.core.ISimulationEnvironment
-
getUnitInfo
public <T extends org.intocps.maestro.framework.core.FrameworkUnitInfo> T getUnitInfo(org.intocps.maestro.ast.LexIdentifier identifier, org.intocps.maestro.core.Framework framework)- Specified by:
getUnitInfoin interfaceorg.intocps.maestro.framework.core.ISimulationEnvironment
-
check
public void check(org.intocps.maestro.core.messages.IErrorReporter reporter) throws java.lang.Exception- Specified by:
checkin interfaceorg.intocps.maestro.framework.core.ISimulationEnvironment- Throws:
java.lang.Exception
-
getModelDescription
public org.intocps.maestro.fmi.Fmi2ModelDescription getModelDescription(java.lang.String name)
-
getFaultInjectionConfigurationPath
public java.lang.String getFaultInjectionConfigurationPath()
-
-