gpt4 book ai didi

org.apache.taverna.scufl2.api.io.WorkflowBundleIO.getReaderForMediaType()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-26 08:55:05 26 4
gpt4 key购买 nike

本文整理了Java中org.apache.taverna.scufl2.api.io.WorkflowBundleIO.getReaderForMediaType()方法的一些代码示例,展示了WorkflowBundleIO.getReaderForMediaType()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WorkflowBundleIO.getReaderForMediaType()方法的具体详情如下:
包路径:org.apache.taverna.scufl2.api.io.WorkflowBundleIO
类名称:WorkflowBundleIO
方法名:getReaderForMediaType

WorkflowBundleIO.getReaderForMediaType介绍

[英]Returns a WorkflowBundleReader for the specified media type. If there is more than one WorkflowBundleReader for the specified media type the first reader discovered is returned. Subsequent calls to this method may return a different reader. If there is no WorkflowBundleReader for the specified media type null is returned.
[中]返回指定媒体类型的WorkflowBundleReader。如果指定的媒体类型有多个WorkflowBundleReader,则返回发现的第一个读卡器。对该方法的后续调用可能会返回不同的读取器。如果指定的媒体类型没有WorkflowBundleReader,则返回null

代码示例

代码示例来源:origin: org.apache.taverna.language/taverna-scufl2-api

WorkflowBundleReader reader = getReaderForMediaType(mediaType);
if (reader == null) {
  if (mediaType == null)

代码示例来源:origin: org.apache.taverna.language/taverna-scufl2-api

WorkflowBundleReader reader = getReaderForMediaType(mediaType);
if (reader == null) {
  if (mediaType == null)

代码示例来源:origin: org.apache.taverna.language/taverna-scufl2-api

@Test
public void getReaderForUnknownMediaType() throws Exception {
  assertNull(bundleIO
      .getReaderForMediaType("application/vnd.example.unknownStuff"));
}

代码示例来源:origin: org.apache.taverna.language/taverna-scufl2-api

@Test
public void getReaderForMediaType() throws Exception {
  WorkflowBundleReader Reader = bundleIO
  .getReaderForMediaType(TEXT_VND_TAVERNA_SCUFL2_STRUCTURE);
  assertTrue(Reader instanceof StructureReader);
}

代码示例来源:origin: org.apache.taverna.language/taverna-scufl2-api

assertSame(myReader, bundleIO.getReaders().get(0));
assertSame(myReader,
    bundleIO.getReaderForMediaType("application/vnd.example.myOwn"));
    .getReaderForMediaType(TEXT_VND_TAVERNA_SCUFL2_STRUCTURE));		
assertEquals("test/test", bundleIO.guessMediaTypeForSignature(new byte[4]));

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com