Package com.nomagic.magicdraw.simulation
Class SimulationHelper
java.lang.Object
com.nomagic.magicdraw.simulation.SimulationHelper
The helper class of the cameo simulation toolkit.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic List<FeatureValue> findFeatureValue(CompoundValue runtimeContext, List<Property> propertyPath, Property target) Deprecated.getAvailableSignals(StructuredValue target, ExecutionEngine engine) Get availableSignals from the specified StructuredValue.static ElementgetConfigElement(SimulationExecution simulationExecution) Gets simulation config element from simulation execution.static SimulationExecutiongetExecution(Project project) Retrieves object representing ongoing SimulationExecution, if anystatic ObjectgetSimulationOptionValue(String name, Element context) Get the simulation option value In case there is no execution, will try to return the option value from project or environment options of the toolstatic BooleanisFeatureValueInvalid(FeatureValue featureValue, int index) Check the specified FeatureValue is invalid value or not.
-
Constructor Details
-
SimulationHelper
public SimulationHelper()
-
-
Method Details
-
findFeatureValue
@Deprecated public static List<FeatureValue> findFeatureValue(CompoundValue runtimeContext, List<Property> propertyPath, Property target) Deprecated. -
getConfigElement
@CheckForNull public static Element getConfigElement(@CheckForNull SimulationExecution simulationExecution) Gets simulation config element from simulation execution.- Parameters:
simulationExecution- SimulationExecution- Returns:
- Simulation config element or null.
-
getExecution
Retrieves object representing ongoing SimulationExecution, if any -
isFeatureValueInvalid
Check the specified FeatureValue is invalid value or not.- Parameters:
featureValue- the specified FeatureValueindex- index of the value- Returns:
- Boolean.TRUE if featureValue is invalid. Boolean.FALSE if featureValue is valid. null if featureValue is not evaluated.
-
getAvailableSignals
public static Set<Signal> getAvailableSignals(@CheckForNull StructuredValue target, @CheckForNull ExecutionEngine engine) Get availableSignals from the specified StructuredValue.- Parameters:
target- the specified StructuredValueengine- ExecutionEngine- Returns:
- Set
-
getSimulationOptionValue
@CheckForNull public static Object getSimulationOptionValue(String name, @CheckForNull Element context) Get the simulation option value In case there is no execution, will try to return the option value from project or environment options of the tool- Parameters:
name- the simulation option name constant (usually fromSimulationOptions)- Returns:
- the simulation option value, if exists
-
fUMLHelper.findFeatureValue(CompoundValue, List, Property)