Search in sources :

Example 1 with ComponentDataPort

use of org.apache.airavata.workflow.model.component.ComponentDataPort in project airavata by apache.

the class ExitComponent method createPorts.

protected void createPorts(NodeImpl node) {
    for (ComponentDataPort input : getInputPorts()) {
        DataPort port = input.createPort();
        node.addInputPort(port);
    }
    for (ComponentDataPort output : getOutputPorts()) {
        DataPort port = output.createPort();
        node.addOutputPort(port);
    }
    if (this.controlInPort != null) {
        ControlPort port = this.controlInPort.createPort();
        node.setControlInPort(port);
    }
    for (ComponentControlPort componentPort : this.controlOutPorts) {
        ControlPort port = componentPort.createPort();
        node.addControlOutPort(port);
    }
    if (this.eprPort != null) {
        EPRPort port = this.eprPort.createPort();
        node.setEPRPort(port);
    }
}
Also used : SystemComponentDataPort(org.apache.airavata.workflow.model.component.system.SystemComponentDataPort) DataPort(org.apache.airavata.workflow.model.graph.DataPort) ComponentDataPort(org.apache.airavata.workflow.model.component.ComponentDataPort) EPRPort(org.apache.airavata.workflow.model.graph.EPRPort) ControlPort(org.apache.airavata.workflow.model.graph.ControlPort) ComponentControlPort(org.apache.airavata.workflow.model.component.ComponentControlPort) ComponentControlPort(org.apache.airavata.workflow.model.component.ComponentControlPort) SystemComponentDataPort(org.apache.airavata.workflow.model.component.system.SystemComponentDataPort) ComponentDataPort(org.apache.airavata.workflow.model.component.ComponentDataPort)

Example 2 with ComponentDataPort

use of org.apache.airavata.workflow.model.component.ComponentDataPort in project airavata by apache.

the class TerminateInstanceComponent method toHTML.

/**
 * @see org.apache.airavata.workflow.model.component.Component#toHTML()
 */
@Override
public String toHTML() {
    StringBuffer buf = new StringBuffer();
    buf.append("<html> <h1>" + this.name + " Component</h1>");
    buf.append("<h2>Description:</h2> " + this.description);
    for (int i = 0; i < this.inputs.size(); i++) {
        ComponentDataPort port = this.inputs.get(i);
        buf.append("<h3>Input" + (i + 1) + "</h3>");
        buf.append("<strong>Name: </strong>");
        buf.append("" + port.getName() + "<br>");
        buf.append("<strong>Description: </strong>");
        buf.append("" + port.getDescription());
    }
    for (int i = 0; i < this.outputs.size(); i++) {
        ComponentDataPort port = this.outputs.get(i);
        buf.append("<h3>Output" + (i + 1) + "</h3>");
        buf.append("<strong>Name: </strong>");
        buf.append("" + port.getName() + "<br>");
        buf.append("<strong>Description: </strong>");
        buf.append("" + port.getDescription());
    }
    buf.append("</html>");
    return buf.toString();
}
Also used : ComponentDataPort(org.apache.airavata.workflow.model.component.ComponentDataPort)

Example 3 with ComponentDataPort

use of org.apache.airavata.workflow.model.component.ComponentDataPort in project airavata by apache.

the class SystemComponent method toHTML.

/**
 * @see org.apache.airavata.workflow.model.component.Component#toHTML()
 */
@Override
public String toHTML() {
    StringBuffer buf = new StringBuffer();
    buf.append("<html> <h1>" + this.name + " Component</h1>");
    buf.append("<h2>Description:</h2> " + this.description);
    for (int i = 0; i < this.inputs.size(); i++) {
        ComponentDataPort port = this.inputs.get(i);
        buf.append("<h3>Input" + (i + 1) + "</h3>");
        buf.append("<strong>Name: </strong>");
        buf.append("" + port.getName() + "<br>");
        buf.append("<strong>Description: </strong>");
        buf.append("" + port.getDescription());
    }
    for (int i = 0; i < this.outputs.size(); i++) {
        ComponentDataPort port = this.outputs.get(i);
        buf.append("<h3>Output" + (i + 1) + "</h3>");
        buf.append("<strong>Name: </strong>");
        buf.append("" + port.getName() + "<br>");
        buf.append("<strong>Description: </strong>");
        buf.append("" + port.getDescription());
    }
    buf.append("</html>");
    return buf.toString();
}
Also used : ComponentDataPort(org.apache.airavata.workflow.model.component.ComponentDataPort)

Example 4 with ComponentDataPort

use of org.apache.airavata.workflow.model.component.ComponentDataPort in project airavata by apache.

the class DoWhileNode method addInputPort.

/**
 * Adds additional input port.
 */
public void addInputPort() {
    DoWhileComponent component = getComponent();
    ComponentDataPort input = component.getInputPort();
    DataPort port = input.createPort();
    addInputPort(port);
}
Also used : DataPort(org.apache.airavata.workflow.model.graph.DataPort) ComponentDataPort(org.apache.airavata.workflow.model.component.ComponentDataPort) DoWhileComponent(org.apache.airavata.workflow.model.component.system.DoWhileComponent) ComponentDataPort(org.apache.airavata.workflow.model.component.ComponentDataPort)

Example 5 with ComponentDataPort

use of org.apache.airavata.workflow.model.component.ComponentDataPort in project airavata by apache.

the class EndBlockNode method addOutputPort.

/**
 * Adds additional output port.
 */
public void addOutputPort() {
    EndBlockComponent component = getComponent();
    ComponentDataPort outputPort = component.getOutputPort();
    DataPort port = outputPort.createPort();
    addOutputPort(port);
}
Also used : EndBlockComponent(org.apache.airavata.workflow.model.component.system.EndBlockComponent) DataPort(org.apache.airavata.workflow.model.graph.DataPort) ComponentDataPort(org.apache.airavata.workflow.model.component.ComponentDataPort) ComponentDataPort(org.apache.airavata.workflow.model.component.ComponentDataPort)

Aggregations

ComponentDataPort (org.apache.airavata.workflow.model.component.ComponentDataPort)18 DataPort (org.apache.airavata.workflow.model.graph.DataPort)15 DoWhileComponent (org.apache.airavata.workflow.model.component.system.DoWhileComponent)3 ForEachComponent (org.apache.airavata.workflow.model.component.system.ForEachComponent)3 EndBlockComponent (org.apache.airavata.workflow.model.component.system.EndBlockComponent)2 EndDoWhileComponent (org.apache.airavata.workflow.model.component.system.EndDoWhileComponent)2 EndForEachComponent (org.apache.airavata.workflow.model.component.system.EndForEachComponent)2 EndifComponent (org.apache.airavata.workflow.model.component.system.EndifComponent)2 ComponentControlPort (org.apache.airavata.workflow.model.component.ComponentControlPort)1 SystemComponentDataPort (org.apache.airavata.workflow.model.component.system.SystemComponentDataPort)1 ControlPort (org.apache.airavata.workflow.model.graph.ControlPort)1 EPRPort (org.apache.airavata.workflow.model.graph.EPRPort)1