本文整理汇总了Java中org.apache.taverna.workflowmodel.processor.activity.config.ActivityOutputPortDefinitionBean类的典型用法代码示例。如果您正苦于以下问题:Java ActivityOutputPortDefinitionBean类的具体用法?Java ActivityOutputPortDefinitionBean怎么用?Java ActivityOutputPortDefinitionBean使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ActivityOutputPortDefinitionBean类属于org.apache.taverna.workflowmodel.processor.activity.config包,在下文中一共展示了ActivityOutputPortDefinitionBean类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: configurePorts
import org.apache.taverna.workflowmodel.processor.activity.config.ActivityOutputPortDefinitionBean; //导入依赖的package包/类
protected void configurePorts() {
// In case we are being reconfigured - remove existing ports first
// to avoid duplicates
removeInputs();
removeOutputs();
// Add input ports
for(ActivityInputPortDefinitionBean inputPort : configBean.getInputPortDefinitions())
{
addInput(inputPort.getName(),inputPort.getDepth(),inputPort.getAllowsLiteralValues(),inputPort.getHandledReferenceSchemes(), inputPort.getTranslatedElementType());
}
// Add output ports
for(ActivityOutputPortDefinitionBean outputPort : configBean.getOutputPortDefinitions())
{
addOutput(outputPort.getName(),outputPort.getDepth());
}
}
示例2: getOutputPorts
import org.apache.taverna.workflowmodel.processor.activity.config.ActivityOutputPortDefinitionBean; //导入依赖的package包/类
@Override
public Set<ActivityOutputPort> getOutputPorts(JsonNode configuration)
throws ActivityConfigurationException {
try {
Set<ActivityOutputPort> activityOutputPorts = new HashSet<>();
for (ActivityOutputPortDefinitionBean opd : createConfiguration(
configuration).getPorts().getOutputPortDefinitions())
activityOutputPorts.add(edits.createActivityOutputPort(
opd.getName(), opd.getDepth(), opd.getGranularDepth()));
return activityOutputPorts;
} catch (MalformedURLException | ComponentException | RuntimeException e) {
throw new ActivityConfigurationException(
"failed to get implementation for configuration of outputs",
e);
}
}
示例3: configurePorts
import org.apache.taverna.workflowmodel.processor.activity.config.ActivityOutputPortDefinitionBean; //导入依赖的package包/类
/**
* <p>
* Simplifies configuring the Activity input and output ports if its
* ConfigType is an implementation of {@link ActivityPortsDefinitionBean}
* </p>
* <p>
* For an Activity that has ports that are defined dynamically it is natural
* that is ConfigType will not implement this interface.
* </p>
*
* @param configBean
*/
protected void configurePorts(ActivityPortsDefinitionBean configBean) {
removeInputs();
for (ActivityInputPortDefinitionBean inputDef : configBean
.getInputPortDefinitions()) {
addInput(inputDef.getName(), inputDef.getDepth(), inputDef
.getAllowsLiteralValues(), inputDef
.getHandledReferenceSchemes(), inputDef
.getTranslatedElementType());
// TODO - use the mime types from the config bean if required,
// probably best handled elsewhere though
}
removeOutputs();
for (ActivityOutputPortDefinitionBean outputDef : configBean
.getOutputPortDefinitions()) {
ActivityOutputPort createActivityOutputPort = getEdits()
.createActivityOutputPort(outputDef.getName(),
outputDef.getDepth(), outputDef.getGranularDepth());
// addOutput(outputDef.getName(), outputDef.getDepth(), outputDef
// .getGranularDepth());
outputPorts.add(createActivityOutputPort);
// add the mime types as annotations
for (String mimeType : outputDef.getMimeTypes())
setMimeType(createActivityOutputPort, mimeType);
}
}
示例4: makeOutputDefinition
import org.apache.taverna.workflowmodel.processor.activity.config.ActivityOutputPortDefinitionBean; //导入依赖的package包/类
private ActivityOutputPortDefinitionBean makeOutputDefinition(int depth,
String name) {
ActivityOutputPortDefinitionBean activityOutputPortDefinitionBean = new ActivityOutputPortDefinitionBean();
activityOutputPortDefinitionBean.setMimeTypes(new ArrayList<String>());
activityOutputPortDefinitionBean.setDepth(depth);
activityOutputPortDefinitionBean.setGranularDepth(depth);
activityOutputPortDefinitionBean.setName(name);
return activityOutputPortDefinitionBean;
}
开发者ID:apache,项目名称:incubator-taverna-plugin-component,代码行数:10,代码来源:ComponentActivityConfigurationBean.java