Cameo Simulation Toolkit 2021x Documentation

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

The following ALH API checks whether a particular object is in a specific state name.
 

public boolean inState(Object_ object, String stateName) {
	... 
} 

public boolean inState(String stateName) {
...
}

 

Unless the object is specified, it will use the current active object, for example:

if (ALH.inState(ccobj, "Operating")) {
	force=ccForce
} else {
	force = acc*2
}

Information

Alternatively, you can use ALH API through the fUML object syntax, with object.inState(stateName). For example:

  • ccobj.inState(“Operating”);
  • No labels