Class SimulationScenarioAPI
Last update: 16.07.2025Namespace: VM.API.Pre
Assembly: VM.API.Pre.dll
This class implements APIs for scenario class.
public static class SimulationScenarioAPI
Inheritance
object ← SimulationScenarioAPI
Extension Methods
LinkPropertyItemCache.GetLinkProperties(object, LinkPropertyType), LinkPropertyItemCache.GetLinkPropertiesAndValues(object, LinkPropertyType), LinkPropertyItemCache.GetLinkedObjects<T>(object, LinkPropertyType)
Methods
CreateSimulationScenarioForActivate(SubSystemDocument, Obj, ExpressionValueVariable?, string, Sensor, Obj?, Sign, ScenarioActivateType, Motion)
Create
[NotNull(new string[] { "document" })]
[NotNullObj(new string[] { "target" })]
public static Obj CreateSimulationScenarioForActivate(this SubSystemDocument document, Obj target, ExpressionValueVariable? referenceValue = null, string name = "", Scenario.Sensor sensorType = Sensor.Time, Obj? function = null, Scenario.Sign sign = Sign.GreaterAndEqual, ScenarioActivateType eventType = ScenarioActivateType.Activate, Scenario.Motion subTarget = Motion.None)
Parameters
document SubSystemDocument
The document to create the simulation scenario.
target Obj
The enable target of the simulation scenario.
referenceValue ExpressionValueVariable?
The value of the simulation scenario.
name string
The name of the simulation scenario.
sensorType Scenario.Sensor
The sensor type of the simulation scenario.
function Obj?
The function of the simulation scenario.
sign Scenario.Sign
The sign type of the simulation scenario.
eventType ScenarioActivateType
The action type of the simulation scenario.
subTarget Scenario.Motion
The sub target of the simulation scenario.
Returns
The new
Exceptions
Will be thrown if 'document', 'target' is null.
Will be thrown if the type of 'function' is not
Will be thrown if the type of 'target' is not
CreateSimulationScenarioForBody(SubSystemDocument, Obj, ExpressionValueVariable?, string, Sensor, Obj?, Sign, ScenarioBodyType)
Create
[NotNull(new string[] { "document" })]
[NotNullObj(new string[] { "target" })]
public static Obj CreateSimulationScenarioForBody(this SubSystemDocument document, Obj target, ExpressionValueVariable? referenceValue = null, string name = "", Scenario.Sensor sensorType = Sensor.Time, Obj? function = null, Scenario.Sign sign = Sign.GreaterAndEqual, ScenarioBodyType eventType = ScenarioBodyType.SetToRigidBody)
Parameters
document SubSystemDocument
The document to create the simulation scenario.
target Obj
The enable target of the simulation scenario.
referenceValue ExpressionValueVariable?
The value of the simulation scenario.
name string
The name of the simulation scenario.
sensorType Scenario.Sensor
The sensor type of the simulation scenario.
function Obj?
The function of the simulation scenario.
sign Scenario.Sign
The sign type of the simulation scenario.
eventType ScenarioBodyType
The action type of the simulation scenario.
Returns
The new
Exceptions
Will be thrown if 'document', 'target' is null.
Will be thrown if the type of 'function' is not
Will be thrown if the type of 'target' is not
CreateSimulationScenarioForFile(SubSystemDocument, string, ExpressionValueVariable?, string, Sensor, Obj?, Sign, ScenarioFileType)
Create
[NotNull(new string[] { "document" })]
[ExistFile(new string[] { "targetFilePath" })]
public static Obj CreateSimulationScenarioForFile(this SubSystemDocument document, string targetFilePath, ExpressionValueVariable? referenceValue = null, string name = "", Scenario.Sensor sensorType = Sensor.Time, Obj? function = null, Scenario.Sign sign = Sign.GreaterAndEqual, ScenarioFileType eventType = ScenarioFileType.ExportIcfFile)
Parameters
document SubSystemDocument
The document to create the simulation scenario.
targetFilePath string
The ICF file path of the simulation scenario.
referenceValue ExpressionValueVariable?
The value of the simulation scenario.
name string
The name of the simulation scenario.
sensorType Scenario.Sensor
The sensor type of the simulation scenario.
function Obj?
The function of the simulation scenario.
sign Scenario.Sign
The sign type of the simulation scenario.
eventType ScenarioFileType
The action type of the simulation scenario.
Returns
The new
Exceptions
Will be thrown if 'document' is null.
Will be thrown if the type of 'function' is not
CreateSimulationScenarioForOutput(SubSystemDocument, ExpressionValueVariable?, ExpressionValueVariable?, string, Sensor, Obj?, Sign, ScenarioOutputType)
Create
[NotNull(new string[] { "document" })]
public static Obj CreateSimulationScenarioForOutput(this SubSystemDocument document, ExpressionValueVariable? target = null, ExpressionValueVariable? referenceValue = null, string name = "", Scenario.Sensor sensorType = Sensor.Time, Obj? function = null, Scenario.Sign sign = Sign.GreaterAndEqual, ScenarioOutputType eventType = ScenarioOutputType.SetMaximumStepsize)
Parameters
document SubSystemDocument
The document to create the simulation scenario.
target ExpressionValueVariable?
The action value of the simulation scenario.
referenceValue ExpressionValueVariable?
The value of the simulation scenario.
name string
The name of the simulation scenario.
sensorType Scenario.Sensor
The sensor type of the simulation scenario.
function Obj?
The function of the simulation scenario.
sign Scenario.Sign
The sign type of the simulation scenario.
eventType ScenarioOutputType
The action type of the simulation scenario.
Returns
The new
Exceptions
Will be thrown if 'document' is null.
Will be thrown if the type of 'function' is not
CreateSimulationScenarioForStop(SubSystemDocument, ExpressionValueVariable?, string, Sensor, Obj?, Sign)
Create
[NotNull(new string[] { "document" })]
public static Obj CreateSimulationScenarioForStop(this SubSystemDocument document, ExpressionValueVariable? referenceValue = null, string name = "", Scenario.Sensor sensorType = Sensor.Time, Obj? function = null, Scenario.Sign sign = Sign.GreaterAndEqual)
Parameters
document SubSystemDocument
The document to create the simulation scenario.
referenceValue ExpressionValueVariable?
The value of the simulation scenario.
name string
The name of the simulation scenario.
sensorType Scenario.Sensor
The sensor type of the simulation scenario.
function Obj?
The function of the simulation scenario.
sign Scenario.Sign
The sign type of the simulation scenario.
Returns
The new
Exceptions
Will be thrown if 'document' is null.
Will be thrown if the type of 'function' is not