de.cau.cs.kieler.kaom.importer.ptolemy
Class PtolemyHelper

java.lang.Object
  extended by de.cau.cs.kieler.kaom.importer.ptolemy.PtolemyHelper
All Implemented Interfaces:
org.eclipse.xtend.expression.IExecutionContextAware

public class PtolemyHelper
extends Object
implements org.eclipse.xtend.expression.IExecutionContextAware

Helper methods to inspect Ptolemy models. Could be used from Xtend transformations.

Rating red

Constructor Summary
PtolemyHelper()
          Constructs a new instance.
 
Method Summary
 List<Port> getPorts(EntityType ptolemyEntity)
          Returns a list of ports of the given entity type.
 List<Port> getPorts(List<EntityType> entities)
          Returns a list of all the ports of the given entity types.
 void setExecutionContext(org.eclipse.xtend.expression.ExecutionContext context)
          Execution context is set by Xtend component from outside.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PtolemyHelper

public PtolemyHelper()
Constructs a new instance.

Method Detail

getPorts

public List<Port> getPorts(List<EntityType> entities)
Returns a list of all the ports of the given entity types.

Parameters:
entities - the entity types whose ports to return.
Returns:
list of ports.

getPorts

public List<Port> getPorts(EntityType ptolemyEntity)
Returns a list of ports of the given entity type.

Parameters:
ptolemyEntity - the entity type whose ports to return.
Returns:
list of ports.

setExecutionContext

public void setExecutionContext(org.eclipse.xtend.expression.ExecutionContext context)
Execution context is set by Xtend component from outside. It can be used to obtain detailed information about the transformation. This implementation currently does nothing since the execution context is not used at the moment.

Specified by:
setExecutionContext in interface org.eclipse.xtend.expression.IExecutionContextAware
Parameters:
context - the execution context.