• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java Progress类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.apache.uima.util.Progress的典型用法代码示例。如果您正苦于以下问题:Java Progress类的具体用法?Java Progress怎么用?Java Progress使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



Progress类属于org.apache.uima.util包,在下文中一共展示了Progress类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: test

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Test
public void test() throws Exception {
	FakeCollectionReader cr = new FakeCollectionReader();

	UimaContext context = UimaContextFactory.createUimaContext();
	cr.initialize(context);
	assertTrue(cr.initialised);

	assertNotNull(cr.getSupport());
	assertNotNull(cr.getMonitor());
	assertNotNull(cr.getProgress());

	Progress[] progress = cr.getProgress();
	assertEquals("testunits", progress[0].getUnit());

	assertFalse(cr.hasNext());
	assertTrue(cr.hasNext);

	cr.getNext((JCas)null);
	assertTrue(cr.getNext);

	cr.destroy();
	assertTrue(cr.closed);
}
 
开发者ID:dstl,项目名称:baleen,代码行数:25,代码来源:BaleenCollectionReaderTest.java


示例2: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
public Progress[] getProgress() {
	return new Progress[] {
			new ProgressImpl(
					Long.valueOf(currentRecord).intValue(),
					Long.valueOf(totalRecords).intValue(),
					Progress.ENTITIES
					)
	};
}
 
开发者ID:tudarmstadt-lt,项目名称:newsleak-frontend,代码行数:10,代码来源:NewsleakCsvStreamReader.java


示例3: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
public Progress[] getProgress() {
	return new Progress[] {
			new ProgressImpl(
					Long.valueOf(currentRecord).intValue() - 1,
					Long.valueOf(totalRecords).intValue(),
					Progress.ENTITIES
					)
	};
}
 
开发者ID:tudarmstadt-lt,项目名称:newsleak-frontend,代码行数:10,代码来源:HooverElasticsearchReader.java


示例4: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Override
public Progress[] getProgress() {
	if (disableProgressTracking) {
		documentsToBeProcessedCount = processedDocumentCount + 1;
	}
	return new Progress[] { new ProgressImpl(processedDocumentCount, documentsToBeProcessedCount, Progress.ENTITIES) };
}
 
开发者ID:UCDenver-ccp,项目名称:ccp-nlp,代码行数:8,代码来源:BaseTextCollectionReader.java


示例5: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
/**
 * {@inheritDoc}
 */
@Override
public Progress[] getProgress() {
    return new Progress[]{
            new ProgressImpl(lastReadFileIdx + 1, files.size(), Progress.ENTITIES)
    };
}
 
开发者ID:textocat,项目名称:textokit-core,代码行数:10,代码来源:FileDirectoryCollectionReader.java


示例6: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
/**
 * {@inheritDoc}
 */
@Override
public Progress[] getProgress() {
    return new Progress[]{
            new ProgressImpl(consumedCount, expectedTotalCount, Progress.ENTITIES)
    };
}
 
开发者ID:textocat,项目名称:textokit-core,代码行数:10,代码来源:JdbcCollectionReader.java


示例7: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Override
public Progress[] getProgress() {
    int filesRead = lastReadFileIndex + 1;
    return new Progress[]{
            new ProgressImpl(filesRead, inputFiles.size(), Progress.ENTITIES)
    };
}
 
开发者ID:textocat,项目名称:textokit-core,代码行数:8,代码来源:RusCorporaCollectionReader.java


示例8: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Override
public final Progress[] getProgress() {
	monitor.startFunction("getProgress");

	Progress[] ret = doGetProgress();

	monitor.finishFunction("getProgress");
	return ret;
}
 
开发者ID:dstl,项目名称:baleen,代码行数:10,代码来源:BaleenCollectionReader.java


示例9: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
public Progress[] getProgress() {
  if (filterArticles) {
    return new Progress[] { new ProgressImpl(progress, articleIds.size(), Progress.ENTITIES) };
  } else {
    return new Progress[] { new ProgressImpl(progress, 2000, Progress.ENTITIES) };
  }
}
 
开发者ID:ClearTK,项目名称:cleartk,代码行数:8,代码来源:GeniaPosGoldReader.java


示例10: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
/**
 *
 * @return an array of Progress objects. Each object may have different units (for example number of entities or bytes).
 */
@Override
public Progress[] getProgress() {
    return new Progress[]{new ProgressImpl(getCurrentIndex(),
            getCollectionSize(),
            Progress.ENTITIES)};
}
 
