|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectptolemy.actor.lib.hoc.ModelUtilities
public class ModelUtilities
A collection of utilities for manipulating a Ptolemy model. FIXME: Currently there is only one major operation for invoke the execution of a model. We may add more later.
| Red (cxh) |
| Yellow (eal) |
| Constructor Summary | |
|---|---|
private |
ModelUtilities()
Instances of this class cannot be created. |
| Method Summary | |
|---|---|
private static RecordToken |
_getResult(CompositeActor model,
java.lang.String[] resultLabels)
Iterate over the resultLabels and check whether the specified model has Attribute with the same name of a label. |
private static void |
_setAttribute(CompositeActor model,
RecordToken args)
Iterate over the labelSet of the args argument and check whether the specified model has Attribute with the same name of a label. |
static RecordToken |
executeModel(CompositeActor model,
RecordToken args,
java.lang.String[] resultLabels)
This method takes model argument which is type of CompositeActor. |
static RecordToken |
executeModel(java.net.URL url,
RecordToken args,
java.lang.String[] resultLabels)
This method takes a url specifying the model to be execute. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
private ModelUtilities()
| Method Detail |
|---|
public static RecordToken executeModel(java.net.URL url,
RecordToken args,
java.lang.String[] resultLabels)
throws IllegalActionException
url - The Model url.args - A set of attributes of the specified model.resultLabels - Labels of the returned result.
IllegalActionException - If can not parse the url
or failed to execute the model.
public static RecordToken executeModel(CompositeActor model,
RecordToken args,
java.lang.String[] resultLabels)
throws IllegalActionException
model - The Model.args - A set of attributes of the specified model.resultLabels - Labels of the returned result.
IllegalActionException - If failed to execute the model.
private static void _setAttribute(CompositeActor model,
RecordToken args)
throws IllegalActionException
IllegalActionException - If reading the ports or
setting the parameters causes it.
private static RecordToken _getResult(CompositeActor model,
java.lang.String[] resultLabels)
throws IllegalActionException
model - The model executed.resultLabels - Labels of the returned result.
IllegalActionException - If reading the ports or
setting the parameters causes it.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||