开发者ID:department-of-veterans-affairs,项目名称:Leo,代码行数:11,代码来源:BaseFileCollectionReader.java


示例11: testRunWithPropertySetting

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Test
public void testRunWithPropertySetting() throws Exception {
    DatabaseCollectionReader dcr = new DatabaseCollectionReader()
            .setQuery(query)
            .setIdColumn("id")
            .setNoteColumn("note")
            .setDriver(dbConnectionInfo.getDriver())
            .setURL(dbConnectionInfo.getUrl())
            .setUsername(dbConnectionInfo.getUsername())
            .setPassword(dbConnectionInfo.getPassword());
    assertNotNull(dcr);
    assertEquals(dbConnectionInfo.getDriver(), dcr.getDriver());
    assertEquals(dbConnectionInfo.getUrl(), dcr.getURL());
    assertEquals(dbConnectionInfo.getUsername(), dcr.getUsername());
    assertEquals(dbConnectionInfo.getPassword(), dcr.getPassword());
    assertEquals(query, dcr.getQuery());
    assertEquals("id", dcr.getIdColumn());
    assertEquals("note", dcr.getNoteColumn());

    //Create the mock client and run it
    DoNothingListener listener = new DoNothingListener();
    assertNotNull(listener);
    MockClient client = new MockClient();
    assertNotNull(client);
    client.run(dcr, listener);
    //Check that all records were pulled
    assertEquals(TEST_CORPUS_SIZE, listener.getNumReceived());
    Progress progress = dcr.getProgress()[0];
    assertEquals(0, progress.getCompleted());
    assertEquals(0, progress.getTotal());
    assertEquals("row(s)", progress.getUnit());
}
 
开发者ID:department-of-veterans-affairs,项目名称:Leo,代码行数:33,代码来源:DatabaseCollectionReaderTest.java


示例12: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Override
public Progress[] getProgress()
{
    // empty as we don't know how many entries are in the tar stream...
    return new Progress[] {};
}
 
开发者ID:UKPLab,项目名称:argument-reasoning-comprehension-task,代码行数:7,代码来源:CompressedXmiReader.java


示例13: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
public Progress[] getProgress()
{
    return null;
}
 
开发者ID:Horsmann,项目名称:FlexTag,代码行数:5,代码来源:LineTokenTagReader.java


示例14: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Override
public Progress[] getProgress() {
  return new Progress[]{new ProgressImpl(completed, total, "Documents", true)};
}
 
开发者ID:nlpie,项目名称:biomedicus,代码行数:5,代码来源:DocumentSourceUimaAdapter.java


示例15: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Override
public Progress[] getProgress() {
  return new Progress[0];
}
 
开发者ID:nlpie,项目名称:biomedicus,代码行数:5,代码来源:NoDocumentsCollectionReader.java


示例16: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Override
public Progress[] getProgress() {
	return null;
}
 
开发者ID:quadrama,项目名称:DramaNLP,代码行数:5,代码来源:AbstractDramaUrlReader.java


示例17: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
public Progress[] getProgress() {
    int total = resourcesNum == null ? -1 : resourcesNum;
    return new Progress[]{new ProgressImpl(resourcesRead, total, Progress.ENTITIES)};
}
 
开发者ID:textocat,项目名称:textokit-core,代码行数:5,代码来源:XmiCollectionReaderBase.java


示例18: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
/**
 * {@inheritDoc}
 */
@Override
public Progress[] getProgress() {
    return null;
}
 
开发者ID:textocat,项目名称:textokit-core,代码行数:8,代码来源:LinesCollectionReader.java


示例19: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Override
public Progress[] getProgress() {
    return new Progress[]{new ProgressImpl(mCurrentIndex,
            uriAnnotatorPairs.size(), Progress.ENTITIES)};
}
 
开发者ID:textocat,项目名称:textokit-core,代码行数:6,代码来源:CorpusDAOCollectionReader.java


示例20: getProgress

import org.apache.uima.util.Progress; //导入依赖的package包/类
@Override
public Progress[] getProgress() {
    return new Progress[]{
            new ProgressImpl(docsRead, totalDocsNum, Progress.ENTITIES)
    };
}
 
开发者ID:textocat,项目名称:textokit-core,代码行数:7,代码来源:BratCollectionReader.java



注:本文中的org.apache.uima.util.Progress类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java MBeanServerBuilder类代码示例发布时间:2022-05-21
下一篇:
Java SendRequest类代码示例发布时间:2022-05-21
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap